Hello to all,
I am using NXPLPCXpresso 54114 board. I am working on ARM Cortex-M4. I need to change the ENDIANNESS from Little to Big and again Big to Little. Can anybody help me with the scripting part? I have gone through the ARM documentation and found this:
Can anybody help me with how to change the register value to convert the endianness ??
An example script will be a great help to convert Little-endian to Big-endian and Big-endian to Little-endian.
Thanking you in advance,
Regards,
Himanshu
Hi HIMANSHU DOSHI ,
The LPC54114 only support the little endian mode and the endian mode can't be changed afterward.(There is no dynamic endian switching, and the SETEND instruction is not supported.). however, you can easily convert the data between little endian and big endian using some of the new instructions in the Cortex-M3. For example, REV and REVH are very useful for this kind of conversion.
Have a great day,
TIC
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------