Venkat Chalapathi

stractures defination in HS08 freescale code warrior

Discussion created by Venkat Chalapathi on May 31, 2007
Latest reply on Jun 1, 2007 by Venkat Chalapathi
Hi,
Can some one suggest me how to utilize the bit field stracture defined in another, using storage calass in some other file.
 
Example  : /* Var.C */
 
typedef struct Bit_Flags {
        unsigned  SPI_RXTX_Flag :1; 
        unsigned  Temp2         :1;
        unsigned  Temp3         :1;
        unsigned  Temp4         :1;
        unsigned  Temp5         :1;
        unsigned  Temp6         :1;
        unsigned  Temp7         :1;
        unsigned  Temp8         :1;
}Flag1;
 
/* Main.c*/
 
Flag1 Status_Flags;
 
/*in Main.c below statement gives an error of undefined storage class ? how to specify storage class here? */
 
 Status_Flags.SPI_RXTX_Flag=0; 
 
please suggest the solution .
 
Thanks
Venkat

Outcomes