i have a code for avr that write with iar, and have a header file,"ATxmega128A3.h. if i want to port this code to GCC (i am working with atmel studio),will i need to call this header file, or this header file just for IAR compiler?
1 Answer
\$\begingroup\$
\$\endgroup\$
2
You'll need the equivalent GCC header (iox128a3.h) and try to compile. You might have to fix and debug anything where the definitions aren't exactly the same... but don't worry, your compiler will complain for every... last... one... of... them.
-
\$\begingroup\$ can you tell me please why we need this header file,and why we should use this header file? \$\endgroup\$ Commented Apr 18, 2017 at 16:11
-
\$\begingroup\$ You don't 'need' it, but otherwise you will have to define any hardware-specific numbers (I/O register addresses and bits, interrupt vectors, memory ranges etc.) in your own code. \$\endgroup\$ Commented Apr 18, 2017 at 17:20