Version 8, working version with Alix, sams and ollies code. Displays time, date and sensor info onto terminal, LCD and networking, and saves onto SD card.

Dependencies:   BMP280 ELEC350-Practicals-FZ429 TextLCD BME280 ntp-client

Committer:
Alix955
Date:
Thu Dec 13 15:24:22 2018 +0000
Revision:
10:eea19f8e6122
Parent:
6:b7f6e0c0f646
Child:
12:4c7eaac8ceef
Alix & Sams versions combined;

Who changed what in which revision?

UserRevisionLine numberNew contents of line
Alix955 10:eea19f8e6122 1 #include "mbed.h"
Alix955 10:eea19f8e6122 2 #include <stdio.h>
Alix955 10:eea19f8e6122 3 #include <string>
Alix955 10:eea19f8e6122 4
O_Thom 6:b7f6e0c0f646 5 typedef struct
O_Thom 6:b7f6e0c0f646 6 {
O_Thom 6:b7f6e0c0f646 7 double temp;
O_Thom 6:b7f6e0c0f646 8 double pressure;
O_Thom 6:b7f6e0c0f646 9 double ldr;
O_Thom 6:b7f6e0c0f646 10 } sample_message;
O_Thom 6:b7f6e0c0f646 11
O_Thom 6:b7f6e0c0f646 12 extern sample_message msg;
Alix955 10:eea19f8e6122 13
Alix955 10:eea19f8e6122 14
Alix955 10:eea19f8e6122 15 typedef struct
Alix955 10:eea19f8e6122 16 {
Alix955 10:eea19f8e6122 17 string day; //current day, mon - sun
Alix955 10:eea19f8e6122 18 string month; //current month, jan - dec
Alix955 10:eea19f8e6122 19 string date; //current date, 1-31
Alix955 10:eea19f8e6122 20 string time; //current time SS:MM:HH
Alix955 10:eea19f8e6122 21 string year; //current year 1970 - 2035?
Alix955 10:eea19f8e6122 22
Alix955 10:eea19f8e6122 23 string current_time; //all of the above in one string, day month date time year
Alix955 10:eea19f8e6122 24
Alix955 10:eea19f8e6122 25 } time_and_date;
Alix955 10:eea19f8e6122 26
Alix955 10:eea19f8e6122 27 extern time_and_date Timemsg;