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: BMP280 ELEC350-Practicals-FZ429 TextLCD BME280 ntp-client
Diff: message.hpp
- Revision:
- 5:f87129ac8bf3
diff -r 740cba3f2716 -r f87129ac8bf3 message.hpp
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/message.hpp Thu Nov 29 16:08:28 2018 +0000
@@ -0,0 +1,28 @@
+// Class for Sampled Data
+#ifdef _SAMPLE_MESSAGE_
+#define _SAMPLE_MESSAGE_
+class sample_message
+{
+private:
+ float temp = 0;
+ float pressure = 0;
+ int sw1State = 0;
+ int sw2State = 0;
+public:
+ sample_message(float f1, float f2, int s1, int s2) // Constructor
+ {
+ temp = f1;
+ pressure = f2;
+ sw1State = s1;
+ sw2State = s2;
+ }
+ ~sample_message() // Desconstructor
+ {
+ temp = 0;
+ pressure = 0;
+ sw1State = 0;
+ sw2State = 0;
+ }
+};
+
+#endif
\ No newline at end of file