MakerGram Logo

    MakerGram

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Popular
    • Tags
    • Users
    • Groups
    1. Home
    2. Anudeep
    A
    • Profile
    • Following 0
    • Followers 0
    • Topics 3
    • Posts 9
    • Best 1
    • Controversial 0
    • Groups 0

    Anudeep

    @Anudeep

    2
    Reputation
    74
    Profile views
    9
    Posts
    0
    Followers
    0
    Following
    Joined Last Online

    Anudeep Unfollow Follow

    Best posts made by Anudeep

    • RE: Uploading data to firebase using NodeMCU

      @salmanfaris Thanks for the support!!
      I finally resolved the error. I have taken FIREBASE_AUTH as apiKey instead of Database secrets.

      posted in Arduino
      A
      Anudeep

    Latest posts made by Anudeep

    • RE: Uploading data to firebase using NodeMCU

      Hello @Palani, In the Firebase, there are two types of storage,

      1. Cloud Firestore (Very recent one & NoSQL database)
      2. Realtime Database (To which we upload the data using NodeMCU)

      In the Arduino Code, you can see that there is a variable named FIREBASE_AUTH.

      This variable should be assigned to the Database secret. This you can find in Project Settings -> Service accounts -> Database Secrets.

      My mistake is, i have mistakenly assigned thay to Web API key. This is found at Project Settings -> General.

      The error can also occur when u don't initialise a proper realtime database in Firebase. (This is not my case).

      posted in Arduino
      A
      Anudeep
    • Understanding the raw output of MPU-6050

      Hello all,

      I have a small doubt regarding the raw values given by MPU 6050.
      I am getting 6 raw values from the MPU 6050 sensor!
      I have given a default sensitivity of +/- 2g.
      What exactly each value mean? Is it like, voltage values across each axis or capacitance values or the acceleration values itself.
      But for me they doesn't mean anything. I am getting some values above 1000, some of them in negative and some doesn't go beyond +/- 250.
      So, can you explain me in detail what does those value mean in physical parameters and their units?

      Thank you!!

      posted in Arduino
      A
      Anudeep
    • RE: Error uploading code to Arduino Nano

      @salmanfaris Yeah, I have checked the cable because I was able to upload to another Arduino Nano. But, I was not able to upload this new Arduino Nano.
      I have tried with both bootloader's new and Old... It's not working with both!!
      So, any help regarding this?

      posted in Arduino
      A
      Anudeep
    • Error uploading code to Arduino Nano

      Please refer to my code and error log and tell the error!!
      I have a new version of Arduino Nano and I'm trying to upload code to it. But it's showing the following error. Can u help me rectify it!!

      Code:

      String str = "";
      void setup() {
        Serial.begin(9600); // Starts the serial communication
      }
      
      void loop() {
        if(Serial.available() > 0){
          str = Serial.readString();
          Serial.println(str);
          }
      }
      

      Error Log:

      Build options changed, rebuilding all
      Sketch uses 3276 bytes (10%) of program storage space. Maximum is 30720 bytes.
      Global variables use 204 bytes (9%) of dynamic memory, leaving 1844 bytes for local variables. Maximum is 2048 bytes.
      avrdude: stk500_recv(): programmer is not responding
      avrdude: stk500_cmd(): programmer is out of sync
      avr_read(): error reading address 0x0000
          read operation not supported for memory "flash"
      avrdude: failed to read all of flash memory, rc=-2
      avrdude: stk500_disable(): protocol error, expect=0x14, resp=0x00
      avrdude: stk500_disable(): protocol error, expect=0x14, resp=0x00
      

      Image of Error:
      e93e34ab-e0dc-4992-b6d1-c463fdb65c0f-image.png

      posted in Arduino
      A
      Anudeep
    • RE: Uploading data to firebase using NodeMCU

      @salmanfaris Thanks for the support!!
      I finally resolved the error. I have taken FIREBASE_AUTH as apiKey instead of Database secrets.

      posted in Arduino
      A
      Anudeep
    • RE: Uploading data to firebase using NodeMCU

      @salmanfaris Nothing, No errors!!
      Do I need to change anything in Firebase settings or something?

      posted in Arduino
      A
      Anudeep
    • RE: Uploading data to firebase using NodeMCU

      Thanks, @rafitc99. But even this didn't solve my problem!!
      I have changed the code in the below format...

      #include <ESP8266WiFi.h>
      #include <FirebaseArduino.h>       
      
      // Set these to run example.
      #define FIREBASE_HOST "syndinnovate-1.firebaseio.com"
      #define FIREBASE_AUTH "AIzaS********************7hKQe4uPbfUKHc"
      #define WIFI_SSID "SSID"
      #define WIFI_PASSWORD "PASS"
      
      void setup() {
        Serial.begin(9600);
        delay(1000);                
        WiFi.begin(WIFI_SSID, WIFI_PASSWORD);                                     //try to connect with wifi
        Serial.print("Connecting to ");
        Serial.print(WIFI_SSID);
        while (WiFi.status() != WL_CONNECTED) {
          Serial.print(".");
          delay(500);
        }
        Serial.println();
        Serial.print("Connected to ");
        Serial.println(WIFI_SSID);
        Serial.print("IP Address is : ");
        Serial.println(WiFi.localIP());                                            //print local IP address
        Firebase.begin(FIREBASE_HOST, FIREBASE_AUTH);                              // connect to firebase                                                               //Start reading dht sensor
      }
      
      void loop() {                                                             //Convert RainSensr data into string
        
        Firebase.pushString("/NEW", "No");   
        delay(1000);//setup path and send readings
        Firebase.pushString("/NEW", "Yes");                                //setup path and send readings
        delay(1000);//setup path and send readings
      }
      
      posted in Arduino
      A
      Anudeep
    • RE: Uploading data to firebase using NodeMCU

      Thanks, @salmanfaris, I have solved this error previously. But for me there is no error, code is getting uploaded smoothly but the data is not getting uploaded to the firebase!
      Do I have to change any settings in the firebase page? for uploading the data!!

      After uploading the code... I have the below log!!

      esptool.py v2.6
      2.6
      esptool.py v2.6
      Serial port COM4
      Connecting....
      Chip is ESP8266EX
      Features: WiFi
      MAC: 84:f3:eb:58:b5:b7
      Uploading stub...
      Running stub...
      Stub running...
      Configuring flash size...
      Auto-detected Flash size: 4MB
      Compressed 366560 bytes to 260548...
      
      Writing at 0x00000000... (6 %)
      Writing at 0x00004000... (12 %)
      Writing at 0x00008000... (18 %)
      Writing at 0x0000c000... (25 %)
      Writing at 0x00010000... (31 %)
      Writing at 0x00014000... (37 %)
      Writing at 0x00018000... (43 %)
      Writing at 0x0001c000... (50 %)
      Writing at 0x00020000... (56 %)
      Writing at 0x00024000... (62 %)
      Writing at 0x00028000... (68 %)
      Writing at 0x0002c000... (75 %)
      Writing at 0x00030000... (81 %)
      Writing at 0x00034000... (87 %)
      Writing at 0x00038000... (93 %)
      Writing at 0x0003c000... (100 %)
      Wrote 366560 bytes (260548 compressed) at 0x00000000 in 23.3 seconds (effective 126.0 kbit/s)...
      Hash of data verified.
      
      Leaving...
      Hard resetting via RTS pin...
      
      posted in Arduino
      A
      Anudeep
    • Uploading data to firebase using NodeMCU

      Hello,
      I am trying to upload data to firebase but wasn't able to do it. I'm not able to understand the error.
      I wanted to update the value of NEW in firebase...
      Please refer to my code and firebase tree to solve the error.!!!

      68f72edb-2241-4e61-923d-1cd79b154718-image.png

      #include <ESP8266WiFi.h>
      #include <FirebaseArduino.h>       
      
      // Set these to run example.
      #define FIREBASE_HOST "syndinnovate-1.firebaseapp.com"
      #define FIREBASE_AUTH "AIzaSyAf**********-v7hKQe4uPbfUKHc"
      #define WIFI_SSID "Anudeep"
      #define WIFI_PASSWORD "Anudeep123"
      
      void setup() {
        Serial.begin(9600);
      
        // connect to wifi.
        WiFi.begin(WIFI_SSID, WIFI_PASSWORD);
        Serial.print("connecting");
        while (WiFi.status() != WL_CONNECTED) {
          Serial.print(".");
          delay(500);
        }
        Serial.println();
        Serial.print("connected: ");
        Serial.println(WiFi.localIP());
        
        Firebase.begin(FIREBASE_HOST, FIREBASE_AUTH);
      }
      
      int n = 0;
      
      void loop() {
        /*
        // set value
        Firebase.setFloat("number", 42.0);
        // handle error
        if (Firebase.failed()) {
            Serial.print("setting /number failed:");
            Serial.println(Firebase.error());  
            return;
        }
        delay(1000);*/
        
        // update value
        Firebase.setFloat("/NEW", 43.0);
        // handle error
        if (Firebase.failed()) {
            Serial.print("setting /number failed:");
            Serial.println(Firebase.error());  
            return;
        }
        delay(1000);
      /*
        // get value 
        Serial.print("number: ");
        Serial.println(Firebase.getFloat("number"));
        delay(1000);
      
        // remove value
        Firebase.remove("number");
        delay(1000);
      
        // set string value
        Firebase.setString("message", "hello world");
        // handle error
        if (Firebase.failed()) {
            Serial.print("setting /message failed:");
            Serial.println(Firebase.error());  
            return;
        }
        delay(1000);
        
        // set bool value
        Firebase.setBool("truth", false);
        // handle error
        if (Firebase.failed()) {
            Serial.print("setting /truth failed:");
            Serial.println(Firebase.error());  
            return;
        }
        delay(1000);*/
      
        // append a new value to /logs
        String name = Firebase.pushInt("/NEW", n++);
        // handle error
        if (Firebase.failed()) {
            Serial.print("pushing /logs failed:");
            Serial.println(Firebase.error());  
            return;
        }
        Serial.print("pushed: /logs/");
        Serial.println(name);
        delay(1000);
      }
      
      posted in Arduino
      A
      Anudeep