Author Topic: Analog switches  (Read 1570 times)

0 Members and 1 Guest are viewing this topic.

Offline Walshware

  • Thread Starter
  • Posts: 19
Analog switches
« on: Mon, 04 January 2021, 14:07:26 »
Hello! I have a 65% board and layout completed, but I would like to change the wasd keys portion of the pcb to be analog instead and hopefully be hotswap-able to normal mechanical switches.

I would also need help with finding a driver and also help with setting up the qmk. This is a lot of work I would imagine so Iíd like to be able to pay someone and hopefully have it done in the next couple weeks.
« Last Edit: Mon, 04 January 2021, 15:34:12 by Walshware »

Offline AKmalamute

  • HHKB Scrub
  • Posts: 837
  • Location: Western WA, USA
Re: Analog switches
« Reply #1 on: Tue, 05 January 2021, 11:36:15 »
analog as opposed to mechanical? I think I'm missing something.
Not that I'm in a position to rewrite a PCB file anyway, I just don't understand your request.

HHKB-lite2, Dvorak user

Offline Walshware

  • Thread Starter
  • Posts: 19
Re: Analog switches
« Reply #2 on: Tue, 05 January 2021, 14:29:01 »
Yeah analog switches instead of mechanical for Ďwasdí something like the flaretech. It helps with certain games that allow for dual inputs like fortnite or driving games so that you can choose how far to press the key to go that percent of speed in that direction like how any analog input works

Offline elmo

  • Posts: 367
  • Location: Hamburg, Germany
  • Hello I like keyboards
    • Elmo's keyboards
Re: Analog switches
« Reply #3 on: Tue, 05 January 2021, 17:12:50 »
Doesn't work.

What you are thinking about are electromagnetic Hall-effect switches. They are sometimes marketed as "analog switches".
They exist but they require a completely different and much much more complex underlying PCB technology.

There are no drop-in replacements that would work with a standard mechanical keyboard PCB.
The firmware that runs on these PCBs doesn't even support the concept of a multistep switch.

Offline Walshware

  • Thread Starter
  • Posts: 19
Re: Analog switches
« Reply #4 on: Wed, 06 January 2021, 20:57:44 »
Thatís why I have my own pcb and would have a driver for download to allow to dual inputs. If it works for one pcb then it can be modified to fit for mine right?

Offline Leslieann

  • * Elevated Elder
  • Posts: 3749
Re: Analog switches
« Reply #5 on: Thu, 07 January 2021, 03:05:42 »
No you can't just take someone else's software and driver and make it work for you, not unless they open sourced it. Not all keyboards and drivers are open source.

QMK can do what you want, but basically it will not register as a key press, at least out of the box, as far as I know, I never had a need to look but it does support a lot. You would also need a way to switch what mode it's in with either a function layer (if possible, capability and memory-wise this could be an issue) or a system service to identify when to switch to analog and when to switch to digital. You probably can get away with a basic keyboard driver in this way. Doing it this way a lot of this is already done for you, set up a compatible chip with qmk, tell QMK you have 4 sliders for analog. It's probably pretty simple keyboard side except that function layer. On the OS side you can just use Autohotkey to identify when a game is running and switch to analog and when to use digital. This would not only make it automatic but make the QMK code a lot simpler.

The most difficult part is the keyboard itself, usually I find the hardware side easy or at least easier, not in this case. How are you planning to find a digital switch and either an optical or hall effect switch that matches the rest of the board? Granted maybe you don't care about the feel, but even the switch height may need adjustment, meaning you may need 2 plates and/or PCBs to compensate. While that may be easy off to the side of the board, this would need to be in the middle, this means extra mounts, along with all that extra wiring.

I'm not saying this isn't doable, but it's not going to be that simple as just copying someone's code.
Novelkeys NK65AE w/62g Zilents/39g springs
62g Zilents/lubed/Novelkeys 39g springs, HK Gaming Thick PBT caps, Netdot Gen10 magnetic cable, pic
| Filco MJ2 L.E. Vortex Case, Jailhouse Blues, heavily customized
Vortex case squared up/blasted finish removed/custom feet/paint/winkey blockoff plate, HID Liberator, stainless steel universal plate, 3d printed adapters, Type C, Netdot Gen10 magnetic cable, foam sound dampened, HK Gaming Thick PBT caps (o-ringed), Cherry Jailhouse Blues w/lubed/clipped Cherry light springs, 40g actuation
w/ Kailh Purple Pros/lubed/Novelkeys 39g springs, HK Gaming Thick PBT caps, Netdot Gen10 Magnetic cable
| PF65 3d printed 65% w/LCD and hot swap
Box Jades, Interchangeable trim, mini lcd, QMK, underglow, HK Gaming Thick PBT caps, O-rings, Netdot Gen10 magnetic cable, in progress link
| Magicforce 68
MF68 pcb, Outemu Blues, in progress
| YMDK75 Jail Housed Gateron Blues
J-spacers, YMDK Thick PBT, O-rings, SIP sockets
| KBT Race S L.E.
Ergo Clears, custom WASD caps
| Das Pro
Costar model with browns
| GH60
Cherry Blacks, custom 3d printed case
| Logitech Illumininated | IBM Model M (x2)

Offline vvp

  • Posts: 842
Re: Analog switches
« Reply #6 on: Thu, 07 January 2021, 03:34:57 »
These things are typically done as a composite device where keyboard HW presents itself as both keyboard and joystick or mouse. Analog functionality will send joystick or mouse events. Key presses will be presented as keyboard or as button presses on joystick/mouse. That way you do not need any drivers on the OS side. Switching of a key from analog to digital mode is done by a simple key (combination) on the keyboard (like layer switching).

Offline Walshware

  • Thread Starter
  • Posts: 19
Re: Analog switches
« Reply #7 on: Tue, 12 January 2021, 21:50:43 »
So qmk has analog options? I felt like hardware would be the biggest problem since they require a optical sensor on the top of the pcb if Iím not mistaken. It would be worth the slight difference for the analog capabilities for the type of people using this as they wouldnít be as big into the custom keyboard scene. I donít know enough about drivers but it sounds like since Iím already going the qmk route then I just need to set that up correctly with enough memory on the board

Offline hanya

  • Posts: 129
  • Location: Japan
Re: Analog switches
« Reply #8 on: Tue, 12 January 2021, 22:30:12 »
Analog switch can be made with reflective photointerruptor, magnetic hall sensor or electrostatic capacitive sensing.
You can choose one from them to match to your swtich module.
Writing firmware for such sensor is not so difficult but you have to calibrate to match to real stroke.
PFU HHKB JP, Sanwa MA-TB38 trackball