Cannot send BLE server notificatoin to multiple clients, need help decoding backtrace

listout
Posts: 31
Joined: Wed Mar 16, 2022 10:54 am

Cannot send BLE server notificatoin to multiple clients, need help decoding backtrace

Postby listout » Sat May 14, 2022 6:57 am

I'm trying to send BLE notification to multiple (for now 2) connection handles. I can send notification to either one of the connection handles. But when I try to send the notification to two of the handles, one after the another, I get a core panic. I don't know what I'm doing wrong can someone help understand the core panic backtrace ?

Code: Select all

vhci.c 134
Guru Meditation Error: Core  0 panic'ed (Interrupt wdt timeout on CPU0).

Core  0 register dump:
PC      : 0x4008a241  PS      : 0x00060235  A0      : 0x8008a428  A1      : 0x3ffbe6e0
0x4008a241: vhci_recv_end at vhci.c:?

A2      : 0x00000002  A3      : 0x3ffb557c  A4      : 0x40017620  A5      : 0x3ffb8140
A6      : 0x00000003  A7      : 0x00060923  A8      : 0x8008a241  A9      : 0x3ffbe650
A10     : 0x0000000b  A11     : 0x0000000b  A12     : 0x0000000c  A13     : 0xffffffff
A14     : 0x00000000  A15     : 0xfffffffc  SAR     : 0x00000004  EXCCAUSE: 0x00000005
EXCVADDR: 0x00000000  LBEG    : 0x4000c349  LEND    : 0x4000c36b  LCOUNT  : 0xffffffff
Core  0 was running in ISR context:
EPC1    : 0x400d2c47  EPC2    : 0x00000000  EPC3    : 0x4008a241  EPC4    : 0x4008a241
0x400d2c47: uart_hal_write_txfifo at /home/listout/esp/esp-idf/components/hal/uart_hal_iram.c:35

0x4008a241: vhci_recv_end at vhci.c:?

0x4008a241: vhci_recv_end at vhci.c:?



Backtrace:0x4008a23e:0x3ffbe6e00x4008a425:0x3ffbe700 0x400e7bcc:0x3ffbe720 0x4008a43c:0x3ffbe740 0x40082d79:0x3ffbe760 0x4008363e:0x3ffccd70 0x4008a1c9:0x3ffccd90 0x400f84ec:0x3ffccdb0 0x400e0d8c:0x3ffccde0 0x400e06e2:0x3ffcce00 0x400d765d:0x3ffccf20 0x400dde09:0x3ffccf40 0x400dde7e:0x3ffccf70 0x400dc793:0x3ffccf90 0x400da062:0x3ffccfc0 0x400d9ea9:0x3ffccff0 0x400d9239:0x3ffcd020 0x400d642c:0x3ffcd040 0x400939ed:0x3ffcd070
0x4008a23e: vhci_recv_end at vhci.c:?

0x4008a425: r_vhci_isr at ??:?

0x400e7bcc: r_eif_isr at ??:?

0x4008a43c: r_eif_isr_wrapper at intc.c:?

0x40082d79: _xt_lowint1 at /home/listout/esp/esp-idf/components/freertos/port/xtensa/xtensa_vectors.S:1111

0x4008363e: cause_sw_intr_to_core_wrapper at /home/listout/esp/esp-idf/components/bt/controller/esp32/bt.c:1033

0x4008a1c9: vhci_set_interrupt at vhci.c:?

0x400f84ec: API_vhci_host_send_packet at ??:?

0x400e0d8c: esp_vhci_host_send_packet at /home/listout/esp/esp-idf/components/bt/controller/esp32/bt.c:1381

0x400e06e2: ble_hci_trans_hs_acl_tx at /home/listout/esp/esp-idf/components/bt/host/nimble/esp-hci/src/esp_nimble_hci.c:136

0x400d765d: ble_hs_tx_data at /home/listout/esp/esp-idf/components/bt/host/nimble/nimble/nimble/host/src/ble_hs.c:714

0x400dde09: ble_hs_hci_acl_tx_now at /home/listout/esp/esp-idf/components/bt/host/nimble/nimble/nimble/host/src/ble_hs_hci.c:519

0x400dde7e: ble_hs_hci_acl_tx at /home/listout/esp/esp-idf/components/bt/host/nimble/nimble/nimble/host/src/ble_hs_hci.c:577

0x400dc793: ble_l2cap_tx at /home/listout/esp/esp-idf/components/bt/host/nimble/nimble/nimble/host/src/ble_l2cap.c:452

0x400da062: ble_att_tx at /home/listout/esp/esp-idf/components/bt/host/nimble/nimble/nimble/host/src/ble_att_cmd.c:75

0x400d9ea9: ble_att_clt_tx_notify at /home/listout/esp/esp-idf/components/bt/host/nimble/nimble/nimble/host/src/ble_att_clt.c:902

0x400d9239: ble_gattc_notify_custom at /home/listout/esp/esp-idf/components/bt/host/nimble/nimble/nimble/host/src/ble_gattc.c:4178

0x400d642c: ble_server_uart_task at /home/listout/Documents/work/idf_projects/ble_server/build/../main/main.c:461

0x400939ed: vPortTaskWrapper at /home/listout/esp/esp-idf/components/freertos/port/xtensa/port.c:131



Core  1 register dump:
PC      : 0x40123672  PS      : 0x00060635  A0      : 0x800d27c6  A1      : 0x3ffbd460
0x40123672: esp_pm_impl_waiti at /home/listout/esp/esp-idf/components/esp_pm/pm_impl.c:839

A2      : 0x00000000  A3      : 0x00000028  A4      : 0x80093ca1  A5      : 0x3ffba520
A6      : 0x00000003  A7      : 0x00060423  A8      : 0x801017c6  A9      : 0x3ffbd430
A10     : 0x00000000  A11     : 0x010f9d60  A12     : 0x0000001a  A13     : 0x00000030
A14     : 0x00000000  A15     : 0x00000000  SAR     : 0x00000000  EXCCAUSE: 0x00000005
EXCVADDR: 0x00000000  LBEG    : 0x00000000  LEND    : 0x00000000  LCOUNT  : 0x00000000


Backtrace:0x4012366f:0x3ffbd4600x400d27c3:0x3ffbd480 0x40092469:0x3ffbd4a0 0x400939ed:0x3ffbd4c0
0x4012366f: cpu_ll_waiti at /home/listout/esp/esp-idf/components/hal/esp32/include/hal/cpu_ll.h:183
 (inlined by) esp_pm_impl_waiti at /home/listout/esp/esp-idf/components/esp_pm/pm_impl.c:837

0x400d27c3: esp_vApplicationIdleHook at /home/listout/esp/esp-idf/components/esp_system/freertos_hooks.c:63

0x40092469: prvIdleTask at /home/listout/esp/esp-idf/components/freertos/tasks.c:3973 (discriminator 1)

0x400939ed: vPortTaskWrapper at /home/listout/esp/esp-idf/components/freertos/port/xtensa/port.c:131
Code gist: https://gist.github.com/listout/45065af ... 6bffbf16de

Who is online

Users browsing this forum: No registered users and 124 guests