Hello,
I would like to have 2 variables of different structure, but of course same size, at same adress.
The goal is to decode easily serial header by putting incomming char in a buffer of 10 byte where each will have particular signification.
See example bellow (not the final code just trial)
typedef struct
{
byte one;
byte two;
int three;
} type_record;typedef struct
{
byte buffer[4];
} type_buffer;type_buffer buf;
type_record test;type_buffer *ptr1;
type_record *ptr2;
Many thanks