For some DIY mechanical keyboards, instead of an integrated microcontroller, a daughterboard like the Pro Micro is used. Pro Micro-based builds/PCBs are commonly found in designs for split keyboards like the Let’s Split, Quefrency, and Iris (the older Rev. 2), due to split keyboards being relatively new compared to single-piece keyboards.

Split keyboard using Pro Micro controllers

Bad Pro Micro!

The Pro Micro uses a Micro-USB port, which is a decent port, but for most of the clones out there, the Micro-USB port that was used doesn’t stay on the board very well and can be torn off.

Pro Micro on the right with a sheared off Micro-USB port

Enter the Elite-C. USB-C is being used more these days, and keyboard builders have been wanting a USB-C version of the Pro Micro to resolve the port issues with the Pro Micro. So SpaceCat Design, Maple Computing, and Keebio got together to develop the Elite-C. The goal was to produce a drop-in replacement for the Pro Micro, but with the following improvements:

USB-C port

DFU bootloader instead of Caterina bootloader

More pins of the ATmega32u4 controller made available

Reset button

Here’s a fun little video how the USB-C port of the Elite-C holds up:

USB port strength test of the Elite-C and Pro Micro

Different versions

To date, there have been 3 different versions of the Elite-C. Here’s a quick summary of the different versions:

V1: Initial release, no major issues, except for Schottky diode not being soldered on properly sometimes. The diode’s SOD-123 legs were fairly small, so we switched to a SOD-123F package for V2.

Elite-C V1, so pretty

V2: Since the V1 did not have an LED on there, some people mistakenly thought that their Elite-C was not working, so we added an LED in between VCC and GND to indicate that the board is getting power. A 500mA fuse was also added for protection (sorry drashna for ruining your RGB dreams). A couple of runs were done with V2.

Elite-C V2 (pic grabbed from NovelKeys and then annotated)

V3: For V3, we decided to play around with adding castellated holes to allow for soldering to a board with special solder pads for a lower profile build.

Elite-C V3 with fancy castellated holes

Signs of trouble

Problems with V1 and V2 were fairly minimal. However, with the release of V3, issues were being reported of slave halves using the V3 not working with boards like the Corne, Quefrency, etc. People tried a mix of boards using Pro Micro and Elite-C V1/V2 controllers to experiment with what would work.

Most of this discussion took place on the QMK and Keebio Discord servers, and shoutout to Yan-Fa Li for working with people to determine that there was an issue with V3. After a few reported cases, Chris (of Maple Computing) and I took a look at the schematic and that everything checked out with the Schottky, which we suspected was a possible source of the issue.

How split keyboard detection works

For a split keyboard, each half needs to know if it is the master half or the slave half. The master half will be the one that talks to the computer and sends up keystrokes, while the slave just sends its keystroke info via a TRRS cable to the master and does not talk to the computer.

To determine which half is the master, we need to figure out which half is connected via USB to the computer. Currently in QMK, the firmware used for these keyboards, this is done by reading in the VBUS pin when the board starts up. If the VBUS pin is high (close to 5V), we determine that it’s connected to the USB port and call it the master. If the VBUS pin is low (close to 0V), then we set it to be the slave.

Diagram of how power is shared between the two halves of a split keyboard

Now how we set up the circuitry on the board to allow for this method of detection to work? Let’s look at how current flows within the split keyboard.

Power comes in from the USB port at 5V (marked in purple). It then goes through a fuse and at the other side, it will still be 5V (green on the master half). This is connected to the VBUS pin of the master’s ATmega32u4, which will be read in. Next, it goes through a Schottky diode. The purpose of a diode is to allow current to flow in one direction (from anode to cathode), but not in the reverse direction. However, the cost of this is a forward voltage drop, which varies based on diode. For the common 1N4148 diode, it’s about 0.6–0.7V, which would make VCC about 4.3–4.4V, which is a bit lower than the 32u4 ideally wants. So we used a Schottky diode, which has a lower voltage drop of 0.3–0.4V, resulting in a VCC of 4.6–4.7V. VCC makes its way across the TRRS cable (with negligible voltage drop if any), and then there’s a small bit of current that goes backwards through the slave’s Schottky diode from the cathode to the anode. This current is called reverse current. Hopefully, this reverse current is minimal and that the slave’s VBUS pin voltage is close to 0V.

So based off of this, our hypothesis was that the Schottky diode is the source of the issue.

Rolling up my sleeves and digging into the issue

After hearing about 4–5 reports of the issue, I decided to set aside some time to investigate it. I took a pair of brand-new, unflashed Elite-C V3s and soldered on jumper wires to join the VCC and GND pins of the two together.

Testing procedure:

Plug USB into one of the Elite-Cs, which will simulate being the master Check voltage before and after the Schottky diode on both master and slave controllers

Testing rig (from left to right: Elite-C V3, Elite-C V2, 2 Pro Micros, Elite-C V3)

The main measurement of interest is the anode side of the slave half’s Schottky. Ideally, this should be somewhere close to 0V. Well, when I did the measurement of the ‘slave’ Elite-C V3, it was 1.1V. Hmmm…

Logic Levels

So what does 1.1V translate to when the 32u4 microcontroller reads the pin? Is it a 0 (low) or 1 (high)? This is when I had to dig through the datasheet for the ATmega32u4.

Excerpt of ATmega32u4 Datasheet

Highlighted above are the relevant values we need to take a look at. VCC is 5V in this case, so it means that 0–0.9V translates to a 0 (low), and 1.9V-5V translates to a 1 (high). Well, the reading of 1.1V I measured is in between, which is in a grey area, and it ended up getting marked as high when the read was done. As a result, the firmware thought the slave Elite-C was the master.

Not good.

But why was the voltage 1.1V in the first place? Time to dig some more.

Reading more datasheets

Before I had even setup my testing rig, I noticed that the Schottky diodes on the V2 and V3 were different. So I asked Chris for the part number of the Schottky on the V3 to see what the difference was.