In the previous blog post in this series, we installed the programmer software on the Nano and placed the last components to be able to program an ATtiny85 chip. New ATtiny85 chips need to be prepared to take Arduino sketches by burning a bootloader. In this post, we go through the steps of configuring the Arduino IDE for programming ATtiny85 and burning the bootloader to ATtiny85.
THIS BLOG POST IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THIS HOWTO OR SOFTWARE OR THE USE OR OTHER DEALINGS IN THIS BLOG POST.
Verify ATtiny85 Placement
TODO Put macro image here
Connect Nano and Start Arduino GUI
Connect the Nano via USB to your computer for the Arduino GUI to be able to find its COM port. Note the slowly pulsing green LED to indicate the programmer software ArduinoISP.ino is running.
Configure for ATtiny85
We need to set the appropriate settings in the Arduino GUI for programming the ATtiny85. For the purpose of these blog posts, we will leave most settings on their default value.
Select the ATtiny85 Board
Tools -> Board -> ATtiny Microcontrollers -> ATtiny25/45/85
Note that the Tools menu now has additional items, related to the ATtiny:
First select the correct COM port.
Tools -> Port -> COM<x>
Verify Board Selection
Make sure you have the correct board selected. It should show ATtiny25/45/85.
Tools -> Get Board Info
BN: ATtiny25/45/85 VID: N/A PID: N/A
Select OK to close the popup window.
Tools -> Clock -> Internal 8 MHz
Tools -> Processor -> ATtiny85
Select the programmer for ISP you want to use. You may still have this selected from when it was set in the last blog post.
Tools - Programmer -> Arduino as ISP
Burn the Bootloader
Note that you only have to burn the bootloader once on a newly arrived chip. You have prepared the configuration and can now burn the bootloader.
Tools -> Burn Bootloader
The output window shows the technical details of erasing the chip, installing the bootloader and the verification.
avrdude: Version 6.3-20201216 Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/ Copyright (c) 2007-2014 Joerg Wunsch ... detailed info ... avrdude: Device signature = 0x1e930b (probably t85) avrdude: Send: Q   avrdude: Recv: .  avrdude: Recv: .  avrdude done. Thank you.
The ATtiny85 is now prepared with the bootloader and is ready to receive sketches. Sketches that work on e.g. Uno, will not automatically work on ATtiny85. They need to be adapted in a process called porting. More on that in the next blog post.