menu projet
Dependencies: SDFileSystem SPI_TFT_ILI9341 TFT_fonts mbed
Fork of TFT_banggood by
Revision 2:da6faa24e5b2, committed 2015-06-23
- Comitter:
- JoeJoe
- Date:
- Tue Jun 23 07:29:03 2015 +0000
- Parent:
- 1:2b041456fea2
- Commit message:
- JordanRoger
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/main.cpp Thu May 28 06:42:26 2015 +0000 +++ b/main.cpp Tue Jun 23 07:29:03 2015 +0000 @@ -19,7 +19,7 @@ int flip = 0; // Pin de connection de l'écran TFT -SPI_TFT_ILI9341 TFT(p5, p6, p7, p25, p26, p27,"TFT"); //mosi,miso,sclk,cs,reset,dc +SPI_TFT_ILI9341 TFT(p11, p12, p13, p5, p7, p6,"TFT"); //mosi,miso,sclk,cs,reset,dc void attime() { @@ -31,7 +31,7 @@ if(MenuPrincipal==0) { if(PosMenu>0) { PosMenu=PosMenu-1; - wait_ms(50); + wait_ms(75); } } } @@ -41,7 +41,7 @@ if(MenuPrincipal==0) { if(PosMenu<=1) { PosMenu=PosMenu+1; - wait_ms(50); + wait_ms(75); } } } @@ -52,7 +52,7 @@ MenuPrincipal=1; } else { MenuPrincipal=0; - wait_ms(50); + wait_ms(75); } } int main () @@ -64,7 +64,7 @@ BMoins.rise(&trigger2); BValide.rise(&trigger3); set_time(456771); - TFT.claim(stdout); // send stdout to the TFT display + TFT.claim(stdout); TFT.set_orientation(3); TFT.background(White); // Applique le fond de l'écran en blanc TFT.foreground(Black); // Applique la police de caractère en noir @@ -78,7 +78,6 @@ TFT.rect(5,190,826,235,Black); while(1) { - if(flip == 0) { TFT.set_font((unsigned char*) Arial28x28); TFT.locate(220,10); @@ -86,7 +85,6 @@ char buffer[32]; strftime(buffer,32,"%Hh%M",localtime(&heure)); TFT.printf("%s",buffer); - } TFT.set_font((unsigned char*) Neu42x35); if(ecrire==0) { @@ -179,8 +177,7 @@ TFT.printf(" "); } } - ecrire=1; } - + ecrire=1; } } \ No newline at end of file