Using opus decoder with ESP-IDF 4.x
Posted: Fri Feb 21, 2020 4:42 pm
I have a project that's currently using ESP-IDF 4.x
I'm interested in using opus-decoder in my ESP-IDF 4.x project. Currently, ESP-ADF is only supported on a specific version of ESP-IDF 3.x where the build system is different.
I noticed that a static library of the the opus library exists here:
https://github.com/espressif/esp-adf-li ... esp-opus.a
I also noticed that the ESP-IDF 4.x documents describe how to use a static library here:
https://docs.espressif.com/projects/esp ... components
I tried following the prebuilt example from here:
https://github.com/espressif/esp-idf/tr ... t_prebuilt
It builds! But I get a runtime error:
That error references opus_decoder.c from some developer's machine. I'm unsure if I can work around this.
I'm in the process of making a suitable source-code component from https://github.com/xiph/opus
I have two questions:
1. Is there any advice for using the opus encoder/decoder with ESP-IDF 4.x ?
2. Maybe this question should be posted in ADF - are there optimizations built in to the libesp-opus.a static library in esp-adf-libs ?
Many thanks,
Dave
I'm interested in using opus-decoder in my ESP-IDF 4.x project. Currently, ESP-ADF is only supported on a specific version of ESP-IDF 3.x where the build system is different.
I noticed that a static library of the the opus library exists here:
https://github.com/espressif/esp-adf-li ... esp-opus.a
I also noticed that the ESP-IDF 4.x documents describe how to use a static library here:
https://docs.espressif.com/projects/esp ... components
I tried following the prebuilt example from here:
https://github.com/espressif/esp-idf/tr ... t_prebuilt
It builds! But I get a runtime error:
Code: Select all
Guru Meditation Error: Core 0 panic'ed (StoreProhibited). Exception was unhandled.
Core 0 register dump:
PC : 0x4000c46c PS : 0x00060530 A0 : 0x8013c4c7 A1 : 0x3ffd8420
A2 : 0x00000000 A3 : 0x00000000 A4 : 0x00006780 A5 : 0x00000000
A6 : 0x00000003 A7 : 0x00000678 A8 : 0x00006780 A9 : 0x3ffd83e0
A10 : 0x000045c8 A11 : 0x00000000 A12 : 0x00000000 A13 : 0x3ffd9ef4
A14 : 0x0000002e A15 : 0x00000006 SAR : 0x00000020 EXCCAUSE: 0x0000001d
EXCVADDR: 0x00000000 LBEG : 0x4000c46c LEND : 0x4000c477 LCOUNT : 0x00000677
ELF file SHA256: 93e3c61071c572a1b5de0e95a1c939fe2f3d1f551c1a59ec0e1518509581cc21
Backtrace: 0x4000c469:0x3ffd8420 0x4013c4c4:0x3ffd8430 0x400d610b:0x3ffd8460 0x400936d9:0x3ffd9810
0x4013c4c4: opus_decoder_init at /Users/maojianxin/duros/esp-adf-libs-source/esp_codec/esp-opus/src/opus_decoder.c:106
0x400d610b: moondog_rtp_mcast_task_function at /Users/dsee/Documents/esp_opus_test/build/../main/esp_opus_test_main.c:50
0x400936d9: vPortTaskWrapper at /Users/dsee/esp/esp-idf/components/freertos/xtensa/port.c:143[Codebox=bash file=Untitled.bsh]
I'm in the process of making a suitable source-code component from https://github.com/xiph/opus
I have two questions:
1. Is there any advice for using the opus encoder/decoder with ESP-IDF 4.x ?
2. Maybe this question should be posted in ADF - are there optimizations built in to the libesp-opus.a static library in esp-adf-libs ?
Many thanks,
Dave