Proj 324 Final

Fork of ELEC351_Group_T by Plymouth ELEC351 Group T

Committer:
thomasmorris
Date:
Mon Jan 08 21:53:40 2018 +0000
Revision:
47:6d128e500875
Parent:
45:875f7e18a386
Child:
48:244d6d81bb52
FINAL working copy

Who changed what in which revision?

UserRevisionLine numberNew contents of line
thomasmorris 41:859b5e1e3d9a 1 #ifndef _SETUP_HPP_ //SETUP header guard
thomasmorris 25:36699ed589ab 2 #define _SETUP_HPP_
thomasmorris 41:859b5e1e3d9a 3 //File includes
thomasmorris 25:36699ed589ab 4 #include "rtos.h"
thomasmorris 25:36699ed589ab 5 #include "LED.hpp"
thomasmorris 25:36699ed589ab 6 #include "DATA.hpp"
thomasmorris 25:36699ed589ab 7 #include "LCD.hpp"
thomasmorris 25:36699ed589ab 8 #include "SERIAL.hpp"
thomasmorris 30:4cde05cc7c4f 9 #include "TIME.hpp"
thomasmorris 41:859b5e1e3d9a 10 #include <iostream>
thomasmorris 38:8d86e0d8a816 11
thomasmorris 41:859b5e1e3d9a 12 //Signal definitions
thomasmorris 47:6d128e500875 13
thomasmorris 47:6d128e500875 14 //Mutex Locks
thomasmorris 47:6d128e500875 15
thomasmorris 38:8d86e0d8a816 16
thomasmorris 41:859b5e1e3d9a 17 //Time definitions
thomasmorris 45:875f7e18a386 18 #define TimerInterval 15 //This is in seconds
thomasmorris 41:859b5e1e3d9a 19 #define NetworkWait 5000
thomasmorris 41:859b5e1e3d9a 20
thomasmorris 37:7c4d7f206039 21
thomasmorris 41:859b5e1e3d9a 22
thomasmorris 41:859b5e1e3d9a 23 //Forward Declarations of functions
thomasmorris 25:36699ed589ab 24
thomasmorris 25:36699ed589ab 25 void Serial_Comms();
chills 26:78f5e454e59f 26 void Sample_signal_set();
chills 26:78f5e454e59f 27 void Console_Output_ISR();
thomasmorris 41:859b5e1e3d9a 28 void Serial_Comms_Data_Get();
thomasmorris 41:859b5e1e3d9a 29 void Sampling_ISR();
thomasmorris 41:859b5e1e3d9a 30 void Console_Output_ISR();
thomasmorris 41:859b5e1e3d9a 31 //Declarations of Varialbes
thomasmorris 25:36699ed589ab 32
thomasmorris 25:36699ed589ab 33 float Sample_Rate;
thomasmorris 41:859b5e1e3d9a 34 int LCD_sprintf;
thomasmorris 41:859b5e1e3d9a 35 double temp = 0;
thomasmorris 41:859b5e1e3d9a 36 double pressure = 0;
thomasmorris 41:859b5e1e3d9a 37 double lux = 0;
thomasmorris 41:859b5e1e3d9a 38 string buffer_time = 0;
thomasmorris 41:859b5e1e3d9a 39 char buffer[32];
thomasmorris 41:859b5e1e3d9a 40 char scom_time_buffer[32];
thomasmorris 41:859b5e1e3d9a 41 char msel_time_buffer[32];
thomasmorris 41:859b5e1e3d9a 42
thomasmorris 47:6d128e500875 43
thomasmorris 25:36699ed589ab 44
thomasmorris 41:859b5e1e3d9a 45 //Time out Declarations
thomasmorris 25:36699ed589ab 46 Timeout sw1TimeOut;//Used to prevent switch bounce
thomasmorris 30:4cde05cc7c4f 47 Timeout sw2TimeOut;//Used to prevent switch bounce
thomasmorris 25:36699ed589ab 48
thomasmorris 25:36699ed589ab 49
thomasmorris 25:36699ed589ab 50
thomasmorris 41:859b5e1e3d9a 51 using namespace std;//Set default namespace enables use of iostream with serial comms
thomasmorris 25:36699ed589ab 52 #endif