-
Notifications
You must be signed in to change notification settings - Fork 12
Description
I am working on low power IOT home automation network. The code I wrote send up to 5 different sensor values, their respective sensor types and 5 different status values for that particular device along with the device ID to identify the device. These devices can also receive MQTT commands from any MQTT client by publishing with topic "command/". My repo is linked below:
https://github.com/happytm/BatteryNode
Right now I am using ESP Dash android app to monitor and control my network but your software could be better because it can not only display but store it in database. I have used node-red but I think it is overkill in my case.
I would like to use your front end to display data on web and store it in database. Data will be collected by network of my battery nodes and published as MQTT messages by the gateway. I wanted to see how I can implement my ProbeReceiver.ino sketch with your code and display all sensor data it collects from all battery node devices on network . Each BatteryNode devices send data to one gateway and gateway has MQTT broker built in which publishes data in following format for example data received from a BatteryNode with Device ID = 36:
Serial debug messages on Gateway device where it receive data from all Battery node devices:
Command sent to device no. 36 = 'command/36/06/16/26/36/46/
################ Person 1 arrived ######################
Received Topic 'Sensordata/Person1/Home
Received Topic 'Sensordata/Signal/-48
Received Topic 'Sensordata/Person1/in/Livingroom
Received Topic 'SensorData/36/6/2.90
Received Topic 'SensorData/36/16/20
Received Topic 'SensorData/36/26/50
Received Topic 'SensorData/36/36/596
Received Topic 'SensorData/36/46/37
Received Topic 'DeviceStatus/36/DeviceMode/0
Received Topic 'DeviceStatus/36/DeviceIP/36
Received Topic 'DeviceStatus/36/WiFiChannel/7
Received Topic 'DeviceStatus/36/SleepTime/1
Received Topic 'DeviceStatus/36/UpTime/127
6,16,26,36,46 in above messages are predefined sensor types to identify what kind of sensors they are for example 6 = voltage, 16 = temperature , 26 = humidity, 36 = pressure, 46 = light intensity etc.
Signal Strength of remote sensor: -23
Received Topic 'Sensordata/Signal/-23
Serial debug messages from BatteryNode device no. 36:
Sensor Type values sent to controller: 24:06:10:1A:24:2E
Device status values sent to controller: 24:00:24:07:01:8B
Sensors values sent to controller: 24:93:38:25:19:59
Message received from Controller: 24:06:10:1A:24:2E (This message is received from gateway).
I hope you can help me.
Thanks.