Skip to content

Instantly share code, notes, and snippets.

@setkeh
Created August 23, 2013 05:00
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save setkeh/6315692 to your computer and use it in GitHub Desktop.
Save setkeh/6315692 to your computer and use it in GitHub Desktop.
#include <aery32/all.h>
#include "board.h"
#define LED AVR32_PIN_PC04
using namespace aery;
int main(void)
{
/*
* * The default board initializer defines all pins as input and
* * sets the CPU clock speed to 66 MHz.
* */
board::init();
gpio_init_pin(LED, GPIO_OUTPUT);
gpio_set_pin_high(LED);
for(;;)
{
gpio_toggle_pin(LED);
delay_ms(500);
gpio_toggle_pin(LED);
delay_ms(2000);
}
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment