Usb keyboard as lots of switches for arduino?

I was just wondering if anybody here knows what would have to be done to use a usb keyboard with the arduino mega ADK to control the outputs of the mega basically a big keypad

rickharris2 years ago

The keyboard has a lot of normally open switches set out in a matrix. One side is connected to 5 Volts the other to a chip which decodes the keyboard matrix.

See if there is a library to decode ASCII codes - that's what the keyboard sends after the matrix is decoded.

Otherwise you could write a matrix decode routine all for your self. you can work out what is what with a multi meter or LED and battery so you can see which switch effects which input on the decoder.

It's is always worth a search her as well as many subjects are already covered.

https://www.instructables.com/id/Hacking-a-USB-Keyb...

https://services.brics.dk/java/courseadmin/dintdes...