Endiness is characteristic of a Digital link or an Electronic System.
For a System, Endiness refers to the order in which the data is stored by the system in its memory. The order could be LSB to a lower memory address or MSB to lower memory address.
For example : A Data coming to system is - 0x 00 FF
- '00' : MSB and 'FF' : LSB in the received data.
- System use 2 bytes to store data in its memory. Suppose address bytes 0x0001 and 0x0002 are to be used for storing these 2 data bytes.
- Strange thing is , System can utilize these two bytes in two ways to store the data.
Method 1 : Little Endian
Address | 0x0001 | 0x0002 |
Data | LSB - FF | MSB - 00 |
Method 2 : Big Endian
Address | 0x0001 | 0x0002 |
Data | LSB - 00 | MSB - FF |
For a communication link like CAN , Ethernet , an endiness of a channel means , the order in which data is put on the bus.
For a System, Endiness refers to the order in which the data is stored by the system in its memory. The order could be LSB to a lower memory address or MSB to lower memory address.
For example : A Data coming to system is - 0x 00 FF
- '00' : MSB and 'FF' : LSB in the received data.
- System use 2 bytes to store data in its memory. Suppose address bytes 0x0001 and 0x0002 are to be used for storing these 2 data bytes.
- Strange thing is , System can utilize these two bytes in two ways to store the data.
Method 1 : Little Endian
Address | 0x0001 | 0x0002 |
Data | LSB - FF | MSB - 00 |
Method 2 : Big Endian
Address | 0x0001 | 0x0002 |
Data | LSB - 00 | MSB - FF |
For a communication link like CAN , Ethernet , an endiness of a channel means , the order in which data is put on the bus.
Comments
Post a Comment