Talking Electronics PIC Theory
                                      5x7 VIDEO SCREEN

Construction

THE CIRCUIT
The complete circuit for the 5x7 Video Screen project is shown below:

HOW THE CIRCUIT WORKS
The circuit relies on a program in the PIC16F84 chip to activate the LEDs and piezo diaphragm. This program is "Burnt" into the chip during "Programming" or "Burning" or "Downloading."  Without a program, the circuit does nothing.
Depending on the complexity of the program, the LEDs will display different effects. This is fully covered in the "Testing"  "Experiments" and "Piezo Experiments" sections.
Only one column of LEDs is shown in the diagram. The next column "taps" off the 100R resistors as shown and the cathodes connect to a BC 547 "sinking" transistor. There are five columns, making a total of 35 LEDs.
The 4017 "counter" chip has 10 outputs with one output going HIGH at a time. The chip is firstly reset by taking pin 15 HIGH then LOW and keeping the line low - this allows the chip to "clock." 
The first output (pin 3) goes HIGH and this is connected to the first transistor via a 2k2 base resistor. The transistor turns on and the cathodes of the first column of LEDs connect to the 0v rail. 
The LEDs are turned ON by delivering current from the PIC chip. When any of the output lines of the chip go HIGH (RB0 to RB6), the corresponding LEDs are illuminated. The 100R resistor limits the current to about 25mA as this is the maximum the chip is designed to deliver. 
The output lines of the chip correspond to portB (file 06) and by turning off these lines, clocking the 4017 then turning on the outputs again, the second column of LEDs will be illuminated. This is repeated for the 3rd, 4th and 5th columns. When this is repeated at a rate above 50 times per second, the whole screen of LEDs appears to be ON at the same time. This is how a picture or effect is produced on the screen - it's called scanning.
The 8th line of output port B (RB7) is connected to a driver transistor. This transistor is connected to a piezo diaphragm and two output pins are provided on the board to drive a 5v relay or globe, instead of the piezo. 
The project includes a 1k resistor as load resistor for the driver transistor but a 10mH choke can be placed across the piezo to increase its output.
Three switches are provided on the board (SwA, SwB and SwC). When these switches are pressed, they provide a HIGH on the corresponding input line. The PIC chip must be programmed so that port A, (bits 2, 3 and 4) (RA2, RA3 and RA4) are inputs. 
The 220R resistors connected in series with the switches prevent damage to the chip. If the output is programmed to be LOW and the switch is pressed, a high current will flow into the chip if a resistor is not included. The 10k resistor is a voltage divider with the 220R to produce a HIGH when the switch is pressed. When the switch is not pressed, the 10k provides a LOW to the input line. 
The PIC chip has an internal oscillator that requires either a crystal or resistor/capacitor components to be fitted to determine the frequency of oscillation. 
A 4k7 resistor and 22p capacitor will produce very near 4MHz.
The chip can be clocked at DC (called single-step mode) or as high as 4MHz. 
A power diode on the supply line drops the 6v to about 5.4v as the PIC chip requires a voltage below 5.5v. The diode also serves as a reverse-voltage protection. 
The 100n across the chip prevents high-frequency instability and the 100u electrolytic removes ripples from the supply line. 

ASSEMBLING THE PC BOARD
The PC board is a single sided design and special wiring will be required on the underside of the board to join the columns of LEDs. 
The connections could have been done with a double-sided PC board but this would have added to the expense of the project. 
All you have to do is join the cathodes of each LED together with a fine wire and take the end to the collector of the column transistor. There are five columns and each wire must 

Before snipping the leads of the LEDs close to the board, you have to leave the cathode leads 3mm longer so that the joining wire can be above the underside of the board. The rigidity of the wiring will keep everything from touching each other. 
Fine tinned copper wire is included in the kit for this purpose.

TESTING THE DISPLAY
When all the LEDs,  transistors, switches, resistors IC sockets and all other components have been fitted, the LED display should be tested to make sure all the LEDs are working. 
there are 3 possible causes for a LED not to illuminate. 
1. Dry joints on the underside of the board, 
2. LED fitted around the wrong way, and 
3. Soldering-time too long or the soldering iron too. LEDs can easily be damaged by excessive heat and this will cause their brightness to be reduced. 
Set-up a very simple piece of test gear by connecting a 470R resistor to a battery-snap and a stiff wire (cut from a resistor) to the other lead.
Place the positive probe on the 100R resistor and the negative lead on one of the collectors. One of the LEDs should illuminate. Try each of the 100R resistors and all the LEDs in a column should illuminate.
Repeat with the collectors of the other transistors.
Replace any faulty or weak LEDs as the display must have uniform brightness.

CRYSTAL OSCILLATOR
The 5x7 Video Screen project uses a Resistor/Capacitor (R/C) network for the microcontroller oscillator so that the chip operates at approximately 4MHz. This frequency is not critical and so non-accurate components can be used. 
During burning, the chip can be programmed for one of four different types of oscillators (Crystal, Resistor/capacitor, Low-power crystal - such as 38kHz watch crystal -  or HS). If Crystal is selected (such as 4MHz), the chip will not work if Resistor/capacitor components are connected to the "clk in" pin. The same applies if RC is selected during programming. The chip will not work if a crystal is connected to pins 15 and 16. 
Once you know this, you will not fall into any traps. 
If you are producing a program for notes and tunes you will find it handy to be able to design with an accurate crystal frequency, then convert to RC components in the final production-run. 
The circuit below shows how to switch between RC and Xtal.