
Program 2d_2 obsługujący wyświetlacz LCD
Dependencies: LCD_DISCO_F429ZI mbed TS_DISCO_F429ZI BSP_DISCO_F429ZI
main.cpp
- Committer:
- apepkowski
- Date:
- 2020-06-01
- Revision:
- 1:bb8bfbe63b08
- Parent:
- 0:aa756e4665e5
File content as of revision 1:bb8bfbe63b08:
#include "mbed.h" #include "KeyboardTsLcd.h" int main(){ KeyboardTsLcd Keyboard(0); KeyboardTsLcd LedLcd(2); while(1){ Keyboard.eRead(); wait(0.1); switch(Keyboard.pKeyboard -> eRead()){ case BUTTON_0: LedLcd.pLed -> On(BUTTON_3); break; case BUTTON_1: LedLcd.pLed -> On(BUTTON_2); break; case BUTTON_2: LedLcd.pLed -> On(BUTTON_1); break; case BUTTON_3: LedLcd.pLed -> On(BUTTON_0); break; default: LedLcd.pLed -> On(NO_BUTTON_PRESSED); break; } wait(0.1); } }