IBM 45U0018 POS Keyboard
I saw this unit on eBay and couldn't resist. It really did remind me of the department store POS keyboards and I remember them being clicky. I checked the photos on the auction and saw that it had a non-standard socket and no cable included. You can download the drivers/configuration-utility here.
The main keys are fixed, but the surrounding keys have optional translucent key 'covers' where inserts have been placed for special functions. Some of them even cover standard keyboard keys.
But yeah, back to the socket, and do excuse the photo...
It's very similar to a standard IDC Header, but in-set which makes it really difficult to use anything other than IBM's proprietary cables. After a lot of googling, I found that there's both a USB and PS/2 cable version available.
Unfortunately, these weren't actually available anywhere... and if they were, the cost was out of control. It seems that these keyboards could also just dock onto the POS system above the till, so it's possible that the cable was only required if you wanted to mount the keyboard elsewhere. Anyway, a cable would be too easy... I'm sure we can work this out!
What does it look like on the inside?
With the hunch that the port supported PS/2 and USB, the keyboard was opened to work out the pinout. Opening it was actually very easy with just 6 small screws on the back. A large plate comes off and then there's just a bit of foil-cardboard shielding over the main circuit board.
Inside, of note, were a TUSB2046B IC and a STM32F103VBT6 Microcontroller with V0326_PF.bin programmed into it. The first IC happens to be the brains for a USB 4-port hub and provided a huge hint for determining the unit's wiring. I started tracing along the pins and the table below is the result.
Note that, when looking at the back of the keyboard into the socket when the keyboard is UPSIDE-DOWN on a flat surface, I've started Pin 1 from the top-right, with pin 6 then being top-left, pin 7 bottom-right and pin 12 bottom-left. This turned out to be silly as all the wires are in vertical pairs. Note this has been updated from the great resource at sharktastica.
Pin # | Connected To | Notes | USB Cable |
---|---|---|---|
1 | Pin 1 of T-46 aka TPS73633DBV | Voltage supply for the power regulator. Must be 5v! | Pin 1 - Red |
2 | Pin 1 of TUSB2046B | DP0 = Root port USB differential data plus. DP0 paired with DM0 constitutes the upstream USB port. | Pin 3 - Green |
3 | NC? | ||
4 | Pin 3 (or 6) of U4 | U4 is not populated. | |
5 | Pin 64 (PC7) of STM32F103VBT6 Microcontroller | PS/2 Keyboard Clock | |
6 | Pin 48 (PB11) of STM32F103VBT6 Microcontroller | PS/2 Mouse Clock | |
7 | GND | Pin 4 - Black | |
8 | Pin 2 of TUSB2046B | DMO = Root port USB differential data minus. DM0 paired with DP0 constitutes the upstream USB port. | Pin 2 - White |
9 | NC? | ||
10 | Pin 2 (or 7) of U4 | U4 is not populated. | |
11 | Pin 66 (PC9) of STM32F103VBT6 Microcontroller | PS/2 Keyboard Data | |
12 | Pin 52 (PB13) of STM32F103VBT6 Microcontroller | PS/2 Mouse Data |
Ok, so that's easy for the USB connection.. just wire the 'upstream' pins, +5v and GND into a spare USB cable. The other 2-pair of wires which run into the Microcontroller must be for the PS/2 mouse and keyboard? I wonder which is clock and which is data? There are plenty of images online showing microcontroller-to-PS/2-port hookups, so I'll try that after USB.
Hooking Up USB
USB cables contain 4 wires. First you need two wires for a very standard 5v DC rail and then you need two more wires to transmit and receive data. As you can see from the table above, we have all of these already mapped out. This was all very straight-forward thanks to the documentation for the TUSB2046B USB Root Hub IC. I grabbed a bunch of spare parts from the box'o'junk and started wiring something together. The USB cables I first tried to use happened to be power-only? No data lines! No wonder someone else threw them out.
Too short anyway! So instead, I remembered I had a mini USB socket in another tray'o'junk and set to wiring that up...
I plugged it into my RasPi 400 and it evicted all USB devices...
Sep 2 17:04:30 raspberrypi kernel: [63187.047153] usb usb2-port1: over-current change #1 Sep 2 17:04:30 raspberrypi kernel: [63187.202027] usb 1-1-port1: over-current change #1 Sep 2 17:04:31 raspberrypi kernel: [63187.278524] usb usb2-port2: over-current change #1 Sep 2 17:04:31 raspberrypi kernel: [63187.438880] usb 1-1-port2: over-current change #1 Sep 2 17:04:31 raspberrypi kernel: [63187.518607] usb usb2-port3: over-current change #1 Sep 2 17:04:31 raspberrypi kernel: [63187.678902] usb 1-1-port3: over-current change #1 Sep 2 17:04:31 raspberrypi kernel: [63187.758546] usb usb2-port4: over-current change #1 Sep 2 17:04:31 raspberrypi kernel: [63187.918864] usb 1-1-port4: over-current change #1 Sep 2 17:04:31 raspberrypi kernel: [63187.998562] usb usb2-port1: over-current change #2 Sep 2 17:04:32 raspberrypi kernel: [63188.238478] usb usb2-port2: over-current change #2 Sep 2 17:04:32 raspberrypi kernel: [63188.478480] usb usb2-port3: over-current change #2 Sep 2 17:04:32 raspberrypi kernel: [63188.718503] usb usb2-port4: over-current change #2 Sep 2 17:04:32 raspberrypi kernel: [63188.890074] usb 1-1-port1: over-current change #2
Ooops! Why am I chewing too much power? I google'd around and couldn't find an easy solution to inject my own power, as all answers indicated VCC needed to stay connected. Looking at my wiring again, I realised that this error was bound to happen as I'd wired the polarity around the wrong way! So, after correcting that...
Sep 2 18:44:47 raspberrypi kernel: [69203.309095] usb 1-1.3: new full-speed USB device number 9 using xhci_hcd Sep 2 18:44:47 raspberrypi kernel: [69203.443182] usb 1-1.3: New USB device found, idVendor=0451, idProduct=2046, bcdDevice= 1.25 Sep 2 18:44:47 raspberrypi kernel: [69203.443193] usb 1-1.3: New USB device strings: Mfr=0, Product=0, SerialNumber=0 Sep 2 18:44:47 raspberrypi kernel: [69203.449815] hub 1-1.3:1.0: USB hub found Sep 2 18:44:47 raspberrypi kernel: [69203.452677] hub 1-1.3:1.0: 4 ports detected Sep 2 18:44:47 raspberrypi kernel: [69203.779047] usb 1-1.3.4: new full-speed USB device number 10 using xhci_hcd Sep 2 18:44:47 raspberrypi kernel: [69203.922725] usb 1-1.3.4: New USB device found, idVendor=04b3, idProduct=4604, bcdDevice= 3.26 Sep 2 18:44:47 raspberrypi kernel: [69203.922734] usb 1-1.3.4: New USB device strings: Mfr=1, Product=2, SerialNumber=3 Sep 2 18:44:47 raspberrypi kernel: [69203.922741] usb 1-1.3.4: Product: IBM Retail USB Alphanumeric POS Keyboard Sep 2 18:44:47 raspberrypi kernel: [69203.922747] usb 1-1.3.4: Manufacturer: (c) Copyright IBM Corp. 2008 Sep 2 18:44:47 raspberrypi kernel: [69203.922752] usb 1-1.3.4: SerialNumber: 44T4011-200811231006420977000036 Sep 2 18:44:47 raspberrypi kernel: [69203.935428] input: (c) Copyright IBM Corp. 2008 IBM Retail USB Alphanumeric POS Keyboard as /devices/platform/scb/fd500000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/usb1/1-1/1-1.3/1-1.3.4/1-1.3.4:1.0/0003:04B3:4604.000D/input/input18 Sep 2 18:44:47 raspberrypi kernel: [69204.000545] hid-generic 0003:04B3:4604.000D: input,hidraw4: USB HID v1.00 Keyboard [(c) Copyright IBM Corp. 2008 IBM Retail USB Alphanumeric POS Keyboard] on usb-0000:01:00.0-1.3.4/input0 Sep 2 18:44:47 raspberrypi kernel: [69204.008558] hid-generic 0003:04B3:4604.000E: hiddev97,hidraw5: USB HID v1.00 Device [(c) Copyright IBM Corp. 2008 IBM Retail USB Alphanumeric POS Keyboard] on usb-0000:01:00.0-1.3.4/input1 Sep 2 18:44:47 raspberrypi kernel: [69204.016919] hid-generic 0003:04B3:4604.000F: hiddev98,hidraw6: USB HID v1.00 Device [(c) Copyright IBM Corp. 2008 IBM Retail USB Alphanumeric POS Keyboard] on usb-0000:01:00.0-1.3.4/input2 Sep 2 18:44:47 raspberrypi kernel: [69204.035363] input: (c) Copyright IBM Corp. 2008 IBM Retail USB Alphanumeric POS Keyboard as /devices/platform/scb/fd500000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/usb1/1-1/1-1.3/1-1.3.4/1-1.3.4:1.5/0003:04B3:4604.0010/input/input19 Sep 2 18:44:47 raspberrypi kernel: [69204.036075] hid-generic 0003:04B3:4604.0010: input,hidraw7: USB HID v1.00 Mouse [(c) Copyright IBM Corp. 2008 IBM Retail USB Alphanumeric POS Keyboard] on usb-0000:01:00.0-1.3.4/input5 Sep 2 18:44:47 raspberrypi mtp-probe: checking bus 1, device 10: "/sys/devices/platform/scb/fd500000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/usb1/1-1/1-1.3/1-1.3.4" Sep 2 18:44:47 raspberrypi mtp-probe: bus: 1, device: 10 was not an MTP device Sep 2 18:44:48 raspberrypi mtp-probe: checking bus 1, device 10: "/sys/devices/platform/scb/fd500000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/usb1/1-1/1-1.3/1-1.3.4" Sep 2 18:44:48 raspberrypi mtp-probe: bus: 1, device: 10 was not an MTP device
HAHA. It just worked. It's very loosely-clicky, but not bad at all. Hilariously sounds like the registers at David Jones. The trackpad and touchpoint actually work beautifully as well. Very impressive. I assume there's further commands that could be sent to change LEDs, use the peripherals, but I don't need it.
PS/2 Wiring
I didn't feel like plugging this into a PC and restarting it 17 times to work out the wiring, so I used an Arduino Uno instead! Unfortunately, no combination of pairs would get the unit to produce any output. I'll have to do some more digging at some point in the future... a cop-out, I know, but I'm happy with USB for now!
UPDATE: There's a pinout here at sharktastica.
Printing a proper plug
I searched Thingiverse and found a very nice set of IDC Plug Frames. I then dragged that frame into Tinkercad and stretched it to make it fit better. The result is here.
From there, I used standard 'single' jumper wires to build the 6x2 inner plug and glued them in place. I then soldered up a spare USB cable.
Perfect! Note there's still plenty of these keyboards on eBay from a WA seller. Highly recommended!
February 19th, 2022 - 05:21
Would you be able to go over which pin you connected the usb to in more depth?
February 23rd, 2022 - 11:57
Cheeki,
Cut open a USB cable and wire up red to pin 1, black to pin 7, green to pin 2 and white to pin 8.
February 24th, 2022 - 05:02
Cheers, going to test this out with my keyboard to see if I can get the card reader working
March 10th, 2022 - 04:40
I’ve hooked it up to these pins but I don’t see any activity on the keyboard and it isn’t recognized by my RPI
March 15th, 2022 - 18:41
Apologies for this! I realised my mistake and have now added a diagram and correctly worded the pinouts above. Please try again!
March 16th, 2022 - 04:51
Tried again with the new diagram and it work flawlessly, cheers!
March 16th, 2022 - 10:01
Great news! Thanks for the feedback.
December 12th, 2022 - 22:47
Did you find the IBM Modular Device Utility program to program the keys?
July 28th, 2023 - 08:25
Apologies. I never did try and I can’t find the software now during a quick search. If you do come across it, then please post a link here!
July 27th, 2023 - 22:24
how do I reassign keys on ibm/toshiba keyboards?
July 28th, 2023 - 08:25
Hi tatarin, It’d be via the IBM Modular Device Utility as Enver mentioned above, but it can’t be found.
July 31st, 2023 - 15:52
Hi stevenh, they helped me on reddit
https://www.reddit.com/r/modelm/comments/u3mqpm/sharks_wiki_page_on_the_buckling_sleeve_modular/