Code supports writing to the SD card as well as working with the Volckens group smartphone apps for the mbed HRM1017
Dependencies: ADS1115 BLE_API BME280 Calibration CronoDot EEPROM LSM303 MCP40D17 NCP5623BMUTBG SDFileSystem SI1145 STC3100 mbed nRF51822
Fork of UPAS_BLE_and_USB by
Revision 110:67980ebdebf6, committed 2016-02-12
- Comitter:
- caseyquinn
- Date:
- Fri Feb 12 02:15:02 2016 +0000
- Parent:
- 109:33d7fc6c1b9b
- Child:
- 111:5f2ba5f1a468
- Commit message:
- Replaced logg interupt using Timeout with Ticker function.
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/main.cpp Fri Feb 12 00:52:10 2016 +0000 +++ b/main.cpp Fri Feb 12 02:15:02 2016 +0000 @@ -45,7 +45,9 @@ Calibration calibrations(1); //Default serial/calibration if there are no values for the selected option Timeout stop; //This is the stop call back object -Timeout logg; //This is the logging call back object +//Timeout logg; //This is the logging call back object +Ticker logg; //This is the logging call back object + uint16_t serial_num = 1; // Default serial/calibration number int RunReady =0; @@ -179,8 +181,9 @@ void log_data() { - logg.detach(); - logg.attach(&log_data, logInerval); // reading and logging data must take significintly less than 0.5s. This can be increased. + //logg.detach(); + //logg.attach(&log_data, logInerval); // reading and logging data must take significintly less than 0.5s. This can be increased. + RTC.get_time(); @@ -609,7 +612,9 @@ // Main Control Loop - logg.attach(&log_data, logInerval); // uses callbacks or block Interrupts for anything that uses i2c + //logg.attach(&log_data, logInerval); // uses callbacks or block Interrupts for anything that uses i2c + logg.attach(&log_data, logInerval); + }