Author Topic: WASD keyboards custom controller: USB+BT  (Read 2933 times)

0 Members and 1 Guest are viewing this topic.

Offline karakum

  • Thread Starter
  • Posts: 3
WASD keyboards custom controller: USB+BT
« on: Thu, 07 November 2019, 06:41:29 »
Hi guys! I have 104-key WASD keyboard about more 3 years. And last years I can’t leave thoughts about making it Bluetooth wireless.

At beginning, I had try to make usb-2-bt converter like https://github.com/juancgarcia/HID-Relay. It worked success except that my WASD-keyboard don’t turn on leds when it was connected to usb-host. I checked my hid-relay with other USB-keyboards, they worked properly, and their leds worked. However, not with my WASD.

Then I had decide to make own custom controller. I have made reverse engineering of board wiring. Keys board has two header-connector for controller board.
229654-0229656-1229658-2229660-3
229662-4

Totally, this keyboard has 8 rows and 18 columns. I decide to union Win_R & Win_L single columns with other. It reduce columns to 16. In addition, board has 6-key DIP-switch to configure (layouts, mode…) and 3 led.

Total 8+16+6+3=33 I/O ports. It is too much for typical Arduino/teensy boards. It can be reduce by using bi-directional multiplexor. 8 rows can be reduced by 74HC4051 to 3-bit line. 16 columns – to 4-bit line by 74HC4067.

So 3+4+6+3=16 I/O ports – it is enough to choose any arduino/teensy compatible board.

It need to say that also RX/TX lines required for communicate with rn-42(hc-05). Wireless mode can be turned on/off by one of DIP-switch or just additional switcher on keyboard’s cover.

Now I can’t choose and ask for help of community - which one of teensy-compatible board to select?
« Last Edit: Fri, 10 July 2020, 14:49:44 by karakum »

Offline yui

  • Posts: 305
  • Location: 127.0.0.1 (in azerty)
Re: WASD keyboards custom controller: USB+BT
« Reply #1 on: Thu, 07 November 2019, 07:45:02 »
Teensy would be best, otherwise the pro micro has is quite popular around here and is cheaper but the bootloader is not as good and it has 1 less usable pin, there is also the goldfish project but you would need to order the boards and parts yourself and solder them and it is closer to the pro micro, just with a usb C and lower profile.
vi vi vi - the roman number of the beast (Plan9 fortune)

Offline Findecanor

  • Posts: 4587
  • Location: Koriko
Re: WASD keyboards custom controller: USB+BT
« Reply #2 on: Thu, 07 November 2019, 09:12:19 »
If you want Bluetooth and USB, you could consider the Nordic nRF52840 microcontroller. It has 48 configurable GPIO pins, both USB and Bluetooth. There is a fork of QMK firmware for it.

However, boards suitable for hand-soldering that expose many GPIO pins are a bit more unusual.
There are those with Pro Micro pinout and then there is the Adafruit Feather nRF52840 Express and Sparkfun's Particle Xenon in feather pinout, but neither has that many pins.

However, there are tiny modules out there, that fit onto a larger circuit board, and which should expose enough GPIO pins and the USB. Those tend to not have battery charging built-in though, and you would have to design the main PCB for it yourself.

I suspect also that the WASD as-is runs on 5V from VBUS directly, and that the module would need a voltage regulator for 3.3V (or lower).
« Last Edit: Thu, 07 November 2019, 09:49:43 by Findecanor »
Man must shape his tools lest they shape him
-- Arthur Miller

Offline karakum

  • Thread Starter
  • Posts: 3
Re: WASD keyboards custom controller: USB+BT
« Reply #3 on: Fri, 10 July 2020, 14:41:45 »
I did it! :cool:

Thanks to fork of QMK firmware author!
Thanks to joric for great work of project! It was my guidebook.

New features:
- Bluetooth LE & USB HID with QMK powered keyboard
- Nordic nRF52840 microcontroller
- USB Type-A & Type-C connectors
- Li-Po 250mAh Battery with power switch

Firmware source: https://github.com/karakum/qmk_firmware/tree/wasd_custom
Schematic & pcb: https://easyeda.com/karakum/wasd-custom-controller

246916-0246918-1246920-2246922-3246924-4246926-5

(two wires on pcb - temporary serial tx-gnd for debug)
« Last Edit: Fri, 10 July 2020, 14:55:49 by karakum »

Offline Pylon

  • Posts: 669
Re: WASD keyboards custom controller: USB+BT
« Reply #4 on: Fri, 10 July 2020, 17:47:25 »
Nice work!

Did you mean 2500mah for the battery? Those little blue TP4056 charging board are usually 1A charging by default. Unless you mod the current set resistor that's way too much current for charging a 250mah battery.

Offline karakum

  • Thread Starter
  • Posts: 3
Re: WASD keyboards custom controller: USB+BT
« Reply #5 on: Sat, 11 July 2020, 01:12:32 »
Nice work!

Did you mean 2500mah for the battery? Those little blue TP4056 charging board are usually 1A charging by default. Unless you mod the current set resistor that's way too much current for charging a 250mah battery.
No, 250. Prog resistor in TP4056 was replaced accordingly.
Now I'm watching energy consumption. But it is very impressive. Approximately 1-2% per day. If the battery lasts for a month, then it will be more than excellent. :thumb: