Kamil Maruta / Mbed 2 deprecated zad_2d_2

Dependencies:   BSP_DISCO_F429ZI LCD_DISCO_F429ZI TS_DISCO_F429ZI mbed

KeyboardTsLcd.cpp

Committer:
marutson
Date:
2018-05-14
Revision:
0:6b004e89c859

File content as of revision 0:6b004e89c859:


#include "KeyboardTsLcd.h"
 
KeyboardTsLcd::KeyboardTsLcd()
{
pKeyboard = new KeyboardTs(0);
pLed = new LedLcd(0);
 
};
int KeyboardTsLcd::eRead (void) {
        switch(pKeyboard -> eRead()) {
            case LED_0:
                pLed -> On(0);
                return 2;
            case LED_1:
                pLed -> On(1);
                return 1;
            case LED_2:
                pLed -> On(2);
                return 0;
            
            default:
                pLed -> On(4);
                return 4;
            }
};