The most important part when we start a project involving electronics is to have knowledge of the capabilities and incapacities of the components we are using.
For this it is important to see the data sheet of the components!
This week, we are programming an attiny44, the data sheet of it we can see here:
The first page of the data sheet shows most of the information about the component.
It is important to know the pins and the description of the pins, to understand where to place the LEDs and buttons, and the AVR and power.
Now is the time to use my ISP to program the Hello-Word board I did on week 6 in electronics design.
To program my hello-world I will use the Arduino program and the USBTinyISP I did in week 4.
For this you need:
1
Connect the USBTinyISP to the hello-world board through the idc cable and connect both cards to the computer.
2
Check if USBTinyISP is being recognized on the computer, so go to the "device manager on windows" or use the lsusb command.
3
4
Burn the bootloader
5
Run the example Blink to check if everything is working.
Now it's time to program the board
Firstly, it is necessary to note which pins are connected to the two LEDs and the button on the board.
The schematic next to it helps you understand the relationship between the output pins of attiny44 and the arduino pins.
The idea is to make a basic digital reading that turns on and off the two LEDs connected to digital pin 6 and 7 by pressing a button attached to pin 4.
The code I ran on the Arduino was:
The programming went well, and both LEDs blink when you click the button. As we can see from the video below.
Find the files used and download here: