Compile/run on the sam architecture too (used with the Due boards).

I have added some pre-processor definitions to make the code compile on the sam architecture too. I have tested it on a project using the Arduino IDE 1.5.1 and a Due board. 

I have also tested that it still compiles without errors on the old avr architecture, but I had no appropriate board to test that it still runs as expected on the avr architecture.