This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux/AM5728: GPIO keys

Part Number: AM5728

Tool/software: Linux

Hello All,

I'm working on our custom board, able to configure few gpio's as gpio_keys.

I have configured as below:

USER1 {
label = "UP";
linux,code = <KEY_UP>;
gpios = <&gpio3 7 GPIO_ACTIVE_LOW>;
};

Able to test with evtest command the interrupt,

Event: time 1520873640.120477, type 1 (EV_KEY), code 103 (KEY_UP), value 1
Event: time 1520873640.120477, -------------- SYN_REPORT ------------
Event: time 1520873640.286905, type 1 (EV_KEY), code 103 (KEY_UP), value 0
Event: time 1520873640.286905, -------------- SYN_REPORT ------------

I'm getting event for both rising and falling egde.

but i have below doubts on this:

1. How do i configure only for falling edge ?

2. I need to set an particular functionality for the key pressed, how can i do that? Do i need to wrrite an ISR for this interrupt event?

Thanks