This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

F28035中数据结构的问题,有没有一个8bit长度的数据结构,char也是16bit的

如题,在调试程序中发现,建立了一个共用体

union CAL_DATA

{

Uint32 CalData;

Uint8 Byte[4];

};

CAL_DATA U1;

这个结构体相当于把32位的数据拆成4个8位的数据来用,方便传输,结果发现Uint8是从unsinged char命名过来的,而char是个16bit的数据,导致完全乱了套,数据对不齐了。试问,这F28035没有8位数据结构的数据吗?按说一般char是8bit长度的,这里竟然是16bit的,着实让我吃了一惊啊。

x 出现错误。请重试或与管理员联系。