Display text on screen.
Dependencies: TextLCD mbed MaxSonar RTC-DS1307
Fork of TextLCD_HelloWorld by
Revision 15:1e08396885bf, committed 2017-05-26
- Comitter:
- aueangpanit
- Date:
- Fri May 26 12:08:55 2017 +0000
- Parent:
- 14:2bde99b3345c
- Commit message:
- it's working!
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/main.cpp Fri May 26 11:13:59 2017 +0000 +++ b/main.cpp Fri May 26 12:08:55 2017 +0000 @@ -493,6 +493,7 @@ r2 = range2->read(); } + void Clock() { questionScreen.write(1); @@ -507,7 +508,22 @@ rtc.startClock(); - while(1){ + bool clock = true; + while(clock){ + + UpdateRange(); + if(r1 < 25 && r2 < 25) + { + cloo.detach(); + if(CheckExit(r1, r2)) + { + + GameOption(); + clock = false; + break; + } + cloo.attach(&displayTime, 1); + } wait_ms(50); //wait so button states do not overlap