[Solved] Pushing multiple values in a single node in Firebase from nodeMCU.
Since I'm new to nodeMCU and Firebase, I'm having a problem to push multiple values in a single node (randomly created) in Firebase from my nodeMCU-ESP8266. I can successfully push a single value whether it's String or Integer.
To be clear... I'm willing to store temperature and humidity values to a new node that's randomly created each time as the values are available. But, the problem is I can't push more than one value in that single node!
It'll be really helpful if you guys can help me out...
The image is the result when I store the values through an android app. But, I can't do the same with the nodeMCU!
kowshik1729 last edited by kowshik1729
@SalmanFK Thanks for posting the query. I would like to know what exactly you are referring to when you say "node".
According to what I understood you are not able to push more than one value at a time into the firebase. Am I right? is that your doubt is? Just to add on, I want to let you know that ESP8266 cannot send characters or strings to the cloud directly. You need to declare a C string and initialize a pointer to run over the length of string, then upload each character to the cloud. This is what basically I did when I faced the error.
salmanfaris last edited by salmanfaris
Hi @SalmanFK ,
You can Serialize the data as a JSON or CSV string format and publish that as a single string, so you get the data in a single node, you also DeSerialize the string simply in the application end.
@salmanfaris Actually, I can't connect my NodeMCU device with the localhost server. I can establish a connection using the test.mosquitto.org server.
This is my required case: YouTube link
@sivanath From your last message looks like the MQTT broker already running on your computer. Could you please try to do a test with nodeRED and see it's working or not.
@swalahamani I may not be able to come tomorrow. I think we could set up a call. How can I contact you personally?
Please bring your device if you're coming for the upcoming MakerChat 0x13 tomorrow (IST). Either I and @salmanfaris or both of us will be there.
Or else we can set up a call sometime this weekend or the next week and sort it out.
Let me know.