Skip to content

library crash on xRingbufferReceive(_rb, &rx_size, RMT_RX_BUF_WAIT); #5

@marcmerlin

Description

@marcmerlin

The example code works fine on my ESP32, but when I integrate your lib in a much bigger code base that uses DMA and probably one code to push to the RGBPanels (in the SmartMatrix library), your library crashes here:

uint32_t IRRecv::read(char* &timingGroup, bool preferredOnly)
{
    if (!available()) return 0;
         
    size_t rx_size = 0;
    rmt_item32_t* item = (rmt_item32_t*) xRingbufferReceive(_rb, &rx_size, RMT_RX_BUF_WAIT); <<<
0x4008a1b0: invoke_abort at /Users/ficeto/Desktop/ESP32/ESP32/esp-idf-public/components/esp32/panic.c line 155
0x4008a3e1: abort at /Users/ficeto/Desktop/ESP32/ESP32/esp-idf-public/components/esp32/panic.c line 170
0x4008600b: xRingbufferReceive at /Users/ficeto/Desktop/ESP32/ESP32/esp-idf-public/components/esp_ringbuf/ringbuf.c line 845
0x400e221e: IRRecv::read(char*&, bool) at /home/merlin/Arduino/libraries/IR32/src/IRRecv.cpp line 128
0x400ded35: check_IR_serial() at /home/merlin/arduino/prg/Neopixel/NeoMatrix-FastLED-IR/NeoMatrix-FastLED-IR.ino line 2273
0x400dfb93: setup() at /home/merlin/arduino/prg/Neopixel/NeoMatrix-FastLED-IR/NeoMatrix-FastLED-IR.ino line 3158
0x400e46b3: loopTask(void*) at /home/merlin/Arduino/hardware/espressif/esp32/cores/esp32/main.cpp line 14
0x400861f1: vPortTaskWrapper at /Users/ficeto/Desktop/ESP32/ESP32/esp-idf-public/components/freertos/port.c line 143

19:24:56.431 -> Backtrace: 0x4008a1b0:0x3ffb1ea0 0x4008a3e1:0x3ffb1ec0 0x4008600b:0x3ffb1ee0 0x400e221e:0x3ffb1f20 0x400ded39:0x3ffb1f50 0x400dfb93:0x3ffb1f80 0x400e46b3:0x3ffb1fb0 0x400861f1:0x3ffb1fd0
19:24:56.431 -> 
19:24:56.431 -> Rebooting...
19:24:56.431 -> ets Jun  8 2016 00:22:57
19:24:56.431 -> 
19:24:56.431 -> rst:0xc (SW_CPU_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
19:24:56.504 -> configsip: 0, SPIWP:0xee
19:24:56.504 -> clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00

Is there a way to make this compatible with SmartMatrix?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions