composants:attiny85

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
composants:attiny85 [2019/08/12 19:57] – created mhcomposants:attiny85 [2020/06/01 16:35] (current) – external edit 127.0.0.1
Line 4: Line 4:
  
 {{composants:attiny85-pins.jpg}} {{composants:attiny85-pins.jpg}}
 +
 +===== Programming ======
 +
 +You need an Arduino to act as ISP to flash programs to the ATtiny.
 +
 +Also, the ATtiny85 runs by default at 1MHz so if you want it to run at 8MHz you need to burn the bootloader into it after having selected the appropriate frequency.
 +
 +<WRAP info round 95>
 +
 +**Note :** Arduino in the past did not support ATtiny by default and additional libs had to be provided. 
 +
 +Sooner or later this might not be the case anymore.
 +</WRAP>
 +
 +The Arduino UNO should be flashed with the ISP program : File > Examples > ArduinoISP
 +
 +==== Wiring ====
 +
 +{{composants:programming-attiny85.jpg?480}}
 +
 +//**Note : **The SCK, MISO and MOSI pins can be directly wired to the Arduino's ICSP/SPI header pins. There is a 10μF electrolytic capacitor between RESET and GND (anode in GND) to avoid being auto-reset when we flash programs to the ATtiny//
 +
 +Set Arduino to ISP, usually located in the IDE in Tools > Programmer > Arduino as ISP
 +
 +You can add Heartbeat, Error, Programming LEDs (choose your colors) respectively on 9, 8, 7.
 +
 +
 +
 +
 +===== Ressources =====
 +
 +  *[[https://forum.arduino.cc/index.php?topic=342977.0|Forum post on the 'avrdude: stk500_initialize(): (b) protocol error, expect=0x10, resp=0x01' error. Possibly related to the absence of a capacitor between RESET and GND on linux]]
 +
 +  *[[https://create.arduino.cc/projecthub/arjun/programming-attiny85-with-arduino-uno-afb829|Basic programming tutorial]]
 +
 +  *[[https://www.re-innovation.co.uk/docs/sleep-modes-on-attiny85/|Sleep Mode tutorial]]
  • composants/attiny85.1565632648.txt.gz
  • Last modified: 2020/06/01 16:36
  • (external edit)