ESP_ERROR_CHECK failed, expression: esp_intr_alloc

Example TERMINAL output:

ESP_ERROR_CHECK failed: esp_err_t 0x105 (ESP_ERR_NOT_FOUND) at 0x4201f8d1
0x4201f8d1: twai_driver_install at C:/Espressif/esp/esp-idf/components/driver/twai.c:449 (discriminator 1)

file: "/IDF/components/driver/twai.c" line 449
func: twai_driver_install
expression: esp_intr_alloc(ETS_TWAI_INTR_SOURCE, g_config->intr_flags, twai_intr_handler_main, NULL, &p_twai_obj->isr_handle)

abort() was called at PC 0x4037af97 on core 0

In this example, the installation of the TWAI driver failed because the system ran out of CPU interrupt inputs. This can happen when several drivers or subsystems are initialized. Something along the lines of this suggestion might help.

See our page on this issue here.

See the Espressif interrupt allocation doc here.