I'm try to write my own HID host driver. This work fine on ESP-IDF v4.4. I get my keyboard or mouse event. But on ESP-IDF v5.0, usb_host_interface_claim doesn't work.
This is the backtrace :
Code: Select all
abort() was called at PC 0x4037723f on core 0
0x4037723f: lock_acquire_generic at C:/espressif_5/esp-idf/components/newlib/locks.c:130
Backtrace: 0x40375cd2:0x3fcebc80 0x40379c01:0x3fcebca0 0x4037fb82:0x3fcebcc0 0x4037723f:0x3fcebd30 0x40377355:0x3fcebd60 0x40377424:0x3fcebd80 0x4201838d:0x3fcebdb0 0x4201b4d1:0x3fcec0c0 0x42022f2d:0x3fcec0f0 0x4037fa31:0x3fcec120 0x4200b5ca:0x3fcec170 0x4200aa5e:0x3fcec190 0x42008adb:0x3fcec1c0 0x42008c93:0x3fcec1e0 0x42008df9:0x3fcec200 0x42008ed9:0x3fcec230 0x4037c9f5:0x3fcec260
0x40375cd2: panic_abort at C:/espressif_5/esp-idf/components/esp_system/panic.c:412
0x40379c01: esp_system_abort at C:/espressif_5/esp-idf/components/esp_system/esp_system.c:135
0x4037fb82: abort at C:/espressif_5/esp-idf/components/newlib/abort.c:38
0x4037723f: lock_acquire_generic at C:/espressif_5/esp-idf/components/newlib/locks.c:130
0x40377355: _lock_acquire_recursive at C:/espressif_5/esp-idf/components/newlib/locks.c:158
0x40377424: __retarget_lock_acquire_recursive at C:/espressif_5/esp-idf/components/newlib/locks.c:314 (discriminator 3)
0x4201838d: _vfprintf_r at ??:?
0x4201b4d1: vprintf at /builds/idf/crosstool-NG/.build/HOST-x86_64-w64-mingw32/xtensa-esp32s3-elf/src/newlib/newlib/libc/stdio/vprintf.c:34 (discriminator 5)
0x42022f2d: esp_log_writev at C:/espressif_5/esp-idf/components/log/log.c:200
0x4037fa31: esp_log_write at C:/espressif_5/esp-idf/components/log/log.c:210
0x4200b5ca: usbh_dev_get_addr at C:/espressif_5/esp-idf/components/usb/usbh.c:648
0x4200aa5e: usb_host_interface_claim at C:/espressif_5/esp-idf/components/usb/usb_host.c:1109
0x42008adb: check_interface_desc_boot_keyboard at K:/Projet_GIT/Kineko/KinekoESP32/esp_app/usb_host_lib/main/class_driver.c:85
0x42008c93: show_config_desc_full_special_hid at K:/Projet_GIT/Kineko/KinekoESP32/esp_app/usb_host_lib/main/class_driver.c:146
0x42008df9: action_get_config_desc at K:/Projet_GIT/Kineko/KinekoESP32/esp_app/usb_host_lib/main/class_driver.c:272 (discriminator 2)
0x42008ed9: class_driver_task at K:/Projet_GIT/Kineko/KinekoESP32/esp_app/usb_host_lib/main/class_driver.c:420
0x4037c9f5: vPortTaskWrapper at C:/espressif_5/esp-idf/components/freertos/FreeRTOS-Kernel/portable/xtensa/port.c:151