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: SPI_TFTx2_ILI9341 TFT_fonts TOUCH_TFTx2_ILI9341 mbed
Fork of CANary_corrupt by
Diff: main.cpp
- Revision:
- 21:22bdce9efcb5
- Parent:
- 20:3bf176d14b14
- Child:
- 22:a43df3905863
--- a/main.cpp Fri Mar 08 04:17:30 2013 +0000
+++ b/main.cpp Fri Mar 08 04:43:24 2013 +0000
@@ -256,7 +256,7 @@
//sprintf(sTemp,"Putting uC to sleep.\n");
seconds = time(NULL);
t = *localtime(&seconds) ;
- strftime(sTemp, 32, "Sleeping: %a %m/%d/%Y %X\n", &t);
+ strftime(sTemp, 40, "Sleeping: %a %m/%d/%Y %X\n", &t);
logMsg(sTemp);
//LPC_RTC->CIIR=0x00; // block RTC interrupts
led1=0;
@@ -268,8 +268,8 @@
while (secsNoMsg>canTimeout && secsNoTouch>userTimeout) {
//DeepPowerDown();
tt.wfi(); //enable touch interrupt
- __wfi(); // freeze CPU and wait for interrupt (from canbus or touch)
- //Sleep();
+ //__wfi(); // freeze CPU and wait for interrupt (from canbus or touch)
+ Sleep();
//DeepPowerDown();
}
canIdle=secsNoMsg>canTimeout;
@@ -278,7 +278,7 @@
//sprintf(sTemp,"Waking uC.\n");
seconds = time(NULL);
t = *localtime(&seconds) ;
- strftime(sTemp, 32, "Waking: %a %m/%d/%Y %X\n", &t);
+ strftime(sTemp, 40, "Waking: %a %m/%d/%Y %X\n", &t);
logMsg(sTemp);
if (time(NULL)>(secs+1800)) {
logOpen = false; // Start new file if asleep for more than 30 minutes
