I am facing an issue of bytes being copied in a reverse order when I compile code using ARMCC. For example :
short int dest; short int src = 0x0010; memcpy(&dest,&src,sizeof(short int));
The value in the dest when i look into the memory display is shown as 10 00. I wonder why doesnt it place the values in appropriate bytes in the destination. To over come this, I have to use an array and copy value byte by byte.
Is there a solution to this issue ? or it is some problem in my code.