Closed baqwas closed 4 years ago
@baqwas Could you please point to the exact section in the tutorial where this refers to? A link would be perfect.
Hello @neumannrf,
I was following the steps from Step 4. Create a live dashboard using Node-RED having established the connection from my smartphone to Browse Devices under IBM Watson IoT Platform (i.e. the smartphone is using the IoT app to send accelerometer data to the MQTT broker in the Cloud).
The next step in your tutorial/guide/demo is to construct a Node-RED dashboard. In constructing the flows, information about the MQTT broker, default port & topic are not explicitly mentioned in the text. My assumption was to use the MQTT properties from the preceding step that worked (and are still working as I write this note). Unfortunately, when I plug in these values to the N-R MQTT IN node, the node status simply reports "connecting..." with a yellow ring but no further progress.
My inquiry was trying to understand whether I should be using the previously configured MQTT broker properties. If yes then I would like to request your assistance on guidance for troubleshooting since the debug node in the same flow is not producing any output either. (I am familiar with MQTT brokers under several different APIs but I am totally ignorant about the interactions in Watson). Thanks a bunch.
Kind regards.
P.S. I observed that Watson requires ssl:// in lower case for the MQTT broker but N-R has the SSL/TLS checkbox and therefore I entered the fully qualified broker name without the protocol prefix. Pardon my ignorance again but is my assumption correct?
Hi @baqwas, sorry for the delay!
You are right, in step 4 (more specifically, Create live dashboard with acceleration data) you are supposed to (re-)use the node configuration described in step 3 (more specifically, Create a simple Node-RED app).
I have noticed that when you export or copy-and-paste a mqtt in
node, it does not carry over the username / password
information from the Security tab, so watch out for that. I suggest you dig deeper into the node configuration levels to make sure none is left blank.
The fact that the debug
node is not showing any output can come from at least three sources:
debug
node is not enabled.I'll start with 3 because it is the simplest. The debug node has a button on the right side. When you click it, it goes from gray to green. Make sure it is green and Deploy your Node-RED app to see the effects. Every change you do in the Node-RED workflow requires a new deployment to become active.
The second option up there may be caused by the lack of security credentials in the Subscribe to MQTT event
node. If your first two-node workflow looked like this, you should be getting some output from the debug node
Lastly, you could check if the event data is indeed arriving in your Watson IoT Platform instance. Go to https://internetofthings.ibmcloud.com/, find your organisation in the top-right corner and look for a connected device and recent events. If no devices are connected, or there are no recent events, you may need to redo the initial smartphone setup configuration.
To your PS, I'd say that it depends. On you Android phone you should add the ssl://
prefix as instructed here. On the Node-RED app configuration you do not need the ssl://
prefix but you do need to check the SSL/TLS box as instructed here.
I hope that helps! In case it does, please let me know so I can close the issue.
PS: Please consider giving a ⭐ to the repository and the tutorial if you have found them useful.
Thanks for your detailed instructions. I worked on a related Watson-MQTT-NR tutorial several months ago. I'll adopt a parallel approach - work along the lines you have suggested and also try parametric exercises with the other tutorial. Many thanks again.
Kind regards.
@baqwas You're welcome! But please do let me know if you still cannot make it work after what I suggested. In case there is a bug, I'd be glad to fix it.
Hello!
Under Subscribe to MQTT event node, what are the settings for the broker and topic? Didn't see anything in your notes (apologies, if I have overlooked these two values that are needed to deploy the flow correctly, if I am not mistaken).
Are these the values that should be used: topic: iot-2/evt/accel/fmt/json broker: ssl://ORG_ID.messaging.internetofthings.ibmcloud.com with obvious substitution of ORG_ID
Kind regards.