Using a laptop keyboard as usb keyboard

bentendo64

Active Member
Well, I don't really know what I should be looking up on google for this, but I have a gutted ibook G4 that I am planning on using for a raspberry pi laptop project. For the keyboard, I'll either have to find an external usb one of about the same dimensions, or find some sort of an adapter that works to interface the original keyboard to usb. It's just a ribbon cable coming off of the back of it, so I was wondering if anyone knew if these normally have some sort of standard interface as to how the keys are mapped, so I could take apart a different usb keyboard and just plug it in? Or maybe some sort of pre-made adapter exists for this sort of thing? Anyway, I'm not planning on getting started with this project until this summer (I don't even have any supplies here in Fargo....) but I'm planning ahead.
 
Generally, laptop keyboards are just a key matrix and everything is done on the mobo, so you'd have to figure out the pinout for the matrix. Depending on the number of pins, you may be able to use the gpio pins, but you'll probably need to program a chip to encode the key presses into USB standards.

in my short searches, though, there was some talk of the keyboard being USB, so in the unlikely circumstance that it is only 4 pins, maybe try that?

I'd say the easiest way to find the pinout would be to buy a replacement keyboard, or a busted up g4 'for parts' and take the board apart. From there, scan all the bits and bobs, desaturate, shoot the contrast way up, and start using the paint bucket on the different lines to see where what intersects.
 
I thought about the gpio pins, but then I realised I'm not very good at programming. Also, it would be harder to drop in some other single-board computer in the future if I ever plan on upgrading it.

The laptop is all in pieces, and the keyboard is indeed just a regular key matrix thing. The ribbon cable has quite a few pins, so it is not usb.

I suppose mapping it out would be the best bet. Who knows, maybe it'll map right onto this Apple usb keyboard I have. If not, there are probably programs out there for TI msp430, or an AVR that will do usb without any other hardware. Then I'd just have to write up the part for the keyboard.
 
Back
Top