Arduino Forum

Products => Arduino Due => Topic started by: dezguy on Aug 30, 2013, 11:18 pm

Title: Arduino Due / Cross Compiler
Post by: dezguy on Aug 30, 2013, 11:18 pm
Hey folks,

Quick question, what is the cross compiler / library being used for the Adruino Due for OS X? With GCC and avrlib it was fairly easy to dig deeper than the Arduino IDE. I'm on OS X and can't download AVRStudio. Does ARM work the same way? I'm just looking for some good references.

Cheers,
mike
Title: Re: Arduino Due / Cross Compiler
Post by: jtw11 on Aug 30, 2013, 11:50 pm
GCC also exists for the ARM CPU that the SAM devices utilse - Atmel Studio (It is no longer called AVRStudio, as it supports other devices not just the AVR chips, so it's now called Atmel Studio) also includes a few other compilers. Here's a quote from the product page.

Quote
The Atmel AVR® and ARM® Cortex™-M processor-based microcontrollers are also supported by third-party compilers including IAR Embedded Workbench® and Keil™.


There is a lot of free code available to use with the SAM devices inside the 'Atmel Software Framework'.
Title: Re: Arduino Due / Cross Compiler
Post by: dezguy on Aug 31, 2013, 12:35 am
Thanks,that makes sense. I'll download that and dig around.

Cheers,
Mike
Title: Re: Arduino Due / Cross Compiler
Post by: Palliser on Aug 31, 2013, 02:31 am
Hello dezguy,

As you are going to mess with the ASF, prepare to meet Atmel's hell.- I speak from my own experience. Too much junk code! It's like the Amazon rainforest. It's very easy to get lost in it. So far I have ported a couple of libraries from ASF to Due. A much better start to understand the SAM core is to get familiar with the Arduino libsam library.

Quote
...\arduino-1.5.2-windows\arduino-1.5.2\hardware\arduino\sam\system\libsam 


There you will find the source and include SAM drivers like ADC, PIO, PMC, RTC, TWI, etc. The duo Arduino-Atmel did a great job in it that deserves the benefit of a close look. Good luck!
Title: Re: Arduino Due / Cross Compiler
Post by: noblepepper on Aug 31, 2013, 02:50 pm
The arduino ide uses the Codesourcery toolchain, in linux the actual compiler executable is arm-none-eabi-g++.

You should be able to use the Eclipse IDE on OS X with the stock arduino libraries, it is working great for me on ubuntu. I found some work by Nassa and Zad in this forum that gave me enough hints to get it going on linux. The thread was titled [Q]: Tailoring the Due to Eclipse..

If you are interested I can give some of the details of how I got it working.
Title: Re: Arduino Due / Cross Compiler
Post by: dezguy on Sep 03, 2013, 10:47 pm
Thanks all :) I appreciate the responses.

Cheers,
Mike