#include <avr/io.h>
#include <util/delay.h>

//Port A data register
#define LED_PORT PORTA
//Port A data direction register
#define LED_DIR DDRA
//Port A input pins
#define LED_PINS PINA
//Pin number where LED is connected
#define LED_PIN (1 << PA3)

int main(void){
  //Enable pull-up resistor after tristate (see datasheet 10.1.3)
  LED_PORT |= LED_PIN;
  //Configure pin A3 (i.e. the one for the LED) as output
  LED_DIR |= LED_PIN;

  while(1){
    _delay_ms(50);
    //Toggle LED
    LED_PORT ^= LED_PIN;
  }
}