Closed LIFsCode closed 1 year ago
Reason was the missing initial timestamp, which caused the esp32 to run form 1970 on... du to a "feature" in the arduino ESP32Time library, gettings the timestamp will wait for 5000 milliseconds.
This extremely long wait will cause a buffer overrun in the I2S sampling engine, which leads to the observed behavior.
This is mainly fixed in 8cb379452d39ef79980ea1e904ed8368217c2e11:
Fix recording buffer overrun when creating the 2nd file
Init the time (based on build date) if time is not correctly set, the getLocalTime() will stuck for 5 ms due to invalid timestamp
Since after boot we don't have any proper time available chose build date which is the last guaranteed valid time we know.
NOTE: this does not fix correct handling of buffer overruns
reported here --> ~1:40 - 1:50
2 things are suspicious:
(92542) WAV: Finishing wav file size: 1920044
(97167): main: filename /sdcard/eoc/ELOCprod24964_1970-01-01_00_01_30.wav
This could indicate, that there is a buffer overrun in the I2SMEMSSampler, due to the delay of creating the 2nd filename.