Thursday, 2 January 2014

555 Basic Timer Circuit With LED on Output

This is the basic configuration for using the 555 Timer IC.  This circuit includes an LED on the output for visual feedback but the output can be connected to another circuit where a clock input is needed.


Hardware Needed

  • (1) 555 Timer IC
  • (1) LED
  • (2) 330Ω Resistors
  • (1)  µF Capacitor
  • 9V Power Supply



Experimenting Further

The timing function is regulated by the resistors and capacitors.  Replace R3 with a different value resistor or even a variable resistor or potentiometer to see the results.
Change the duty cycle
Remove R2 and LED1 and connect to another circuit.

2 Transistor 2 LED Flasher

This is a 2 transistor astable multivibrator flashing LED Circuit.


Hardware Needed

  • (2) 2n2222 NPN Transistors
  • (2) LEDs
  • (2) 330Ω Resistors
  • (2) 10µF Capacitors
  • 3V-9V Power Supply

Schematic








Tuesday, 31 December 2013

DIY Cheap Keyboard Encoder

I have been thinking about building a pinball machine and at first, I thought about using an Arduino as the controller.  After giving is some thought, I decided that I would use a computer as the controller and use an Arduino for some specific functions in addition to the computer.

Oh ... and I wanted it to be cheap.

So how do you get all of the switches that you need for a pinball machine to communicate with the computer?  The first idea was through the Arduino but really didn't seem practical and it certainly was not the cheapest and easiest solution.

I started researching and found an interesting product in the I-PAC.  The price was reasonable and the product looked solid but at about $45, I thought I could do better.  After some research on building a custom keyboard encoder, I had my "light bulb" moment:  every USB keyboard has a built-in keyboard encoder that can be cannibalized.  If I didn't have a spare USB keyboard, I could buy one at the dollar store for $3.

I bought the dollar store keyboard and disassembled it.
This is the underside with the switch membrane removed. 

The keyboard encoder is simple enough.  The connections are arranged into Rows and Columns to form a matrix.  Pushing a key closes the connection between a row and column.  It is the job of the keyboard encoder to check the rows and columns and send a signal to the computer with the code for key pressed.

Here is the circuitry from the keyboard.  They leads on the printed circuit board were coated in a black substance which I scraped off to test the unit.

After plugging in the USB connection to the computer, I used a small jumper wire to connect random rows and columns to see what would happen.  Using the program Notepad in Windows, here are the results:
 
You can see that the keyboard encoder works and sent characters to the computer.  Since this is a 101 key keyboard, I have at least 101 inputs available for switches.  Here is my cheap keyboard emulator!

This system works for mechanical SPST (single pole single throw) switches but I also need to include some sensor switches and I haven't figured out how I am going to do that yet.  If you have ideas, I would like to hear them in the comments section.