Discussion in "ARM Development" started by    mhel    Jan 18, 2008.
Fri Jan 18 2008, 02:54 am
#1
hi,
cant' figure out where to post this q, so i chose here instead.
any1 happen to have a ps2 keyboard driver that support host to keyboard com.
i have a working keyboard setup now but no provision of enabling caps lock etc..
it's based on appnote from atmel.

tia.
Mon Feb 04 2008, 01:10 am
#2
Mon Feb 04 2008, 01:12 am
#3
may be this link also help you
http://www.beyondlogic.org/keyboard/keybrd.htm
Mon Feb 04 2008, 02:10 am
#4

i have a working keyboard setup now but no provision of enabling caps lock etc..



well that means you have got the basic code + setup ready and tested it somehow.. gr8!!
now regarding the additional functionality it all depend s on your logic/code..
normally we set a flag for caps lock or numlock ... etc...
once the capslock flag is set call the toupper() and get the problem solved... but is CAPS lock your only concern???
Mon Feb 04 2008, 03:09 am
#5
Thanks for replies guys.

I have attached the code I'm using which works only for keyboard to host communication.
My main concern actually is to reset the keyboard, and to be able to use the extended keys,
e.g up/down arrows , num lock.
Right now, when I reset the uController (LPC2138) it sometimes screws up the keyboard, the kb clock pin is connected to P0.14 which is also the BSL. I found a workaround which is to hold the clock line low a little longer during bootup, it works but as I said just a workaround.
Attachment
 shyam like this.
Mon Feb 04 2008, 07:46 pm
#6
hi mhel,
buddy u cud have posted this thing in the arm development forum too...!!!
so gud u to have u !! .. u always come up with interesting ideas... i wud like to learn to interface a PS/2 kbd on my 2148 too... where to get started????
Mon Feb 04 2008, 09:58 pm
#7
Shyam:

I attached the original code that got me started, can't remember where I got it tho. I base my setup from the schematic in the PDF, and from the link "TPS" posted. I wasn't sure if all keyboards have built in pullup so I used external ones. I was told it is preferable to use pins with open drain, so I used the pins reserved for I2C's namely P0.3 & P0.14, I could have used the pair of pins,( e.g P0.2:P0.3) but an External interrupt pin is needed for the keyboard clock, and P0.11 is used for something else, that's why it has to be P0.3 & P0.14. I'm also told that open drain is not necessary I could have also used a couple of transistors instead. I didn't like the constant flipping of the interrupt edge polarity of the original code, I found a different implementation which is what I used in the code on the previous post.


Ajay: maybe you can move this thread to the Arm forum.
Mon Feb 04 2008, 10:59 pm
#8
Hi mhel thank you for your info on PS2 Keyboard..
can you provide your ARM library for PS2 Keyboard? i can add it in download section.

PS: moved thread to ARM development section another great addition..
Wed Feb 06 2008, 12:39 am
#9
Ajay:
that's all there is. the driver is in my first post with attachment, the only missing is the extint.h header which is basically just the declaration of interrupt plus the 1 define for the edge. let me know if there's something else missing.

Wed Feb 13 2008, 11:43 pm
#10
hi mhel!!!

here is something interesting that we can do!!!!...

Graphical Lcd plus PS2 mouse whatsay???

y not make a desktop appearance using the above two...
ia lready started... looking for your contributions

Get Social

Information

Powered by e107 Forum System

Downloads

Comments

Michailqfh
Fri Mar 29 2024, 01:53 am
Bobbyerilar
Thu Mar 28 2024, 08:08 am
pb58
Thu Mar 28 2024, 05:54 am
Clarazkafup
Thu Mar 28 2024, 02:24 am
Walterkic
Thu Mar 28 2024, 01:19 am
Davidusawn
Wed Mar 27 2024, 08:30 pm
Richardsop
Tue Mar 26 2024, 10:33 pm
Stevencog
Tue Mar 26 2024, 04:26 pm