projets de S3 s4 2021
Dependencies: mbed TFT_fonts SPI_TFT_ILI9341
touch.h
- Committer:
- ecowboy
- Date:
- 2019-01-07
- Revision:
- 1:33506fcfdd95
- Parent:
- 0:42ec9a44bc24
- Child:
- 2:fe018965e46c
File content as of revision 1:33506fcfdd95:
#include "mbed.h" #define RXPLATE 350 #define Q 1024 //10 bit TSC Resolution #define PRESSURE 10 class TouchScreen { private: PinName _yp, _ym, _xm, _xp; public: TouchScreen(PinName xp, PinName yp, PinName xm, PinName ym); int readTouch(PinName p, PinName m, PinName a, PinName i); //bool isTouching(void); //Point getPoint(Point p); }; int map(int value, int fromSource, int toSource, int fromTarget, int toTarget);