Deluxe version

The basic circuit for the deluxe demo board is illustrated above.

The PIC16F84 microcontroller is designated IC1 and shown together with the components which allow it to be programmed from the computer, using the MPASM software. The physical pinout diagram for the PIC16F84 is shown on the PIC16F84 Specifications page of this Reference section.

To program IC1, a 12V to 14V supply is switched by S1 to its control pin 4. The LED D1 indicates when S1 is switched on. In non-programming mode, pin 4 is held at about 4.4V via diode D2.

Switch S2 is the Reset control, switching it on takes IC1 pin 4 to 0V, holding the chip reset. Resistor R2 protects the power lines at this time.

Switches S3 and S4 are intended for switching the computer's printer port data lines D0 and D1 in and out of circuit with IC1 pins 12 and 13. This option prevents any possibility of the two sets of data lines affecting each other when the PICmicro MCU is actually running a program.

The PICmicro MCU is programmed with a stream of serial data (not parallel). Line D0 carries the data, line D1 carries the clock signal.

There is a choice of clock oscillator techniques offered, either RC (resistor-capacitor) or crystal controlled. Switch S5 is for changing over between the two.

The frequency generated using the RC oscillator is variable by preset potentiometer VR1 across a range determined by capacitors C1 and C3. Different frequency settings will be used at various stages throughout these tutorials.

Capacitor C3 is only used in the early tutorial sections in order to severely slow down the rate at which individual PICmicro MCU instructions are performed. It will later be disconnected by removing the linking connector to increase the operational rate; you will be told when.

The crystal oscillator is only used towards the end of the series when an accurate clock frequency is beneficial. In other prototyping applications, crystals having different frequencies could be used in place of the 3.2768MHz device shown. This, though, would require the existing crystal to be removed by desoldering.

Although switch S5 is used to physically change between RC and crystal modes, the PICmicro MCU needs to be configured for the mode chosen through an initialisation program. Failure to do so will prevent the PICmicro MCU's internal oscillator from working. Crystal initialisation is discussed in Tutorial 25.

Although the circuits and printed circuit board have been designed specifically for these tutorials, the whole set-up, with the LCD and LED modules plus the additional Port B push switches options, will be of enormous value when prototyping your own PIC16F84 designs in the future.