#include "config.h"
int main (void) { volatile uint32 CYCLE = 0x0; uint8 i = 0; uint8 rcv_buf[4]={1,2,3,4}; for(i=0; i<4; i++) //前四位buf组成32位数据给CYCLE { CYCLE <<= 8; CYCLE =+ rcv_buf; } while(1); return 0; }
每次运行完CYCLE都等于0x04,在调试里我发现我循环里的左移8位根本没起作用。这是为什么啊!!! |