Knight Rider

Update: There was an error on the schematic.
The JK FlipFlop was wired incorrectly.
Note to Self: Always test your circuits before posting...

I was shooting the breeze one day about the good old days with some friends of mine, and we were reminiscing about our car days, and I was mentioning about a circuit I made during college back in the early 90's that duplicated the Knight Rider scanner in the front of the car.
Having been re-inspired, I set out to find the old schematic I had drawn
then, but alas, it was not to be found no matter how many times I looked in the same places. But, I did remember enough to scratch it down again. I will add some photos and video of the working circuit once I acquire some missing parts...

    The following is a schematic, description, and outline of how it works. This circuit could be easily implemented with a modern microcontroller, but for nostalgia purposes, I've recreated it using logic only.

Fig 1. Click for larger image.
Vcc is +5V.

    Fig 1 shows the schematic for the lighting system. It consists of 5 main sections:

    At the beginning is IC3 - a 555 timer chip. Used for its simplicity, the key components are R1 - 1.7K, C1 - 25uF, and R2/R3 - 10K pot + 100 ohm. Using the pot, the frequency range is f=1.44/C1*(2*R1+R2+R3)

In this case R2+R3 can range from 100 - 10100 ohms.
Which gives us:
Flow = 1.44/25uF*(2*1700 + 10100) =  4.2 Hz

Fhigh = 1.44/25uF*(2*1700 +100) = 16.5 Hz

    The next stage is the heart of the system, the counter. Here I am using the 74LS191 4 bit Up Down Binary Counter.
Most of the pins associated with the counter are not used and left open. Only the Up/Down(U/D), Counter Enable (CTEN), Clock(CLK) inputs and Qa-Qc outputs are used. Because the CTEN is tied low, the counter will always count while the clock is running, and the direction will be determined from the J-K flip flop /Q.

    After the counter is the 74LS138 3 to 8 line decoder. This will take our binary count and activate the LED associated with it. It too is wired to be active all the time.
    The last stage in the pipeline is the LED and decay circuit itself consisting of Q1, R4, R5, C2, and LED's 1 thru 8.
Since the outputs of the decoder are active low, I needed a way to charge C2 when the line goes LOW. Using a PNP transistor here gives me that option. When the base of the transistor goes LOW (like when you want that LED on), current flows through the base turning on the transistor. The quick and dirty LED current calculation is:

Iled = Vcc - LED forward voltage / R5
= 5 - 2 / 220
= 13.6mA

    Since the base current = 4.3/4700 = 0.91mA, multiply this by the gain of the transistor, in this case approx. 100, yields a potential collector current of 91mA. This is 7 times the LED current, thereby ensuring that the transistor is saturated and virtually all 5 volts will be applied to the capacitor.
    Once the base becomes HIGH, the transistor will be "OFF". At this point, the charge stored in the capacitor begins to flow through R5 and the LED. The capacitor will bleed off charge at a given rate which is what gives us the fade out effect. You can change the fade time by increasing or decreasing the capacitor value, or you can decrease it by changing the resistor in series with the LED or by putting a resistor in parallel with the capacitor.

    The final part of this circuit is the feedback control from the 74LS76 dual J-K flip flop. The /Q of the flip flop toggles when ever J=1 and K = 0 or J = 0 and K = 1. Both of these conditions occur depending on which end the count is at.

    This circuit could easily be expanded to 16 LED's with the use of a 74LS154 4 - 16 line decoder and additional LED stages. Simply wire up the remaining counter line (Qd), and attach the K line on the flip flop to Y15 instead of Y7.

Here is the parts list if you want to build your own Knight Rider light out of discrete parts:
  • 1 - 555 Timer
  • 1- 74LS191 Counter
  • 1- 74LS89 J-K Flip Flop
  • 1- 74LS138 3 to 8 Line Decoder
  • 1- 100 ohm Resistor
  • 1- 1.7K ohm Resistor
  • 1 - 10K Potentiometer
  • 8 - 4.7K ohm Resistor
  • 8 - 220 ohm Resistor
  • 1 - 25uF 10V Capacitor
  • 8 - 1000uF 10V Capacitor
  • 8 - 2N3906 Transistors
  • 8 - LED's
    View the various pinouts for the IC's here.
Copyright © 2011 by 100RandomTasks. All rights reserved.