rteerter
Dependencies: C12832
Revision 7:816b490a3119, committed 2020-05-02
- Comitter:
- burgerking
- Date:
- Sat May 02 11:55:03 2020 +0000
- Parent:
- 6:f8cb706c480c
- Commit message:
- a_code;
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
diff -r f8cb706c480c -r 816b490a3119 main.cpp --- a/main.cpp Tue Sep 19 15:25:01 2017 +0000 +++ b/main.cpp Sat May 02 11:55:03 2020 +0000 @@ -3,17 +3,24 @@ // Using Arduino pin notation C12832 lcd(D11, D13, D12, D7, D10); +DigitalIn fire(D4); +int main(){ + int etatBtnPrev,etatBtnAct; + while(1){ + etatBtnAct=fire; + if(etatBtnAct==1&&etatBtnPrev==0){ + lcd.cls(); + lcd.locate(0,10); + lcd.printf("Front \n Montant"); + wait(1.0); + ldc.printf(wait); + } + else{ + lcd.cls();wait(0.05); + } + etatBtnPrev=etatBtnAct; + } + } + -int main() -{ - int j=0; - lcd.cls(); - lcd.locate(0,3); - lcd.printf("mbed application shield!"); - while(true) { // this is the third thread - lcd.locate(0,15); - lcd.printf("Counting : %d",j++); - wait(1.0); - } -}