Aneesh
Aneesh

Reputation: 599

Bluemix node-red add multiple IBM IoT nodes

I understand that we can add IBMIoT nodes to node-red in bluemix and then read the data from the node and do any processing of the data as required by the use case. For this we need to give a device id to the node. Is it possible to create a flow where the device id is dynamic. Let's say I have 10000 sensors / devices. I want to read the data for each of these sensors in a mulitplexed fashion by changing the device id. It is impossible to create 10000 device nodes. So, what is the best way to manage this number of sensors / devices?

Upvotes: 0

Views: 268

Answers (2)

Vishnudas
Vishnudas

Reputation: 1

We can tick All option (device Id) in IBM IoT node option pop up , which helps to connect all Registered devices with different deviceId to Single IBM IoT Node.

Upvotes: 0

amadain
amadain

Reputation: 2836

For the In nodes, set the deviceId to All.

enter image description here

Then use the msg.deviceId property to figure out which deviceId it is. This can also be used to used with the IBM IoT Out node. When msg.deviceId is set on a message sent to the Out node, it will over-ride what is set in the node itself. If it isn't working for you, please add your code.

Upvotes: 1

Related Questions