A Weather station designed to read the values of temperature and pressure from the sensor (BMP180), data displayed via a nokia N5110 display.
Dependencies: BMP180 N5110 PowerControl mbed
Diff: Barometer.cpp
- Revision:
- 27:06fbad36c15e
- Parent:
- 26:c0d8d2f68406
--- a/Barometer.cpp Mon May 11 10:12:22 2015 +0000 +++ b/Barometer.cpp Mon May 11 22:10:42 2015 +0000 @@ -95,7 +95,7 @@ lcd.printString(buffer3,0,3); lcd.printString(buffer4,0,4); lcd.printString(buffer5,0,5); - wait(0.1); + wait(0.01);// } @@ -153,11 +153,12 @@ -/// Checks if the power saver option is set by the user, if yes attach a timeout to call save power; if its not set detach the timeout +/// Provides the power saving features void powerSaverCheck() // checks if the powersaverFlag is set { if (powerSaverFlag == 1) { while (1) { + thresholdCheck(); alarmClockCheck(); updateTime(); loggerData(); @@ -1051,8 +1052,8 @@ void unitsSetting() { state = 0; - powerSaverCheck(); while (1) { + powerSaverCheck(); alarmClockCheck(); updateTime(); loggerData();