Help with xwhatsit and IBM Model F AT
-
- Location: Reno, NV
- Main keyboard: IBM Mod F AT
- Main mouse: Logitech M570
- Favorite switch: Mod F capacitive
- DT Pro Member: -
I recently installed an xwhatsit controller into my original IBM Model F AT.
I’ve spent a couple of days now trying to get this working, and I think I'm likely missing something painfully obvious.
Installing the xwhatsit controller was no problem (I don’t use my vacuum desoldering station much, but it’s really handy when I need it.) When I connect the keyboard to a USB port, all three lock lights come on. My guess is this means the board is in DFU mode, ready to be flashed.
As per the instructions in the eBay listing from which I bought the xwhatsit, I point my browser at 35.164.28.200:5000/#/xwhatsit/ibm to compile some firmware. For the keyboard layout I select “xwhatsit/ibm/fat/xwhatsit”. I click the “Compile” button and it produces a file named “xwhatsit_ibm_fat_xwhatsit_default_6523a7c.hex”, which I download.
I then use QMK Toolbox to connect to the keyboard. After I press the reset button on the controller, it sees the ATmega32U4 controller:
Atmel DFU device connected: ATMEL ATm32U4DFU (03EB:2FF4:0000)
OK, sounds good. At this point I open the downloaded hex file mentioned above and click the “Flash” button. The utility reports success:
Atmel DFU device connected: ATMEL ATm32U4DFU (03EB:2FF4:0000)
Attempting to flash, please don't remove device
> dfu-programmer atmega32u4 erase --force
> Erasing flash... Success
> Checking memory from 0x0 to 0x6FFF... Empty
> dfu-programmer atmega32u4 flash --force /Users/dramsey/Downloads/xwhatsit_ibm_fat_xwhatsit_default_6523a7c.hex
> 0% 100% Programming 0x5680 bytes...
> [>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>] Success
> 0% 100% Reading 0x7000 bytes...
> [>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>] Success
> Validating... Success
> 0x5680 bytes written into 0x7000 bytes memory (77.23%)
> dfu-programmer atmega32u4 reset
Flash complete
Atmel DFU device disconnected: ATMEL ATm32U4DFU (03EB:2FF4:0000)
At this point the middle LED, Num Lock, dims slightly. Sometimes it flickers slightly. The keyboard is otherwise unresponsive. So either there's a hardware problem, or, much more likely, I'm doing something wrong. Hopefully the latter. Any ideas?
I’ve spent a couple of days now trying to get this working, and I think I'm likely missing something painfully obvious.
Installing the xwhatsit controller was no problem (I don’t use my vacuum desoldering station much, but it’s really handy when I need it.) When I connect the keyboard to a USB port, all three lock lights come on. My guess is this means the board is in DFU mode, ready to be flashed.
As per the instructions in the eBay listing from which I bought the xwhatsit, I point my browser at 35.164.28.200:5000/#/xwhatsit/ibm to compile some firmware. For the keyboard layout I select “xwhatsit/ibm/fat/xwhatsit”. I click the “Compile” button and it produces a file named “xwhatsit_ibm_fat_xwhatsit_default_6523a7c.hex”, which I download.
I then use QMK Toolbox to connect to the keyboard. After I press the reset button on the controller, it sees the ATmega32U4 controller:
Atmel DFU device connected: ATMEL ATm32U4DFU (03EB:2FF4:0000)
OK, sounds good. At this point I open the downloaded hex file mentioned above and click the “Flash” button. The utility reports success:
Atmel DFU device connected: ATMEL ATm32U4DFU (03EB:2FF4:0000)
Attempting to flash, please don't remove device
> dfu-programmer atmega32u4 erase --force
> Erasing flash... Success
> Checking memory from 0x0 to 0x6FFF... Empty
> dfu-programmer atmega32u4 flash --force /Users/dramsey/Downloads/xwhatsit_ibm_fat_xwhatsit_default_6523a7c.hex
> 0% 100% Programming 0x5680 bytes...
> [>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>] Success
> 0% 100% Reading 0x7000 bytes...
> [>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>] Success
> Validating... Success
> 0x5680 bytes written into 0x7000 bytes memory (77.23%)
> dfu-programmer atmega32u4 reset
Flash complete
Atmel DFU device disconnected: ATMEL ATm32U4DFU (03EB:2FF4:0000)
At this point the middle LED, Num Lock, dims slightly. Sometimes it flickers slightly. The keyboard is otherwise unresponsive. So either there's a hardware problem, or, much more likely, I'm doing something wrong. Hopefully the latter. Any ideas?
- Muirium
- µ
- Location: Edinburgh, Scotland
- Main keyboard: HHKB Type-S with Bluetooth by Hasu
- Main mouse: Apple Magic Mouse
- Favorite switch: Gotta Try 'Em All
- DT Pro Member: µ
Are you sure your controller is 32u4? As I recall, all of Xwhatsit's original controllers—including the one I installed in my AT—are 32u2. The chip makes a difference. Their hex files are incompatible.
As I recall, I laid out my AT based on this starting point in Pandrew's configurator:
http://35.164.28.200:5000/#/xwhatsit/ib ... LAYOUT_all
Compiling a hex file from there will, I expect, provide a 32u2 binary for the 32u2 controller you're assumed to have. Quite why yours has a 32u4, which QMK Toolbox says it has, I've no idea. That alone is a showstopper. The log suggests you're talking to a 32u4 and successfully flashing it with a firmware: which is 32u2, so bricks your incompatible controller immediately.
Who put a 32u4 in there!?
Also, QMK Toolbox is a badly behaved little bastard when it comes to making guesses about your Atmel chip. It needs handheld all the way.
If it really is a 32u4, maybe Pandrew's QMK can be built from source to support it. It wouldn't be compatible with his layout editor, though. Another option is hoping that someone else added 32u4 controller support, somewhere…
Anyway, I do have the answer for your lock LEDs:
As I recall, I laid out my AT based on this starting point in Pandrew's configurator:
http://35.164.28.200:5000/#/xwhatsit/ib ... LAYOUT_all
Compiling a hex file from there will, I expect, provide a 32u2 binary for the 32u2 controller you're assumed to have. Quite why yours has a 32u4, which QMK Toolbox says it has, I've no idea. That alone is a showstopper. The log suggests you're talking to a 32u4 and successfully flashing it with a firmware: which is 32u2, so bricks your incompatible controller immediately.
Who put a 32u4 in there!?
Also, QMK Toolbox is a badly behaved little bastard when it comes to making guesses about your Atmel chip. It needs handheld all the way.
If it really is a 32u4, maybe Pandrew's QMK can be built from source to support it. It wouldn't be compatible with his layout editor, though. Another option is hoping that someone else added 32u4 controller support, somewhere…
Anyway, I do have the answer for your lock LEDs:
As Xwhatsit says in his manual, the *only* Model F with lock lights is the AT, so I've no idea why he didn't follow this himself! But I do remember rejiggering the pins in my connector and it works.xwhatsit wrote:PC-ATs can be rewired without having to make a new cable by shuffling some pins inside the 6-pin female connector the LED PCB is fitted with. The original IBM mapping—using pin labels from the LED PCB end—is as follows:
A1 Caps Lock LED
A2 Scroll Lock LED
A3 (not connected)
B1 Num Lock LED
B2 GND
B3 VCC
The actual female connector pinout doesn’t match this, so be sure to trace through the wires.
-
- Location: Reno, NV
- Main keyboard: IBM Mod F AT
- Main mouse: Logitech M570
- Favorite switch: Mod F capacitive
- DT Pro Member: -
It is definitely a 32U4; this designation is clearly visible on the controller. So the problem would appear to be that Pandrew's configurator is building a firmware file for the 32U2, which won't work on this as you noted. So I have to find a way to build the firmware file for this chip as opposed to the 32U2. Thanks for the help; I would not have figured this out on my own.
-
- Location: Reno, NV
- Main keyboard: IBM Mod F AT
- Main mouse: Logitech M570
- Favorite switch: Mod F capacitive
- DT Pro Member: -
And the solution is to select xwhatsit/ibm/fat/universal in Pandrew's configurator. This gets things working-- well, except for the "Num Lockl" key, which doesn't activate its LED or change the mapping on the num pad so I can use cursor keys. I suppose the solution there is to download the key map and tweak it manually. Fun!
- Muirium
- µ
- Location: Edinburgh, Scotland
- Main keyboard: HHKB Type-S with Bluetooth by Hasu
- Main mouse: Apple Magic Mouse
- Favorite switch: Gotta Try 'Em All
- DT Pro Member: µ
Very good. That must be the appropriate one for whatever post-Xwhatsit controller version you've got.
Did you rearrange the LED header pins according to Xwhatsit's instructions?
Tweaking the layout in JSON is doable. You just reload them in the configurator to prepare the hex file. It's easy sailing if you have the right base config, which you've found.
-
- Location: Reno, NV
- Main keyboard: IBM Mod F AT
- Main mouse: Logitech M570
- Favorite switch: Mod F capacitive
- DT Pro Member: -
The NumLock key sends the appropriate "Num Lock" key code, but apparently if I want the functionality to switch the Model F's numeric pad to a cursor pad, I'll have to define that as a separate layer (makes sense, really. I keep forgetting that the xwhatsit controller makes no assumptions about many of the keyboard functions) and program the Num Lock key to be a layer switch key. The online QMK Configurator supports layers but it's not obvious how to designate a key as a layer toggle. I'm sure I'll figure it out. Perhaps this can only be done by editing the JSON file.
- Muirium
- µ
- Location: Edinburgh, Scotland
- Main keyboard: HHKB Type-S with Bluetooth by Hasu
- Main mouse: Apple Magic Mouse
- Favorite switch: Gotta Try 'Em All
- DT Pro Member: µ
So, you're on Mac, and this is your first experience hooking up a fullsize mech to one, right?
AT / QMK Numlock is Numlock: this shouldn't be a problem at all. Plug it into a PC and see.
But Macs have never* supported Numlock in all their 40 year history. Any PC keyboard connected to a Mac will do nothing when the Numlock key is pressed. The Mac sees the Numlock keycode and ignores it. There's a couple of ways around that: Karabiner and, as you said, implementing a numpad layer yourself in QMK.
*The pedantic and quite irrelevant exception being the integrated numpad on PowerBook vintage laptops. But even this was hidden from the OS.
You can do it easily enough in the configurator. Use the search box in the lower half of the screen to explore the functions it supports. The one you're after is (types in "toggle"…) TG(layer): simply assign this code to your Numlock key on layer 0 and give it the number of the layer you want it to superimpose when toggled. If you're sneaky, you can send numpad specific 0-9 keys instead of duplicating the number row, as these codes are indeed different. I use this myself for my "universal mousekeys" fallback system.
-
- Location: Germany
- Main keyboard: IBM Model M122 (hopefully soon F122)
Is it also possible to control the Num_Lock LED with Soarer or Karabiner on Mac?
- Muirium
- µ
- Location: Edinburgh, Scotland
- Main keyboard: HHKB Type-S with Bluetooth by Hasu
- Main mouse: Apple Magic Mouse
- Favorite switch: Gotta Try 'Em All
- DT Pro Member: µ
No, it is not. But you’re right: it should be.AngryCockroach wrote: ↑07 Jan 2024, 20:00Is it also possible to control the Num_Lock LED with Soarer or Karabiner on Mac?
As discussed in the link above, this little utility can set all 3 lock LEDs on connected USB keyboards, but the trick lies in triggering it. Karabiner doesn’t play nice. Perhaps something like FastScripts would work if bound to the lock keys. (I used to use it for running a few scripts before I got into the much deeper realm of Karabiner.)
-
- Location: Germany
- Main keyboard: IBM Model M122 (hopefully soon F122)
Thank you, works great with "setleds".
I use it in combination with Soarer and "BetterTouchTool" to send the terminal command when I press the Numlock/Scrolllock key.
Now I can switch between Num Pad Mode and Navigation Cluster Mode and the Numlock LED shows me which I am in. Quite normal with Windows but a bit of work with MacOs...
I use it in combination with Soarer and "BetterTouchTool" to send the terminal command when I press the Numlock/Scrolllock key.
Now I can switch between Num Pad Mode and Navigation Cluster Mode and the Numlock LED shows me which I am in. Quite normal with Windows but a bit of work with MacOs...
Fantastic to hear that "setleds" is working seamlessly for you! Integrating it with Soarer and "BetterTouchTool" to toggle between Num Pad and Navigation Cluster modes on MacOS is a clever solution. It brings a familiar Windows feature to your Mac setup, adding a useful and personalized touch to your workflow.AngryCockroach wrote: ↑08 Jan 2024, 17:39Thank you, works great with "setleds".
I use it in combination with Soarer and "BetterTouchTool" to send the terminal command when I press the Numlock/Scrolllock key.
Now I can switch between Num Pad Mode and Navigation Cluster Mode and the Numlock LED shows me which I am in. Quite normal with Windows but a bit of work with MacOs...
- kbdfr
- The Tiproman
- Location: Berlin, Germany
- Main keyboard: Tipro MID-QM-128A + two Tipro matrix modules
- Main mouse: Contour Rollermouse Pro
- Favorite switch: Cherry black
- DT Pro Member: 0010
@ThiagorosThiagoros wrote: ↑21 Jan 2024, 12:31Fantastic to hear that "setleds" is working seamlessly for you! Integrating it with Soarer and "BetterTouchTool" to toggle between Num Pad and Navigation Cluster modes on MacOS is a clever solution. It brings a familiar Windows feature to your Mac setup, adding a useful and personalized touch to your workflow.AngryCockroach wrote: ↑08 Jan 2024, 17:39Thank you, works great with "setleds".
I use it in combination with Soarer and "BetterTouchTool" to send the terminal command when I press the Numlock/Scrolllock key.
Now I can switch between Num Pad Mode and Navigation Cluster Mode and the Numlock LED shows me which I am in. Quite normal with Windows but a bit of work with MacOs...
Like your other post, this answer has a definite ChatGPT smell
-
- Location: Seattle
- DT Pro Member: -
Do you possibly have a link for the solenoid driver manual? I’ve been toying with the idea of trying to put one in a different board but have been having trouble finding enough information to feel confident doing it myself.Muirium wrote: ↑03 Jan 2024, 12:33As Xwhatsit says in his manual, the *only* Model F with lock lights is the AT, so I've no idea why he didn't follow this himself! But I do remember rejiggering the pins in my connector and it works.
- Muirium
- µ
- Location: Edinburgh, Scotland
- Main keyboard: HHKB Type-S with Bluetooth by Hasu
- Main mouse: Apple Magic Mouse
- Favorite switch: Gotta Try 'Em All
- DT Pro Member: µ
Xwhatsit’s docs are all neatly laid out here:
https://static.wongcornall.com/ibm-capsense-usb/
Bear in mind he wrote these years before Ellipse’s remakes / the various Xwhatsit-inspired hardware that’s been made without him. Things may have changed a bit in the many years since.
https://static.wongcornall.com/ibm-capsense-usb/
Bear in mind he wrote these years before Ellipse’s remakes / the various Xwhatsit-inspired hardware that’s been made without him. Things may have changed a bit in the many years since.