The Trellis 4x4 HT16K33 LED/Keypad I2C driver board uses the same ROW lines for multiple keys, but avoids ghosting by including a diode in series with these lines.
For example, the buttons labelled 3 and 4 on the PCB (SW1G$1 and SW1G$2 on the schematic) both connect via R5 to COM2 and COM1 respectively, but have series diodes, avoiding button ghosting.
However, some buttons connect to COM1 or COM2 without diodes, and this causes LED ghosting.
For example, the buttons labelled 1 and 2 on the PCB (SW1G$4 and SW1G$3 on the schematic) connect via R10 and R7 respectively to COM1. Pressing both these buttons simultaneously shorts R7 and R10 together, so if an LED is lit on R7, the one on the same COM line and R10 will also light, and vice-versa.
The same is true of the buttons labelled 5, 6, 7, 9, 13, and 14.
Run the program. Buttons 1, 5, and 13 light up.
Press buttons 1 and 2; button 2 lights up.
Press buttons 8 and 9 or 8 and 10; button 9 or 10 lights up.
Press buttons 13 and 14; button 14 lights up.
Remedy
The solution is to include a diode in series with every button. This would require an additional 8 diodes. I believe you could then dispense with the diodes in series with the COM1 and COM2 lines, so you actually only need an extra 6 diodes.
I've already assembled the Trellis board I bought, so it would be difficult to test this by cutting tracks and adding diodes, but if you'd like me to test it on a new board I'll be happy to do that.
Description
The Trellis 4x4 HT16K33 LED/Keypad I2C driver board uses the same ROW lines for multiple keys, but avoids ghosting by including a diode in series with these lines.
For example, the buttons labelled 3 and 4 on the PCB (SW1G$1 and SW1G$2 on the schematic) both connect via R5 to COM2 and COM1 respectively, but have series diodes, avoiding button ghosting.
However, some buttons connect to COM1 or COM2 without diodes, and this causes LED ghosting.
For example, the buttons labelled 1 and 2 on the PCB (SW1G$4 and SW1G$3 on the schematic) connect via R10 and R7 respectively to COM1. Pressing both these buttons simultaneously shorts R7 and R10 together, so if an LED is lit on R7, the one on the same COM line and R10 will also light, and vice-versa.
The same is true of the buttons labelled 5, 6, 7, 9, 13, and 14.
The following program demonstrates this:
Demonstration
Run the program. Buttons 1, 5, and 13 light up. Press buttons 1 and 2; button 2 lights up. Press buttons 8 and 9 or 8 and 10; button 9 or 10 lights up. Press buttons 13 and 14; button 14 lights up.
Remedy
The solution is to include a diode in series with every button. This would require an additional 8 diodes. I believe you could then dispense with the diodes in series with the COM1 and COM2 lines, so you actually only need an extra 6 diodes.
I've already assembled the Trellis board I bought, so it would be difficult to test this by cutting tracks and adding diodes, but if you'd like me to test it on a new board I'll be happy to do that.