3 ms·
>always convert to big endian when sending data over a wire What is this awful advice. Only convert to big-endian where legacy demands it.
by hoseja 4y ago
>always convert to big endian when sending data over a wire
What is this awful advice. Only convert to big-endian where legacy demands it.
- wongarsu 4y agoMeh. Network byte order is big endian. Otoh close to every device uses little endian internally and the conversion is pointless except for convention. Otoh it doesn't really matter, because the conversion is extremely fast (including hardware support in common processors). Endianness is really perfectly named: a meaningless difference that generations of people fight holy wars over.
- 0x457 4y agoNetwork only applies to information in packet headers. How you actually pack bytes into your packets is entirely up to you and/or the protocol you're using. It was a flip of a coin choice.
- Gibbon1 4y agoThe LoRaWAN standard uses big endian.