Burn Bootloader Attiny13 Arduino

Posted on

ATtiny13 Arduino Wiring

Before we started to program attiny13, follow the circuit below with PIN configuration:



Let’s Program ATTiny13

1. Make Arduino as an ISP

  • Open Arduino IDE
  • Select the File menu> Examples> 11. ArduinoISP> Arduino ISP
  • Select Menu Tools> Board> Arduino / Genuine Uno
  • Select the programmer menu> avrisp mkll
  • Then click Upload
  • Finish


2 Burn a Bootloader

Burn a bootloader program is quite important and only just once at the beginning.

It is necessary to make attiny13 will be defined all internal settings of attiny13 such as the size of the frequency value used.

If Attiny13 is not done by bootloader, the performance is not appropriate. For example, we set the Attiny13 program delay turning and turning off the lights is for 1 second. If there is no bootloader, the program can run with 1.5 or 2 seconds delay.

This will have an impact on all attiny13 performance.

  • Select Menu Tools> Board> ATTINY13
  • Select Menu Tools> Programmer> Arduino as ISP
  • Select the Tools> Burn Bootloader menu
  • Finish


3 Upload Main Program

  • Select the File menu> Examples> 01.basics> Blink
  • Replace the word LED_Builtin, follow this program:
led = 3;

void setup() {
pinMode(led, OUTPUT);
}

void loop() {
digitalWrite(led, HIGH);
delay(1000);
digitalWrite(led, LOW);
delay(1000);
}
  • Connect a LED to PB3 PIN.
  • If it blinks for 1 second, the program we have succeeded.


Download Datasheet ATtiny13

I hope this article is useful