Advertisement
Guest User

Untitled

a guest
Nov 28th, 2014
165
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.51 KB | None | 0 0
  1. typedef union _MessagePureData_TypeDef
  2. {
  3. signed int S32[1];
  4. unsigned int U32[1];
  5. unsigned short U16[2];
  6. signed short S16[2];
  7. unsigned char U8[4];
  8. } messagePureData;
  9.  
  10. typedef union _MessageData_TypeDef
  11. {
  12. unsigned char ptr[6];
  13. struct
  14. {
  15. unsigned char srcDevice;
  16. unsigned char srcSpecifier;
  17. messagePureData data;
  18. } section;
  19. } messageData;
  20.  
  21. messageData.section.srcDevice = 0xAA;
  22. messageData.section.srcSpecifier = 0xBB;
  23. messageData.section.data.U32 = 0x11223344;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement