CANDY-LINE / node-red-contrib-lwm2m

Step-by-step tutorial is available at
http://candy-line.tumblr.com/post/166976363228/oma-lwm2m-node-red-node
Apache License 2.0
7 stars 3 forks source link

Objects JSON #2

Closed ram1505 closed 6 years ago

ram1505 commented 6 years ago

Hi again, I'm trying to pull temperature readings from my DHT11 sensor which is connected to my raspberry pi using LWM2M. There is a field under the LWM2M that allows JSON input. I am currently testing using the following:

{ "3303": { "0": { "5700": { "type": "FLOAT", "acl": "R", "value": 23.5 } } } }

The value field is currently static and is not linked to my actual sensor reading. How can I integrate my DHT11 sensor reading with this Object? Can I introduce a function node somewhere in-between? Please help.

ram1505 commented 6 years ago

Hey, I figured it. By adding /3303/0/5700 to the topic, I was successfully able to send the temperature data from DHT sensor to my LWM2M server.