esp8266 / Arduino

ESP8266 core for Arduino
GNU Lesser General Public License v2.1
15.98k stars 13.33k forks source link

Wire.endTransmission() wrong return value #65

Closed igrr closed 9 years ago

igrr commented 9 years ago

Currently it returns the number of bytes transmitted. This is how it should work:

Returns byte, which indicates the status of the transmission:
0:success
1:data too long to fit in transmit buffer
2:received NACK on transmit of address
3:received NACK on transmit of data
4:other error
erniberni commented 9 years ago

Hi Ivan, was there any change in the wire lib after this finding? I think this is the reason the i2c scanner doesn't work and also the BMP180 lib expects "0" for successful module recognition. Regards Reinhard

igrr commented 9 years ago

@erniberni Latest version should have this issue fixed.

erniberni commented 9 years ago

Thanks Ivan, I2C scanner now works perfectly. Reinhard