Home Automation Using NodeMCU ESP32 and Firebase | MIT App Inventor

แชร์
ฝัง
  • เผยแพร่เมื่อ 31 พ.ค. 2024
  • Let's make a Home Automation Project to control the multiple rooms of your home with a Firebase Real-time Database, NodeMCU and EPS32. This is an IOT home automation project. I have also created an Android App using MIT App Inventor. You can use the App to control total 4 rooms of you home. You can also add more rooms in the Android App by modifying the project aia file. You can also check the real time status update by using the Android App. I have also added the manual switches to control the appliances of different rooms. If you reset the micro controller, or If there is a power failure. And when the micro controller power up again, the latest status of the relays will be updated automatically.
    This project consumes very little amount of Firebase data. So the free quota of Firebase data usage will never exceeded. So you don't have to worry about hitting the quota limit, of Firebase Database.
    you can use both ESP32 and ESP8266 for this project and you can upload the same code on both devices without making any change in the code.
    00:00 - Intro
    02:02 - Create Firebase Project
    03:27 - Setting Up Authentication Method For Firebase Project
    04:11 - Get Firebase Credentials
    04:56 - Download Code and Resource Files
    05:18 - Create Android App Using MIT App Inventor
    06:22 - Enter Firebase Credentials in the App
    07:45 - Build and Test APK File
    08:54 - Wiring Diagram NodeMCU
    09:50 - Wiring Diagram ESP32
    10:18 - Code NodeMCU
    11:24 - Enter Firebase Credentials in the Code
    12:32 - Testing NodeMCU
    13:09 - Code ESP32
    14:09 - a Little Demo
    14:19 - End Screen
    Parts Used in This Project:
    1. NodeMCU ESP8266 - amzn.to/3Zzm1bJ
    2. ESP32 Development Board - amzn.to/3YCq2dS
    3. 4 Channel Relay Module (2x) - amzn.to/3YJXa3w
    4. AC Bulbs (4x)
    5. Bulb Holder (4x)
    6. 5v Power Adapter
    7. Push Buttons (8x)
    8. Breadboard
    9. Jumper Wires (Male/Female)
    Software Used in This Project:
    1. Arduino IDE (Version 1.8.20)
    2. ESP8266 Board Package (Version 3.0.2)
    3. ESP32 Board Package (Version 1.0.6)
    4. Firebase ESP Client Library (Version 3.1.5)
    --------------------------------------------------------------------------------------------------------------------
    Useful Video Links
    --------------------------------------------------------------------------------------------------------------------
    SIM800L Home Automation Project Using Arduino and Push Buttons
    • SIM800L Home Automatio...
    Advanced RFID Based Attendance System Using NodeMcu Version 2 | Google Sheets
    • Advanced RFID Based At...
    --------------------------------------------------------------------------------------------------------------------
    Social Media Links
    --------------------------------------------------------------------------------------------------------------------
    GitHub:
    github.com/ahmadlogs/
    TH-cam:
    th-cam.com/users/ahmadlogs?sub...
    --------------------------------------------------------------------------------------------------------------------
    Download Code
    --------------------------------------------------------------------------------------------------------------------
    github.com/ahmadlogs/mit-mult...
    --------------------------------------------------------------------------------------------------------------------
    Disclaimer
    --------------------------------------------------------------------------------------------------------------------
    Disclaimer: All videos are for educational purposes and use them wisely. Any video may have a slight mistake, please take decisions based on your research. This video is not forcing anything on you.
    Warning: I will use High Voltages which if incorrectly or improperly used could result in serious injuries or death. So be careful of what you are doing because I will take no responsibility for any of your actions.
    #NodeMCU #HomeAutomation #ESP32

