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

Moderator: igrr

User avatar
By ficeto
#17684 that serial thing is fixed, but the changes have not yet been pulled into the main repo,so sit tight, find other bugs and report :) I imagine Ivan will pull them when he's back from wherever he is ;) Your I2C should be fine with what you are currently running.
User avatar
By martinayotte
#17753 Hi ficeto,
I gave it a try and it is much better. :)
No more watchdog crash on SerialRX.
But I saw that I2C was still not working. :?
But I've figured out something : if I use the now deprecated Wire.pins(12,13), it is actually working. So the problem is somewhere is the newer Wire.begin(12, 13).
I will dig further ...

EDIT : some digging done !
I've changed the follwing code :
Code: Select allvoid TwoWire::begin(int sda, int scl){
+  default_sda_pin = sda;
+  default_scl_pin = scl;
  twi_init(sda, scl);   
  flush();
}

it sounds like there is a call to TwoWire::begin(void) after TwoWire::begin(int sda, int scl), which overwrite the previous pins. :(
Anyway, I have now that workaround...

EDIT2: It is a false positive, it is working after upload, but if I do a reset, it stop working. Really strange :?
(I think I will have to revert again to the March 27 version)
EDIT3: The constructor issue and the stop after reset issue are separate, after power cycle, it is working again.
User avatar
By elmusico101
#52584 Hello martinayotte,

I'm using the nodemcu v3 development board and I had trouble using any gpio to talk via i2c with an adxl345. My question is if inserting that function in the wire.cpp file will do the trick so that now I can call wire.Begin(16,14) as my SDL and SCL pins? Is that correct? I'm using Arduino IDE 1.6.5 with the ESP8266 2.1.0 package as the board manager.

Thanks for your help!
User avatar
By martinayotte
#52602 The above bug was a year ago, it have been fixed a while ago.
It was also already fixed in 2.1.0, so I don't understand why you would have any issue.
The problem is probably somewhere else ...
Did you added PullUps resistors on the I2C bus ?
Don't rely in weak internal pullups, they are weak, especially in your case, GPIO16 doesn't have any internal pullup.