For better or worse, I've been somewhat captivated into looking further into this, mainly because the Pro Micro used in the original projects are 5V, the PS5 joysticks are allegedly 5V, yet the Espressif chips are 3.3V. Additionally, while those ESP32 chips have the 16 channels I need, they don't have full range coverage:
ESP32-S3: Seems it's nonlinear after about 2.5V and maxes out at 3.05V.
Thus, I went on an expedition to find out more info on the joysticks.
From this video, I found a list which I believe is the voltage of the controller:
PS4 - 5V
XBox One - 2.4V (rechargeable) or 3.0V (non-rechargeable)
PS5 - 5V
Switch - 5V
The notable one is the XBox One. While the various hall effect sticks have different colours depending on the polarity of the left/right pins, I couldn't find any reason that the chips used in them were any different, implying that these sticks might work at 2.5V. I also saw a reference to CC6501, and its family of chips seems to output between 10% and 90% of VCC.
Then, looking around, it seems that it's cheaper and more configurable to use an ESP32-S2 for its DAC than it is to buy a separate voltage regulator. A slight drawback is that some purple pcb with only 27 GPIO pins took over the entire local ESP32-S2 market, meaning I'll have to AliExpress in the red board below:
The ADC in the S2 still seems kind of questionable:
The ADC reference voltage can range from 1.0V to 1.2V amongst different ESP32-S2's.
This is one of the reasons why having the DAC is advantageous, since the voltage sent to the joysticks can be tuned to get the best range for the ADCs.
To get over the £8-spend-for-free-delivery, I found a few other components (see below). The BOM is now down from £55 to £43.
I've been considering the potential options for the hand pose to use (e.g. like a glove, like holding a vertical mouse) and I've come to the conclusion of 2 sides of an extrusion that can rotate up to 45 degrees:
The entire "keyboard" is sheathed in the tube seen above, allowing for easy transportation.
The tube also acts as a wind guard.
It allows good ergonomics from the range "crouched on the floor" at 0 degrees to "sitting at a desk" at 45 degrees rotation.
The edge of the desk acts as an armrest.
The hand pose is somewhat natural, like holding a cylinder from the top.
A basic-looking arrangement of the right-hand fingers is shown below, shown with their angle of direction (aka towards touching all fingertips):
The tube at the moment is 250mm long and 100x100mm squircle, which is approximately the diameter of a standard UK 2 litre bottle. Do you know what's also approx 100x100mm? Teaching Tech's Spacemouse (2nd Generation):
I've been trying to rigidly fix the project goalposts, but it's hard to ignore creating a PC input device with no mouse-pointer or scrolling provisions. There are provisions on Svalboard, the WK-50 keyboard and cheap wireless keyboard+trackpad combos, and the below video reminded me that I really should consider something:
I probably spend just as much time scrolling through the web as actually typing anything, and if working outside, current standalone options (mice, trackpads, optical finger navigation) expose my fingers to the cold. That's why I'm wondering if it's possible to have an area slightly before/after the fingertip keys that the fingers could grip on and have the 5 keywells become the spacemouse knob:
This would allow me to use a strategy like 3DxPoint to get mouse and scroll movement, and allow for full 6-axis control to be implemented at some future time.
Ergonomic limitations notwithstanding, the issues are the additional time it may take to implement and that, for the 8 joysticks, I'd need 16 analog pins. Technically, I should only need 6, but then I'd have to look into the computational issues TeachingTech faced and I'd rather not. Looking at the ESP32-S3 development board, it looks like there'd be just enough pins for the 16 joystick and 14 matrix pins.
I've looked into the remixes and a user called Kempy has decided to use PS5 hall-effect joysticks instead of the questionable PS2 resistor-based ones, minimising the deadzone and allowing for smoother control:
stainless
bead
ball spacer
2mm hole
[Jan 05] I just had the great idea to simply keep chord 22 reserved for enabling mouse mode! I'll try and explain quickly:
The "directions" that a right-handed finger inside a keywell can go are numbered to reflect the numpad. The physical buttons are:
1 - southwest
3 - southeast
9 - northeast
7 - northwest
The remaining ones are by pressing 2 buttons, with '5' being pressing all 4 buttons.
The main idea of Tetwice is that 2 fingers are used to chord 1 button, such as the 'a' key or 'esc' key.
Chord 22 essentially means pressing the two fingertip buttons on 2 fingers.
The idea is to detect if this is happening, since a user needs to do this to be able to grip the manipulator so that they can move it in 6 axes anyway.
Since the thumb is needed to grip anything, mouse mode will auto disable if both of the bottom thumb keys are depressed.
And profit! Without ever really needing to move much at all, a user can intuitively switch between keyboard and 3D-mouse modes.
As discovered in #WK-50 Trackball Keyboard, allegedly a keyboard designer could use PNP transistors as a "dual diode" package. If this works, it would be useful as I won't need to worry about diode polarity and will only have to "starter solder" half as many components (whereby starter solder means having a component that isn't held in place by a solder joint yet).
I went to my uni and they happened to have some ZTX502 PNP that mouser said was discontinued so I looked on ebay and it seems that the 2N3906 is the cheapest and most abundant:
For my First Attempt In Learning (FAIL) how to best solder the transistor on, I think it already looks rather good. Now I know:
not to try and solder with the iron on the opposite side, because the molten solder will be sucked in.
text facing up so that the pins are as far away from the switch enclosure as possible
orient like above so that the wiring can be 3 easy pins, as seen below.
I decided to put them on this corner of the RP2040 board so that, if I couldn't easily desolder them, it wouldn't affect my plan of using the entire other side of pins for the matrix. There's 16 GPIOs on that side and the matrix for Tetizmol should only need 14.
I checked continuities and then I installed KMK/Pog and changed the diode direction to ROW2COL, since the "diodes" should be pointing towards the column, but I wasn't getting anything when pressing buttons but was when I manually shorted them, so I know my pins are correct:
I also learned how to use the diode mode on my multimeter and I was getting .685 and .680 when the red lead was on pins 1 or 3 and black on pin 2, with 0L for anything else, so I know they're essentially acting like diodes. I did manage to get the neopixel working though by adding the neopixel.mpy into the lib folder and using GPIO23:
So I slept on this and the next day I continued researching and went back to my uni and they happened to have a BC559C, which seems to be part of a range:At least the datasheet sounds like it's more similar to the S8550.
So I tacked it on:
I only wired a 1x1 matrix
And the chordmap still didn't work. But now it also wasn't working for shorting pins so I closed Pog and decided to go into the serial port.
I had a card up my sleeve. I had also asked for 2 diodes which obviously should work. Their voltage drops were .546 / .562V when I soldered them on:
Can you see how much more work you'd have to do to use diodes instead of transistors?
And as expected... wait, no! It's still not working!
Opened Pog again to check settings, changed the diode orientation to COL2ROW and saved:
So now I have a configuration I know works, so I desoldered the diodes and soldered the 3rd pin for the 2N3906:
So now it works????
Not entirely sure what happened. The voltage drops are .687/.682 so it's not like the transistor has changed much. I can only assume that maybe Pog didn't save or maybe the chordmap finder isn't as reliable as I assumed for testing keys.
I tried printing the keycaps as-is and a modification that has more surface area to see if they'd stick better. I think it's best to go with the original profile but use a raft. Due to the print orientation, they're somewhat grippy, which I believe is a positive as it should make it easier to press multiple keys with confidence.
To avoid the nail for the top switches whilst also avoiding the fingertip hitting the wrong end of the bottom switches, I've come up with this solution.Quick doodle of the finger in the well
I've opted for a printed keycap that is stuck onto the lever with double-sided tape. The keycap hook will then catch on an overhang to prevent it springing back too far.
I need to design some way of adjusting the gap between the switches. Ideally, this would be a tool-less solution (aka doesn't need a screwdriver / allen key).
As I was writing this log after drawing the doodle, I noticed the sharp edges in the path of the finger, so I've tweaked the design a bit:
[The Following Day]
I just realised that the switches configured in this way allow both the bottom and top buttons to be pressed, allowing 3 more possible states. This increases the keymap space from 48 to 99.
The main necessity for this increase is for the modifiers (CTRL, ALT, WIN), but it also means that TeTwice would no longer need to place the following keys onto another layer:
FN 1 - 20
(Where FN20 will be the placeholder for FN0, which doesn't exist)
Arrow keys
Enter
Esc
Tab
Print Screen
Ins, Del, Home, End, PgUp, PgDown
Just to make the modifier combos easier to remember, I'm going to allocate 10 spaces for them. Thus, the TeTwice layout is now 91 entries, which leaves some wriggle room to align groups of characters.
It's starting to feel like I'm mining for copper and finding gold. Tetizmol is starting to approach my initial #Tetent [gd0090] concepts.
By pressing the switch multiple times to get a feel on how it best touches the finger, my current plan is a single 45-degree bend that starts 4mm to the end:
From the experiment (described below), it looks like the bend radius is 1.5mm.
I was able to use a G-clamp for a quick experiment:
I basically held this up infront of the CAD model on my monitor and aligned the bend.
The 45° bend sufficiently allows the finger to slide over the lever and not catch/scrape on the sharp edge, similar to the little tabs in a USB-A port.
At this new bend, the forces for actuation and reset are 17g and 10.5g respectively.
I started off this project by looking at what long-lever microswitches were available, and I only found 1 listing of the large variety that had NO and COM on the short edge.
I was about to checkout, but I decided to first draw up a simple sketch in Fusion and discovered that it was going to be too big to place in the Datahand / Svalboard configuration. I tried with the smaller KW11 microswitch, which surprisingly has a similar lever width (4.5 vs 3.9mm), but it's still too large.
The ovals are the cross section of fingers
I thought this project was over, but after half a week elapsed, I had the idea of diagonal movements. For the KW11-D, they are small enough for this to work:
This render is with a 10 degree bend applied to the lever."If you gaze for long into an abyss, the abyss gazes also into you".
Additionally, the movements necessary are easier as they rely more on the dominant "north / south" movement than the #lalboard - Ergonomic Keyboard / Svalboard / CharaChorder that also need "east / west" movements.
I then proceeded to look all over the internet for options. The KW11 switch is the most abundant and is 18p/ea on AliExpress. Next is the KW12, the silver-contact, green variant of the KW11 at around 40p. After that are Digikey options over 50p and mouse switches that don't come with a lever at all.
I read on the internet that silver contacts are used in applications when arcing (due to high voltage) is expected. The arc cleans off the insulating tarnish of the silver, which wouldn't happen for a USB peripheral. Thus, unless I wanted to pay double for the (admittedly nice) green, I stuck with the standard KW11.
We have a [long lever microswitch] at home
I have a bag of roller-lever switches that looks very similar, and I was able to stick 3 of them together to emulate the placement of the keys and how it'll feel.
I pressed one against a scale and it was nominally 95gf. To get values more representative of the 55mm-long lever microswitches, I broke some toothpicks to length and squeezed them into the gap between the red roller and the 0.4mm thick, stainless-steel lever. The result was nominally 28gf.
Something I noticed is that the angle (between the lever and enclosure) to close the switch is smaller than the angle to open it again:
Thus, the practical linear travel distance on the end of the toothpick is over 4mm just to reach the actuation point. While it's twice as far as a standard keyboard switch, I believe it will reduce misclicks (e.g. intending to press 1 switch but accidentally pressing 2).
Actuation point shown. It's aligned so that the reset point is at 0mm.