View Single Post
  #2   Spotlight this post!  
Unread 16-06-2005, 11:32
ImmortalAres ImmortalAres is offline
Registered User
no team
 
Join Date: May 2005
Location: Clarkson University
Posts: 33
ImmortalAres is an unknown quantity at this point
Re: Programming a 2nd PIC

the demo board supports programming through the mplab ICD2 through an rj-11 plug on the board. and yea, i quickly became aware of how i had to rewrite the start up, pic def, and alias file myself. Which i have no problem doing excpet for the fact that I seriously got lost in the pic def file. They're defnining things in structs that I can't find anywhere on the data sheet (ie the following)

Code:
extern volatile near unsigned char       RCSTA2;
extern volatile near union {
  struct {
    unsigned RX9D:1;
    unsigned OERR:1;
    unsigned FERR:1;
    unsigned ADEN:1;
    unsigned CREN:1;
    unsigned SREN:1;
    unsigned RX9:1;
    unsigned SPEN:1;
  };
  struct {
    unsigned RCD8:1;
    unsigned :5;
    unsigned RC9:1;
  };
  struct {
    unsigned :6;
    unsigned NOT_RC8:1;
  };
  struct {
    unsigned :6;
    unsigned RC8_9:1;
  };
} RCSTA2bits;
i got the first struct and i undersntad what's going on but what on earth is RCD8:1 or the :5 doing. i'm quite lost there.

maybe i'm approaching this totally wrong

any advice?