With a functioning power supply and a fresh 9 volt battery, we will begin assembling the remainder of the circuit. It is very important to have a good 9 volt power supply as a weak supply will cause the microcontroller to act unpredictably.


Consulting the pin diagram in the data sheet, we see the VCC pin is pin number 10. VCC is the positive voltage to be applied to the microcontroller. In this case, it is 5 volts. The pin labeled AVCC is the positive reference voltage for the analog input. We will not go into the analog functions in this manual so it is not necessary to connect the pin. The ground is pin 11 labeled GND.


The reference diagram for the connections is shown in figure 8.1.



Figure 8.1


Connect a jumper between pin 11 and the horizontal ground circuit and another jumper between pin 10 and the horizontal positive voltage circuit. Notice I chose black for the ground jumper and red for the positive jumper. It is not necessary, but it helps to visualize the paths in your circuit if the jumpers are color coded.



Figure 8.2

Powering the Microcontroller