[Solved] Pushing multiple values in a single node in Firebase from nodeMCU.

  • Hi everyone!
    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!


  • @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.

  • 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.

Log in to reply

Recent Posts

  • What are objects?

    Jeff Goodell: Would you explain, in simple terms, exactly what object-oriented software is?

    Steve Jobs: Objects are like people. They’re living, breathing things that have knowledge inside them about how to do things and have memory inside them so they can remember things. And rather than interacting with them at a very low level, you interact with them at a very high level of abstraction, like we’re doing right here.

    Here’s an example: If I’m your laundry object, you can give me your dirty clothes and send me a message that says, “Can you get my clothes laundered, please.” I happen to know where the best laundry place in San Francisco is. And I speak English, and I have dollars in my pockets. So I go out and hail a taxicab and tell the driver to take me to this place in San Francisco. I go get your clothes laundered, I jump back in the cab, I get back here. I give you your clean clothes and say, “Here are your clean clothes.”

    You have no idea how I did that. You have no knowledge of the laundry place. Maybe you speak French, and you can’t even hail a taxi. You can’t pay for one, you don’t have dollars in your pocket. Yet I knew how to do all of that. And you didn’t have to know any of it. All that complexity was hidden inside of me, and we were able to interact at a very high level of abstraction. That’s what objects are. They encapsulate complexity, and the interfaces to that complexity are high level.

    read more
  • This webinar is focussing on learning Git VCS, a distributed version control system for tracking changes during practical software development.

    We will be exploring the usage of various git commands, plugins/extensions and branching-models based on real-world contexts.

    The session is targetting absolute beginners with minimum or no experience with git, But a mindset to optimize and improve work efficiency and productivity by learning and exploring new tool-chains and strategies is a must!

    Join MakerChat.

    Maker: Muhammad Swalah
    Place: Zoom
    Date: 16th Aug 2020
    Time: 8:00 PM

    Registration: bit.ly/makerchat8

    Join MakerGram: bit.ly/join-mg


    read more
  • 3D PRINTING@300x.png

    read more
  • MakerGram is Live Now!

    MakerChat 0x07: How to Learn Machine Learning (for Humans) by @GKS

    Watch LIVE @ https://www.facebook.com/makergram/videos/736833737153967/

    #MakerGramLearnings #MGLive #AI #ArtificialIntelligence #MachineLearning #Humans #MachineIntellegence #MakerChat

    read more
  • @anuradhasingh426 Please check your mailbox.

    read more