12-23-2014 02:17 AM
i am doing a tcp application in SDK, i use microblaze with AXI Bus.
I see that microblaze endianness is little endian because of the AXI Bus,
in SDK i see that in the Symbol tab in the compiler option is active the symbol "__BIG_ENDIAN__"
what is the endianness of the platform?
12-23-2014 03:15 AM
You can find some useeful information in the following AR http://www.xilinx.com/support/answers/45841.html also
12-23-2014 03:20 AM
12-23-2014 04:08 AM
The feature to over write the endianess is removed in Vivado. This was in XPS to support the PLB which supports big endian
12-23-2014 04:48 AM
I continue to not understand,
i use a free TCP/IP library, it has some controls on the endianness of the platform to do some conversion (htons ntohs) to correctly forward addresses on the network..
#ifdef __BIG_ENDIAN__ #ifndef htons #define htons(x) (x) #endif #ifndef ntohs #define ntohs(x) (x) #endif #ifndef htonl #define htonl(x) (x) #endif #ifndef ntohl #define ntohl(x) (x) #endif
i see that __BIG_ENDIAN__ is defined, i see that microblaze is little endian, i see that the application works
where is the trick? maybe microblaze use some functions to convert from little endian to big endian?
how can i attach my workspace?
12-23-2014 12:39 PM
You are right. ntoh and hton that you are referring in the below post are a part of xil_io.h that comes along with Standalone BSP. These functions are also a part of the LWIP source code too. You can find the information about these functions in page 38 of UG647 http://www.xilinx.com/support/documentation/sw_manuals/xilinx2014_4/oslib_rm.pdf