Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: RTC-DS1307 SPI_TFT_ILI9341 TFT_fonts mbed tsi_sensor
Fork of TFT_Mikroelectronika_IL9341_sketchpad by
Diff: analoglogic.h
- Revision:
- 48:76ac309a2bd9
- Parent:
- 44:1c516642c34e
diff -r 424f9c1b857e -r 76ac309a2bd9 analoglogic.h
--- a/analoglogic.h Fri May 26 08:45:43 2017 +0000
+++ b/analoglogic.h Fri May 26 09:34:38 2017 +0000
@@ -23,8 +23,9 @@
else if (x > 0 && x < 50 && y > 150 && y < 200) // side button 4
{
//set desired state to 4
- // f_cycle = !f_cycle;
- return 4;
+ f_cycle = !f_cycle;
+ f_cycle_secs = tm_c.sec;
+ // return 4;
}else if (x > 0 && x < 50 && y > 200 && y < 240) // button home
{
@@ -109,8 +110,10 @@
TFT.locate(220,210);
TFT.printf("%d",tm_c.year); */
if (f_cycle){
+ if ((f_cycle_secs + f_cycle_wait) == tm_c.sec){
f_state = 1;
- wait(1);
+ f_cycle_secs = tm_c.sec;
+ }
}
switch (ana_clock_press()){
case (-1): break;
