2d1

Fork of TS_DISCO_F429ZI by ST

Keyboard_Ts.h

Committer:
Robsonik16
Date:
2017-05-05
Revision:
1:972c0d202476

File content as of revision 1:972c0d202476:


#ifndef KEYBOARD_H
#define KEYBOARD_H

#include "mbed.h"
#include "TS_DISCO_F429ZI.h"
#include "Keyboard_Ts.h"
#include "Led_Lcd.h"


enum KeyboardState{
    RELASED,
    BUTTON_0,
    BUTTON_1,
    BUTTON_2,
    BUTTON_3};

class KeyboardTs
:public LedLcd
{
    public:
        KeyboardTs(unsigned char _ucColIndex=0);
        enum KeyboardState eRead(void);
        private:
        bool touchInRect(uint16_t TouchXpos, uint16_t TouchYpos,uint16_t Xpos, uint16_t Ypos, uint16_t Width, uint16_t Height);
        uint16_t x, y;
        unsigned char ucColIndex;
};
#endif