[Solved] How to get uint8_t data of uint32_t [closed]
[ad_1] From your code, “™” is exactly what you should expect. // 0x19999999 – NOTE: you’d need an extra ‘5’ on the end to make it MAX_UNIT. eg. 0xFFFFFFFF uint32_t number = 429496729; uint8_t x1 = (number >> (8*0)) & 0xff; // 0x99 uint8_t x2 = (number >> (8*1)) & 0xff; // 0x99 uint8_t x3 … Read more