Error in Serial monitor after upload

Hi everybody, Getting error on serial monitor after uploading program.

[vApplicationStackOverflowHook] STACK OVERFLOW - TaskName()

Please suggest how to deal with this error? The compile and upload is without error. Program is attached due to size limit

my_ESP_Ameba.ino (11.5 KB)

This is something that caught my eye

  while (Wire.available()) {         //are there bytes to receive.
    Wire.requestFrom(DEV_ID3, 40, 1); //call the circuit and request 20 bytes (this may be more than we need)

In other places, you first request and next check if there is something available.

Also, on an Arduino, Wire.write() does not actually transmit; this might be different for an ESP. beginTransmission() sets up the address, write() places data in a buffer and endTransmission() transmits the actual address and data.

Similar, requestFrom() on an Arduino does a beginTransmission(), so I'm not sure if you need to do that.

Disclaimer
I2C is not quite my area of expertise.

Thanks sterretje
Even after correcting that mistake, the same message appears on the serial monitor after pressing the reset button.

The whole message is as follows if you can find something ,

=========================================================

ROM Version: 0.3

Build ToolChain Version: gcc version 4.8.3 (Realtek ASDK-4.8.3p1 Build 2003)

=========================================================

Check boot type form eFuse

SPI Initial

Image1 length: 0x3a88, Image Addr: 0x10000bc8

Image1 Validate OK, Going jump to Image1

BOOT from Flash:YES

SPI calibration

Find the avaiable window

Baud:3; auto_length:0; Delay start:0; Delay end:63

[SPIF Err]SpicNVMCalStore: The flash memory(@0x9080 = 0x0) is not able to be write, Erase it first!!
===== Enter Image 1 ====

SPI calibration

Find the avaiable window

Baud:2; auto_length:21; Delay start:0; Delay end:63

[SPIF Err]SpicNVMCalStore: The flash memory(@0x90b0 = 0x0) is not able to be write, Erase it first!!

SDR Controller Init

Test 0: No match addr 0xc9d38 => 0xf != 0xc

Test 0: No match addr 0x1f7c10 => 0x5 != 0xa

OTA addr 0x0 INVALID

load NEW fw 0

Flash Image2:Addr 0xb000, Len 81948, Load to SRAM 0x10006000

Image3 length: 0x2e360, Image3 Addr: 0x30000000

Img2 Sign: RTKWin, InfaStart @ 0x10006049

===== Enter Image 2 ====

addr:100317C0 size:0003E840

addr:30041974 size:001BE68C

[vApplicationStackOverflowHook] STACK OVERFLOW - TaskName()