Ben Gordon
/
ELEC351_GroupA-branch1
Troubleshooting
Diff: displayThread.cpp
- Revision:
- 17:b7cd66c5f845
- Parent:
- 14:9d4c24c3c696
--- a/displayThread.cpp Thu Nov 08 23:22:05 2018 +0000 +++ b/displayThread.cpp Fri Nov 09 14:24:39 2018 +0000 @@ -1,6 +1,6 @@ #include "displayThread.h" -InterruptIn button1(b1); +/*InterruptIn button1(b1); InterruptIn button2(b2); U_BYTE buttonPressed; @@ -12,14 +12,22 @@ button2.rise(&buttonTrigger2); Display display(RS,E,d4,d5,d6,d7); //rs,e,d4,d5,d6,d7 display.INIT(); + wait_us(4000); + display.pageOne(); while(1) { if((buttonPressed & 1) == 1) { display.pageTwo(); buttonPressed &= 2; //clear bit 1 - } - } + } + + if((buttonPressed & 2) == 2) + { + display.pageOne(); + buttonPressed &= 1; + } + } //while(1); } void buttonTrigger1() @@ -30,4 +38,4 @@ void buttonTrigger2() { buttonPressed |= 2; //set second bit -} \ No newline at end of file +}*/ \ No newline at end of file