Looking for the InputKeyService code that compares button voltages.

Philbot
Posts: 10
Joined: Fri Nov 08, 2019 2:14 pm

Looking for the InputKeyService code that compares button voltages.

Postby Philbot » Thu Dec 08, 2022 2:22 am

I have a Lyra MiniT and I'm trying to find where in the esp-adf code, the InputKey Service actually reads the analog input chanel and determines which key is being pressed.

I've found the button ID definitions, and the analog chanel definition and various callbacks, but I just can find any reference to the six button voltages that appear on the schematic.

Is there a definition of the voltages somewhere?

Thanks for any help....

Note: I'm looking to expand the number of buttons on a custom input device.

EDIT: Never mind, I found it as soon as I postd: /components/esp_peripherals/lib/adc_button/adc_button.c

tempo.tian
Posts: 40
Joined: Wed Jun 22, 2022 12:10 pm

Re: Looking for the InputKeyService code that compares button voltages.

Postby tempo.tian » Fri Dec 09, 2022 2:33 am

You can see the define on:
https://github.com/espressif/esp-adf/bl ... ard.c#L116

If you use customized board, you can create a folder like following and put your board defines into it
https://github.com/espressif/esp-adf/tr ... board_v1_0

Who is online

Users browsing this forum: No registered users and 11 guests