ความคิดเห็น • 71

  • @abbasthegreat5
    @abbasthegreat5 ปีที่แล้ว

    Thank you sir,
    You are superman.

  • @rampage_xdit
    @rampage_xdit 2 ปีที่แล้ว

    I am very glad to hearing good news of you .good job

  • @lotfibouchiba1537
    @lotfibouchiba1537 ปีที่แล้ว

    MERCI BOSS

  • @amirtelecom6898
    @amirtelecom6898 2 ปีที่แล้ว

    Very nice project
    Thank you sir

    • @AhmadLogs
      @AhmadLogs  2 ปีที่แล้ว

      So nice of you

  • @messamali8055
    @messamali8055 2 ปีที่แล้ว

    sorry came here searching for jazzcash sandbox issue.
    when i click buy , the screen goes blank for 2,3 seconds and return back to main activity.
    in run menu i found this error
    -> W/ContentCatcher: Failed to notify a WebView
    can you help?

  • @AAdnaanmtl
    @AAdnaanmtl 2 ปีที่แล้ว

    Excellent work sir. Long awaited eeprom is included finally thanks. Can you please make one eeprom option video in your 4 in 1 gsm project also. Are you also planning to add dimmer in your upcoming home automation videos

    • @AhmadLogs
      @AhmadLogs  2 ปีที่แล้ว +1

      As soon as possible

  • @saadelm2955
    @saadelm2955 2 ปีที่แล้ว

    Excellent..... Bravo

  • @edgarblanco7306
    @edgarblanco7306 หลายเดือนก่อน

    can i ask for assistance sir. i just made your tutorial. everything is ok except that i cant open your app in my cellphone which says there is a bug in your app. how can i fix this. thanks.

  • @althafdianraffasya6986
    @althafdianraffasya6986 3 หลายเดือนก่อน

    Excellent sir & Nice project..
    how to connect more than one device mobile ? i mean like a 10 or more device and each device know what happens on other device ?

  • @navaneeth.m.s
    @navaneeth.m.s ปีที่แล้ว

    very nice project😄

    • @AhmadLogs
      @AhmadLogs  ปีที่แล้ว

      Many many thanks

  • @ameenenterprise5869
    @ameenenterprise5869 2 ปีที่แล้ว

    ماشاء اللہ

    • @AhmadLogs
      @AhmadLogs  2 ปีที่แล้ว

      جزاک اللہ

  • @bilalrajput9773
    @bilalrajput9773 5 หลายเดือนก่อน

    how can i connect all room on one esp

  • @yesusdajjal4437
    @yesusdajjal4437 ปีที่แล้ว

    fail when build android apk file , any advice sir?

  • @Luismaia00
    @Luismaia00 2 ปีที่แล้ว

    Very good vídeo

  • @chakhna
    @chakhna 2 ปีที่แล้ว

    esp32 wifi led light not glowing.

  • @KrishanKumarVlog
    @KrishanKumarVlog ปีที่แล้ว +1

    I want to tell you that I used this code in ESP8266 and after all setup I found that at some random interval of time relays are not responding with respect to MIT app button , I need to reset the ESP8266 board every time to make board and relay in normal working condition. I face this problem after 4 hour, after 7 hour , that microcontroller need to reset
    please help me in this situation 🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏🙏

    • @KrishanKumarVlog
      @KrishanKumarVlog ปีที่แล้ว

      I add Wifi manager library to your existing code to change SSID and password from outside

  • @amirqane5270
    @amirqane5270 2 ปีที่แล้ว

    hi the last version of software is 1.8.19,and i cant find esp32 in board manager lab,why?

    • @AhmadLogs
      @AhmadLogs  2 ปีที่แล้ว

      first put the eps32 link in the preferences from the File menu. then you will able to see the esp32 board in the board manager

    • @amirqane5270
      @amirqane5270 2 ปีที่แล้ว

      @@AhmadLogs thank a lot

  • @Leo-vy6fz
    @Leo-vy6fz 2 ปีที่แล้ว +1

    I am really very lucky to find to find this amazing channel keep it up I want to the same project using arduino maga and esp01 how much different will the code change

    • @AhmadLogs
      @AhmadLogs  2 ปีที่แล้ว

      Thanks you very much. I think will work without changing in the code. just give it a try. if you feed issue then let me know

  • @Luismaia00
    @Luismaia00 2 ปีที่แล้ว +1

    After installing app on andoid the app does not load,any ideas for what is wrong?

    • @AhmadLogs
      @AhmadLogs  2 ปีที่แล้ว

      you can use MIT AI2 Companion to test your project

  • @devi8049
    @devi8049 ปีที่แล้ว

    Instead of push button I used a normal switch. If I turn on the switch the relay will continuously on and off, How to solve it sir?

    • @AhmadLogs
      @AhmadLogs  ปีที่แล้ว

      for normal you need aceButton library

  • @do335pfeil
    @do335pfeil 2 ปีที่แล้ว

    I created the Android App following exactly the steps, installing in three differents phones and after 0.5 seconds the app leave and it doesn't work. I tried also with the original .aia file and again it didn't work. Can you please check the .aia file of github if it's the right one?

    • @AhmadLogs
      @AhmadLogs  2 ปีที่แล้ว

      install the AI Companion App on your android phone. Then upload the project on your android phone by scanning the QR code using AI Companion App. If the app have an issue then you will see the error message on the screen.

  • @RK-ky5vh
    @RK-ky5vh ปีที่แล้ว

    if i use normal switch instead of push button it not work (automatically on off) how to resolved sir

    • @AhmadLogs
      @AhmadLogs  ปีที่แล้ว

      you need ace button library for normal button

  • @ravirtech1260
    @ravirtech1260 2 ปีที่แล้ว

    Nice project please add this project RF remote opretion

  • @MAAZAHMAD-dh1ds
    @MAAZAHMAD-dh1ds 24 วันที่ผ่านมา

    sir aap is not opening

  • @saifbbsaif5681
    @saifbbsaif5681 ปีที่แล้ว

    Hello Ahmed, how are you?
    I am Saif from UAE
    I liked the program and your effort is very impressive
    My question is if I want to change the switched switch to a normal switch that is open and closed. Is it possible and how do I do the program on ESP8266? Please help me, my dear brother.

    • @AhmadLogs
      @AhmadLogs  ปีที่แล้ว

      yes you can use normal switches. you can use AceButton library to handle normal switches

  • @amirqane5270
    @amirqane5270 2 ปีที่แล้ว +1

    we can"t paste tex in the box on MIT site ,why?

    • @AhmadLogs
      @AhmadLogs  2 ปีที่แล้ว

      which box you are talking about?

    • @amirqane5270
      @amirqane5270 2 ปีที่แล้ว

      @@AhmadLogs in MIT site when i want to past information about API and ULR i cant to

    • @amirqane5270
      @amirqane5270 2 ปีที่แล้ว

      @@AhmadLogs may i have your email address?

    • @AhmadLogs
      @AhmadLogs  2 ปีที่แล้ว

      @@amirqane5270 it is strange

  • @RK-ky5vh
    @RK-ky5vh ปีที่แล้ว

    my question is if my internet is down then how to control relay ?

    • @AhmadLogs
      @AhmadLogs  ปีที่แล้ว

      you can use push buttons

  • @switage
    @switage ปีที่แล้ว

    Sir plz make this video with home switches instead of push buttons.

  • @balbirsinghheer1370
    @balbirsinghheer1370 2 ปีที่แล้ว

    Sir you are using firebase to upload data to mit can fire base used to diplay data to our own website

    • @AhmadLogs
      @AhmadLogs  2 ปีที่แล้ว

      yes, you can do that

    • @balbirsinghheer1370
      @balbirsinghheer1370 2 ปีที่แล้ว

      Sir i will be very thankful to you if you can explain it

    • @AhmadLogs
      @AhmadLogs  2 ปีที่แล้ว

      @@balbirsinghheer1370 you might use php or python to build website. there is firebase library both for python and php you might that. search on google "PHP firebase sdk" or "Python firebase sdk".

    • @balbirsinghheer1370
      @balbirsinghheer1370 2 ปีที่แล้ว

      Thank you sir ☺️

  • @amirqane5270
    @amirqane5270 2 ปีที่แล้ว

    room1/L1
    Set String... token is not ready
    room1/L1
    Set String... token is not ready
    room1/L1
    Set String... token is not ready
    room1/L1
    Set String... token is not ready
    room1/L1
    Set String... token is not ready
    why dose this happen?

    • @AhmadLogs
      @AhmadLogs  2 ปีที่แล้ว

      I think there is some issue with Firebase connectivity. just tell me what activity you perform, that cause this error message?

    • @amirqane5270
      @amirqane5270 2 ปีที่แล้ว

      @@AhmadLogs please give me your email add

  • @dhanush2060
    @dhanush2060 ปีที่แล้ว

    Can I use this code to ESP01

    • @AhmadLogs
      @AhmadLogs  ปีที่แล้ว

      you might try.

  • @kodavatrack5638
    @kodavatrack5638 ปีที่แล้ว

    Where do we find the code

    • @AhmadLogs
      @AhmadLogs  ปีที่แล้ว

      from the video description

  • @alimousad9638
    @alimousad9638 ปีที่แล้ว

    very good my bro need link face book u

  • @yogeshitaliya473
    @yogeshitaliya473 2 ปีที่แล้ว

    I have some problems after all set up
    I have sand massage in your fb page please check it's

  • @amirqane5270
    @amirqane5270 2 ปีที่แล้ว

    ------------------------------------------------
    ESP8266 Pins
    ------------------------------------------------
    #define Relay1 16 //D0
    #define Relay2 5 //D1
    #define Relay3 4 //D2
    #define Relay4 0 //D3
    #define Switch1 12 //D5
    #define Switch2 14 //D6
    #define Switch3 9 //SD2
    #define Switch4 10 //SD3
    in line 5 switch 12//D5 is wrong D5 is no 14 and at the same in line 6 switch 14//D6 must be instead by 12

    • @AhmadLogs
      @AhmadLogs  2 ปีที่แล้ว +1

      Thanks you so much bro. I have just updated the code.

    • @amirqane5270
      @amirqane5270 2 ปีที่แล้ว

      @@AhmadLogs you are welcone

  • @mcase4171
    @mcase4171 2 ปีที่แล้ว

    😥 PЯӨMӨƧM