需要对三个字节的数据进行运算,发现编译报错,例如
uint8 a[3]={0x11,0x22,0x33};
long b;
b=((a[0])<<16)+((a[1])<<8)+a[2];
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.
需要对三个字节的数据进行运算,发现编译报错,例如
uint8 a[3]={0x11,0x22,0x33};
long b;
b=((a[0])<<16)+((a[1])<<8)+a[2];