It sounds like you're encountering a memory allocation issue with the bme68x_demo_sample due to conflicts in the number of sensor definitions and the physical memory limits of your board. Given the error message "dram0_0_seg overflowed by 9256 bytes" and the specifics you've mentioned, it looks like the application is trying to allocate more memory than is available on your ESP32 board. Here's how you can resolve this issue: 1. Reduce the Number of Sensors: Since each sensor instance (BSEC_INSTANCE_SIZE) consumes 3272 bytes and your current settings are for 8 sensors, this significantly exceeds the default memory capacity of standard ESP32 boards like the ESP32-WROOM-32E(https://www.xecor.com/product/esp32-wroom-32e-n16). Adjust the NUM_BME68X_UNITS to a lower number that fits within the memory limits of your board. Start with the same number as NUM_OF_SENS (i.e., 4) to see if this resolves the memory overflow issue. 2. Configuration and Compilation Settings: Ensure that the configuration in your development environment matches the physical setup and memory capabilities of your ESP32 board. Double-check that the settings in the SDK configuration (sdkconfig) file align with these requirements. 3. Optimize Memory Usage: Look for opportunities to optimize the memory usage in your code. This might involve modifying how data is stored and managed or reducing the footprint of other parts of your application. 4. Multi-instance Management: If you need to manage multiple sensor instances, make sure that your code correctly handles these instances within the memory constraints. This can be managed by dynamically allocating and deallocating memory as needed, rather than having all instances reside in memory simultaneously. 5. Test on a Compatible Board: If reducing the number of sensors and optimizing the code does not resolve the issue, consider testing the application on a board with higher memory capacity or one that supports external memory. By carefully managing the memory and adjusting the number of sensor instances, you should be able to run your application successfully on standard ESP32 boards. If the application's memory demands continue to exceed what's available, you might need to consider either upgrading the hardware or further optimizing the software.
... View more