Using the new Arduino IDE for ESP8266 and found bugs, report them here

Moderator: igrr

User avatar
By bbvert
#20551 ESP-12, programmed with Arduino IDE 1.6.4, Adafruit Board def.

I had some trouble getting it to work properly with wireless functionality. So I decided to upload a very simple blink sketch. See below:
Code: Select allvoid setup() {
  pinMode(13, OUTPUT);
  Serial.begin(9600);
  Serial.println("Setting up...");
}
 
void loop() {
  digitalWrite(13, HIGH);
  Serial.println("On...");
  delay(500);
  digitalWrite(13, LOW);
  Serial.println("Off..");
  delay(500);
}

But during setup I get some messages from the wireless setup, like GW and IP address. Stuff that was used in a previous sketch I uploaded. So it looks like old code that should have been eased is still in progmem and is being executed. And it even does somewhat sensible stuff. Since I get a GW address displayed on my serial monitor, it actually must be setting up full WIFI funstionality!

I tried both board definitions- HUZZZAH and Generic.

Upload Message looks like this:
Code: Select allSketch uses 195,564 bytes (37%) of program storage space. Maximum is 524,288 bytes.
Uploading 34736 bytes from C:\Users\STEIGE~1.SYM\AppData\Local\Temp\build8660175318825877906.tmp/sketch_jun03b.cpp_00000.bin to flash at 0x00000000
..................................
Uploading 160872 bytes from C:\Users\STEIGE~1.SYM\AppData\Local\Temp\build8660175318825877906.tmp/sketch_jun03b.cpp_40000.bin to flash at 0x00040000
..............................................................................................................................................................


Any ideas where I'm screwing this up?
User avatar
By FlyingHacker
#20554 How is the program counter getting to the old code?

You shouldn't have to wipe all the flash every time, just like your computer's RAM is full of old data from programs that ran before... It is just never accessed.

Maybe something was buffered on the serial connection?
User avatar
By cal
#20569 Moin,

It's configuration in the flash that gets written when you configure wifi via SDK.
There is no "old code".
You are using the SDK either directly or indirectly and that does init wifi if configured accordingly.

Cal