Limit on GPIO Interrupt Handlers?

banjoluck
Posts: 25
Joined: Fri Jul 29, 2022 5:11 pm

Limit on GPIO Interrupt Handlers?

Postby banjoluck » Mon Jul 24, 2023 11:30 pm

Greetings,

Using an ESP32, I have GPIO inputs on pins 26, 27, 14, 34, 32, and 35. I am using this code snippet to enable interrupt handlers:

Code: Select all

    void enable_button_input_isr (gpio_num_t gpio_pin, void* pvUser) {
      {
        gpio_config_t config = {};
        config.intr_type = GPIO_INTR_ANYEDGE;
        config.pin_bit_mask = 1ull << gpio_pin;
        config.mode = GPIO_MODE_INPUT;
        ::gpio_config (&config);
      }

      ::printf ("# enable button interrupt on %d\n", int (gpio_pin));
      ::gpio_isr_handler_add (gpio_pin, button_isr, pvUser);
      ::gpio_intr_enable (gpio_pin); }
Except for input 34, all of them use the same ISR. The handler just reads all of the input current values and passes them along to the UI dispatch task. The trouble is that 32 and 35 do not trigger an interrupt. Is there a limit on the number of interrupt handlers we can enable? Or, is there some other limitation that isn't made clear in the documentation?

Cheers

meoychieu2004
Posts: 1
Joined: Tue Jul 25, 2023 7:18 am

Re: Limit on GPIO Interrupt Handlers?

Postby meoychieu2004 » Tue Jul 25, 2023 7:25 am

It should trigger interrupt, check the signal in the PCB.

Who is online

Users browsing this forum: Baidu [Spider], VinayDand and 449 guests