Search the Community
Showing results for tags 'unaligned pointers'.
From a little googling I have learned that the ZPU in general does not support unaligned memory accesses. My question is, will the ZPUino compiler generate the correct code to access the data pointed here correctly? I suspect it does not... would that be considered a bug? The reason for this is I am doing some data structure packing/unpacking. Im porting this code from an ARM and it seemed ok there! Thanks, and please let the emperor know if he is really just losing his mind. uint8_t output_buf ; uint8_t * buf_ptr= output_buf; *buf_ptr = '1'; buf_ptr++; *(unsigned *)buf_ptr = 0;//Unaligned access.