![]() |
Rock Monitoring
V 1.0
|
#include <Gateway.h>

Public Member Functions | |
| Gateway () | |
| uint8_t | init (void) |
| void | showStructContent (uint8_t node) |
| uint8_t | sendToServer (Sensors::structSensors *dataToSend) |
| uint8_t | sendSleep (uint8_t ID) |
| uint8_t | requestData (uint8_t ID) |
| uint8_t | receiveNodeData (void) |
| void | deepSleep (void) |
| int8_t | wakeUp (void) |
| uint8_t | measureBattery (void) |
| void | run (void) |
Private Attributes | |
| Sensors::structSensors | mySensorStruct |
| Sensors::structSensors | mySensorStructArray [numberOfNodes] |
| uint32_t | sleepTime =60 |
| char | timeString [12] |
| uint8_t | sensorID [numberOfNodes] ={3,4,5} |
| uint8_t | notReceived =0 |
| uint8_t | notReceivedCnt =0 |
| uint8_t | notSleepCnt =0 |
| uint8_t | nothingReceived =0 |
| uint8_t | currentNode =0 |
| Lora | myLora |
| Connection3G | my3G |
| Leds | myLeds |
| Gateway::Gateway | ( | ) |
This method creats object of Lora and Connection3G
Definition at line 6 of file Gateway.cpp.
| void Gateway::deepSleep | ( | void | ) |
Sets gateway into deepSleep mode
Definition at line 98 of file Gateway.cpp.
| uint8_t Gateway::init | ( | void | ) |
This method initializes all the components of the sensornode
Definition at line 11 of file Gateway.cpp.
| uint8_t Gateway::measureBattery | ( | void | ) |
This method shuts down the battery charger and measures the battery level
Definition at line 27 of file Gateway.cpp.
| uint8_t Gateway::receiveNodeData | ( | void | ) |
Receives data from a sensor-node
Definition at line 77 of file Gateway.cpp.
| uint8_t Gateway::requestData | ( | uint8_t | ID | ) |
Requests data from a sensor-node
Definition at line 70 of file Gateway.cpp.
| void Gateway::run | ( | void | ) |
structures the procedure of the gateway
Definition at line 116 of file Gateway.cpp.
| uint8_t Gateway::sendSleep | ( | uint8_t | ID | ) |
Sends to all the sensor-nodes a sleep command
Definition at line 91 of file Gateway.cpp.
| uint8_t Gateway::sendToServer | ( | Sensors::structSensors * | dataToSend | ) |
Uploads all the received data to a web-server
Definition at line 84 of file Gateway.cpp.
| void Gateway::showStructContent | ( | uint8_t | node | ) |
Shows the content of a received packet from a sensor-node
Definition at line 40 of file Gateway.cpp.
| int8_t Gateway::wakeUp | ( | void | ) |
After deepSleep reconfigures all the modules
Definition at line 108 of file Gateway.cpp.
|
private |
|
private |
|
private |
|
private |