I am using a TENSTAR T-display ESP32 to interface with a bluetooth pulse oximeter.
I have it working fine with an ESP32-devkit as well as with the TENSTAR T-display so long as I don’t use the display.
If I try to include even themmost basic code for using the display, it seems to run out of memory.
I have essentially the simplest possible setup. Two ble sensors set up to read bytes 6 and 7 respectively from the BLE notification strings from the pulse-ox
For the display I just used a Roboto font to display Hello World (I am still testing).
I tried even with a small 12 point size.
I stripped out all extraneous stuff such as OTA updates, web server, AP etc.
I set log level to WARN.
It compiles and uploads fine so I assume the problem is not flash memory.
However, when I run, the device fails to load BLE and/or says it runs out of memory while trying to attach to WiFi.
Often (but not alway) it just gets stuck in boot loops before falling back to safe mode.
- Is this normal that BLE + Display consumes so much flash/SRAM that it runs out of memory?
- Any suggestions on how to reduce memory consumption by BLE and display so I don’t run out of memory?
- Are there any other versions of an integrated esp32 with small display (~1.5") that include more SRAM (and maybe also flash)?
Here is some relevant log info:
[12:23:31]ets Jun 8 2016 00:22:57
[12:23:31]
[12:23:31]rst:0x1 (POWERON_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
[12:23:31]configsip: 0, SPIWP:0xee
[12:23:31]clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
[12:23:31]mode:DIO, clock div:2
[12:23:31]load:0x3fff0030,len:1344
[12:23:31]load:0x40078000,len:13836
[12:23:31]load:0x40080400,len:3608
[12:23:31]entry 0x400805f0
[12:23:32][W][component:157]: Component wifi set Warning flag: scanning for networks
[12:23:37]E (11550) task_wdt: Task watchdog got triggered. The following tasks did not reset the watchdog in time:
[12:23:37]E (11550) task_wdt: - loopTask (CPU 1)
[12:23:37]E (11550) task_wdt: Tasks currently running:
[12:23:37]E (11550) task_wdt: CPU 0: IDLE
[12:23:37]E (11550) task_wdt: CPU 1: IDLE
[12:23:37]E (11550) task_wdt: Aborting.
[12:23:37]
[12:23:37]abort() was called at PC 0x400f1ac1 on core 0
[12:23:37]
[12:23:37]
[12:23:37]Backtrace:0x40083885:0x3ffbea3c |<-CORRUPTED
[12:23:37]
[12:23:37]
[12:23:37]
[12:23:37]
[12:23:37]ELF file SHA256: 0000000000000000
[12:23:37]
[12:23:37]Rebooting...
[12:23:37]ets Jun 8 2016 00:22:57
[12:23:37]
[12:23:37]rst:0xc (SW_CPU_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
[12:23:37]configsip: 0, SPIWP:0xee
[12:23:37]clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
[12:23:37]mode:DIO, clock div:2
[12:23:37]load:0x3fff0030,len:1344
[12:23:37]load:0x40078000,len:13836
[12:23:37]load:0x40080400,len:3608
[12:23:37]entry 0x400805f0
[12:23:38][W][component:157]: Component wifi set Warning flag: scanning for networks
[12:23:39]
[12:23:39]assert failed: xQueueSemaphoreTake queue.c:1545 (( pxQueue ))
[12:23:39]
[12:23:39]
[12:23:39]Backtrace:0x40083885:0x3fff46c00x40093c15:0x3fff46e0 0x40099191:0x3fff4700 0x40094c19:0x3fff4830 0x4013f3c1:0x3fff4870 0x40115764:0x3fff4890 0x40114e41:0x3fff48b0 0x40144dea:0x3fff48e0 0x401157c7:0x3fff4900 0x4013d631:0x3fff4920 0x4013f4a7:0x3fff4940
[12:23:39]
[12:23:39]
[12:23:39]
[12:23:39]
[12:23:39]ELF file SHA256: 0000000000000000
[12:23:39]
[12:23:39]Rebooting...
[12:23:39]ets Jun 8 2016 00:22:57
[12:23:39]
[12:23:39]rst:0xc (SW_CPU_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
[12:23:39]configsip: 0, SPIWP:0xee
[12:23:39]clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
[12:23:39]mode:DIO, clock div:2
[12:23:39]load:0x3fff0030,len:1344
[12:23:39]load:0x40078000,len:13836
[12:23:39]load:0x40080400,len:3608
[12:23:39]entry 0x400805f0
[12:23:40][W][component:157]: Component wifi set Warning flag: scanning for networks
[12:23:45]E (11548) task_wdt: Task watchdog got triggered. The following tasks did not reset the watchdog in time:
[12:23:45]E (11548) task_wdt: - loopTask (CPU 1)
[12:23:45]E (11548) task_wdt: Tasks currently running:
[12:23:45]E (11548) task_wdt: CPU 0: IDLE
[12:23:45]E (11548) task_wdt: CPU 1: IDLE
[12:23:45]E (11548) task_wdt: Aborting.
[12:23:45]
[12:23:45]abort() was called at PC 0x400f1ac1 on core 0
[12:23:45]
[12:23:45]
[12:23:45]Backtrace:0x40083885:0x3ffbea3c |<-CORRUPTED
[12:23:45]
[12:23:45]
[12:23:45]
[12:23:45]
[12:23:45]ELF file SHA256: 0000000000000000
[12:23:45]
[12:23:45]Rebooting...
[12:23:45]ets Jun 8 2016 00:22:57
[12:23:45]
[12:23:45]rst:0xc (SW_CPU_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
[12:23:45]configsip: 0, SPIWP:0xee
[12:23:45]clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
[12:23:45]mode:DIO, clock div:2
[12:23:45]load:0x3fff0030,len:1344
[12:23:45]load:0x40078000,len:13836
[12:23:45]load:0x40080400,len:3608
[12:23:45]entry 0x400805f0
[12:23:46][W][component:157]: Component wifi set Warning flag: scanning for networks
[12:23:51]E (11548) task_wdt: Task watchdog got triggered. The following tasks did not reset the watchdog in time:
[12:23:51]E (11548) task_wdt: - loopTask (CPU 1)
[12:23:51]E (11548) task_wdt: Tasks currently running:
[12:23:51]E (11548) task_wdt: CPU 0: IDLE
[12:23:51]E (11548) task_wdt: CPU 1: IDLE
[12:23:51]E (11548) task_wdt: Aborting.
[12:23:51]
[12:23:51]abort() was called at PC 0x400f1ac1 on core 0
[12:23:51]
[12:23:51]
[12:23:51]Backtrace:0x40083885:0x3ffbea3c |<-CORRUPTED
[12:23:51]
[12:23:51]
[12:23:51]
[12:23:51]
[12:23:51]ELF file SHA256: 0000000000000000
[12:23:51]
[12:23:51]Rebooting...
[12:23:51]ets Jun 8 2016 00:22:57
[12:23:51]
[12:23:51]rst:0xc (SW_CPU_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
[12:23:51]configsip: 0, SPIWP:0xee
[12:23:51]clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
[12:23:51]mode:DIO, clock div:2
[12:23:51]load:0x3fff0030,len:1344
[12:23:51]load:0x40078000,len:13836
[12:23:51]load:0x40080400,len:3608
[12:23:51]entry 0x400805f0
[12:23:52][W][component:157]: Component wifi set Warning flag: scanning for networks
[12:23:53][E][esp32_ble:166]: esp_bluedroid_enable failed: 257
[12:23:53][E][esp32_ble:299]: BLE could not be set up
[12:23:53][E][component:119]: Component esp32_ble was marked as failed.
[12:23:53][E][component:164]: Component esp32_ble set Error flag: unspecified
[12:23:54][W][component:239]: Component display took a long time for an operation (81 ms).
[12:23:54][W][component:240]: Components should block for at most 30 ms.
[12:23:59][W][component:239]: Component display took a long time for an operation (81 ms).
[12:23:59][W][component:240]: Components should block for at most 30 ms.
[12:24:01][W][ble_sensor:123]: [Pulse] Cannot poll, not connected
[12:24:04][W][component:239]: Component display took a long time for an operation (81 ms).
[12:24:04][W][component:240]: Components should block for at most 30 ms.
[12:24:09][W][component:239]: Component display took a long time for an operation (81 ms).
[12:24:09][W][component:240]: Components should block for at most 30 ms.
[12:24:14][W][component:239]: Component display took a long time for an operation (81 ms).
[12:24:14][W][component:240]: Components should block for at most 30 ms.
[12:24:17][W][ble_sensor:123]: [O2Sat] Cannot poll, not connected
[12:24:19][W][component:239]: Component display took a long time for an operation (81 ms).
[12:24:19][W][component:240]: Components should block for at most 30 ms.
[12:24:22][E][wifi:490]: Scan timeout!
[12:24:24][W][component:239]: Component display took a long time for an operation (81 ms).
[12:24:24][W][component:240]: Components should block for at most 30