Stack Exchange network consists of 183 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
Thank you. I was aware of the fact of 8bit vs 32bit. I haven't tried your code but it seems right. What did the trick for me in the end was the following: void putData64(byte* packet, int pos, uint64_t data) { uint32_t* out= (uint32_t*) (packet+pos+2); uint32_t* in= (uint32_t*) data; *(out++)= *(in++); *(out++)= *(in++); }