diff --git a/components/mch2022-bsp/rp2040.c b/components/mch2022-bsp/rp2040.c index f7d7d08..d250d53 100644 --- a/components/mch2022-bsp/rp2040.c +++ b/components/mch2022-bsp/rp2040.c @@ -29,7 +29,7 @@ void rp2040_intr_task(void *arg) { ESP_LOGE(TAG, "RP2040 interrupt task failed to read from RP2040"); continue; } - ESP_LOGW(TAG, "RP2040 input state %08x", state); + //ESP_LOGW(TAG, "RP2040 input state %08x", state); uint16_t interrupt = state >> 16; uint16_t values = state & 0xFFFF; for (uint8_t index = 0; index < 16; index++) { diff --git a/main/fpga_test.c b/main/fpga_test.c index e9fd1e0..427532f 100644 --- a/main/fpga_test.c +++ b/main/fpga_test.c @@ -144,19 +144,19 @@ void fpga_test(ILI9341* ili9341, ICE40* ice40, xQueueHandle buttonQueue) { if (xQueueReceive(buttonQueue, &buttonMessage, portMAX_DELAY) == pdTRUE) { printf("Button: %u, %u\n", buttonMessage.input, buttonMessage.state); if (buttonMessage.state) { - /*switch(buttonMessage.button) { - case PCA9555_PIN_BTN_HOME: - case PCA9555_PIN_BTN_MENU: - case PCA9555_PIN_BTN_BACK: + switch(buttonMessage.input) { + case RP2040_INPUT_BUTTON_HOME: + case RP2040_INPUT_BUTTON_MENU: + case RP2040_INPUT_BUTTON_BACK: waitForChoice = false; break; - case PCA9555_PIN_BTN_ACCEPT: + case RP2040_INPUT_BUTTON_ACCEPT: reload_fpga = true; waitForChoice = false; break; default: break; - }*/ + } } } }