Make bidirectional communication work between the keyboard halves. Make the set test LED USB command set the test LED of the left half, too.

This commit is contained in:
László Monda
2016-10-19 19:39:00 +02:00
parent 1286d9cfc3
commit 7a6e5523fb
9 changed files with 167 additions and 37 deletions

View File

@@ -103,8 +103,11 @@ void JumpToBootloader() {
void GetSetTestLed()
{
uint8_t arg = GenericHidInBuffer[1];
switch (arg) {
uint8_t ledState = GenericHidInBuffer[1];
uint8_t data[] = {1, ledState};
I2cWrite(I2C_MAIN_BUS_BASEADDR, I2C_ADDRESS_LEFT_KEYBOARD_HALF, data, sizeof(data));
switch (ledState) {
case 0:
TEST_LED_ON();
break;