Uups, da war ich etwas voreilig. Hatte noch einen Fehler im Code, als ich's ohne typedef probiert hatte.
Es geht also auch ohne typedef problemlos:
Code:
struct { 
        unsigned short int ID ;      // 11 Bit-Kennung                          
        unsigned char      RTR ;     // TRUE, wenn remote request              
        unsigned char      LEN ;     // Anzahl der gueltigen Datenbytes (0..8) 
        unsigned char      DATA[8] ; // Datenbytes 0..7                        
} CANMsg; 


int main(void) 
{ 
while(1) 
CANMsg.ID ++; 

return 0; 
}
Dann stimme ich PicNick mal zu: Code herzeigen!