Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Interfacing keyboard to microcontroller

Status
Not open for further replies.

Drew

Newbie level 4
Joined
Nov 15, 2004
Messages
6
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
67
keyboard microcontroller

I'm having a problem getting my 5 pin keyboard to interface to my microcontroller. I have the Vcc and GND lines connected to 5V and ground. I'm using an oscilloscope to read the Data and Clock lines but come up short. Even when I'm holding a key down continuously, the oscilloscope doesn't pick up any signals. Do the DATA and Clock lines have to be connected to 5V through external pull up resistors? I thought keyboards had internal pull up resistors. Thanks for any responses.
 

interfacing keyboard to 8051

It is possible that there are no pull-ups inside the keyboard, so you can easily connect ≈4.7kΩ as pull-ups.
What happens when you apply power to the keyboard, do the 3 LEDs flash a couple of times as normal?
 

interfacing keyboard with 8051

The lights don't flash after power up. However, it does work when plugging it into a motherboard. When I press a key continuously should I see signals on the Data and Clocks lines using the oscilloscope? I've tried this test on 3 keyboards already, coming up short each time.
 

keyboard interfacing with 8051

The keyboard should perform a RESET on startup, and this should be visible by looking at the LEDs, they should blink briefly. Check your electrical connections. Also be aware that the KB may need well above 100mA to function properly, so check if your power source meets this requirement.
 

keyboard with microcontroller

Make sure you connect power (+5V and 0V) correctly: it should flash after power is applied.
Both lines, clock and data, are HIGH at the idle stage. When you press a button you should see pulses from High/Low/High ..
Are we talking about the same keyboards: PS/2 .. AT?
 

interfacing keyboard to microcontroller

My bad. The three LED lights DO flash after power up. The Data and Clock lines are held high at 5 V and remain there even when pressing on a key continuously. I'm using an AT keyboard.
 

interfacing keyboard with microcontroller

This is strange. Is the keyboard connected to a microcontroller which I/O pins force the data and/or clock lines to logical 1, by any chance?
 

related:electrosofts.com/8051/keyboard.html

The data and clocks lines are connected to 5V through 5 Kohm external pullups. and to the oscilloscope. There are no connections to the microcontroller. Do I have to give it a permission-to-send command?
 

microcontroller keyboard

No, it needs no special permissions, both clock and data are idle. Very weird. Check your oscilloscope settings.
 

keyboard interfacing with 8051 microcontroller

Maybe this application note is useful for you.
 

keyboard interfacing to 8051

does anybody have some similar code in pic basic pro???
 

interfacing of keyboard with 8051

Is the keyboard connected to a microcontroller? then force the data and/or clock to pull up.
 

interfacing keyboard microcontroller

hi,

if u send the electric diagram it will be much more easy to help u.
r u using bi-directional communication or uni ?? make sure that the microcontroller's control pins are configured as input when using uni direction (in my opinion keyboard-host is enough).
one more thing the ideal state is reached automatically by using the pull up resistors, the micro controller should not force there "1" !!!

avi.
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top