Modified version of the DmTftLibrary, optimized for the LPC4088 Experiment Base Board
Dependents: lpc4088_ebb_dm_calc lpc4088_ebb_dm_bubbles
Fork of DmTftLibrary by
Diff: DmTouch.cpp
- Revision:
- 11:8b441dd1d470
- Parent:
- 10:d263094e666d
- Child:
- 12:eb97ccfe7c3f
diff -r d263094e666d -r 8b441dd1d470 DmTouch.cpp --- a/DmTouch.cpp Wed Jul 09 08:31:34 2014 +0000 +++ b/DmTouch.cpp Wed Sep 10 12:47:47 2014 +0000 @@ -249,7 +249,9 @@ void DmTouch::readTouchData(uint16_t& posX, uint16_t& posY, bool& touching) { uint16_t touchX, touchY; - getMiddleXY(touchX,touchY); + if (!getMiddleXY(touchX,touchY)) { + touching = false; + } posX = getDisplayCoordinateX(touchX, touchY); posY = getDisplayCoordinateY(touchX, touchY);