In the file "Adafruit_STMPE610.cpp", the Wire.requestFrom() should not be followed by Wire.endTransmission(). The Wire.requestFrom() is a complete I2C transmission on its own.
The Wire.endTransmission() is only used after a Wire.write() when data in the buffer needs to be transmitted.
There is an other call to Wire.requestFrom() which is encapsulated by both Wire.beginTransmission() and Wire.endTransmission(). Those should both be removed, Wire.requestFrom() stands on its own.
In the file "Adafruit_STMPE610.cpp", the
Wire.requestFrom()
should not be followed byWire.endTransmission()
. TheWire.requestFrom()
is a complete I2C transmission on its own. TheWire.endTransmission()
is only used after aWire.write()
when data in the buffer needs to be transmitted.There is an other call to
Wire.requestFrom()
which is encapsulated by bothWire.beginTransmission()
andWire.endTransmission()
. Those should both be removed,Wire.requestFrom()
stands on its own.Explanation: Common-mistakes, number 2 and 3. See also my alternative explanation of the functions of the Wire library.