Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
BCD を使用して int を byte[4] 配列に変換したいと考えています。
問題の int はデバイス ID から取得され、シリアルポート経由でデバイスと通信する必要があります。
これを行う既製の機能はありますか、それとも簡単な方法を教えていただけますか?
例:
int id= 29068082
出力します:
byte[4]{0x82, 0x80, 0x06, 0x29};