I'm trying to create a small native blinking LED sample for the Netduino. It shouldn't be that difficult.
I'm using the Atmel driver package: http://www.atmel.com...sp?tool_id=3759
And I've based the sample on the "getting-started" sample.
The code is simply:
/// Burn off some cpu time void Wait(unsigned long delay) { volatile unsigned long c = 0; volatile unsigned long dummy = 0; while( c < delay*1000) { dummy++; } } int main(void) { //configure led LED_Configure(0); // Main loop while (1) { //write LED_Toggle(0); //wait Wait(1000); } }
Where the LED-functions come from Atmel.
I've changed the led-0 to point at PB24. (The LED!)
I've changed the optimization to O0. (Just in case.)(I've also tried Os though.)
I've changed the chip to at91sam7x512.
(That should do it.)
I've tried with the YAGARTO4.4, YAGARTO4.5, CodeSourcery4.2 and CodeSourcery4.4 without succes.
Have anyone tried out the Atmel package or do someone have a small sample for a blinking LED? Or can anyone see the fatal mistake in my code?
Perhaps I need to enable the "peripheral clock" or something???
I've attached the complete project.