ESP8266 (NodeMcu) Raspberry Pi MQTT | ESP8266 Publish/Subscribe

แชร์
ฝัง
  • เผยแพร่เมื่อ 9 พ.ค. 2020
  • This is the 3rd video of How to MQTT series. In this video, we will learn how to subscribe and publish MQTT messages using ESP8266 (NodeMcu). We will use the Raspberry pi as Local mosquitto MQTT broker which we created in the last video.
    We will read the temperature and humidity values from a DHT11 sensor using Nodemcu and publish it on topic "data", raspberry pi will subscribe to that topic and receive that data. So this can also be considered as "Raspberry pi Esp8266 Wireless communication" or "NodeMcu Raspberry pi IoT".
    Get PCBs at 10% off www.nextpcb.com/
    Order your projects at fiverr: www.fiverr.com/users/emmiasim67/
    Read the blog and get code: highvoltages.co/iot-internet-...
    code: github.com/HighVoltages/ESP82...
    Full Playlist: • How to MQTT ?
    Raspberry pi as MQTT broker: • Raspberry Pi as a MQTT...
    ESP8266 WifiManager: • Esp8266 connect WIFI w...
    Watch How to use ESP8266 with MQTT broker on a cloud.
    • ESP8266 Publish/subscr...
    Amazon and Banggood Purchase links:
    *****************
    Buy anything from amazon
    amzn.to/2SGees7
    Buy Arduino UNO R3
    amzn.to/2zmeipW
    Arduino starter kit with book
    amzn.to/3cg8Svt
    Raspberry pi
    amzn.to/2zjiYx2
    Browse Arduino products
    amzn.to/2zgCLx9
    Esp8266 boards
    amzn.to/2WGpOo6
    Arduino many in 1 sensor kit
    amzn.to/3ccMvag
    RFID module
    amzn.to/35Ip06r
    Bangood
    UNOR3 Basic Starter Kits
    www.banggood.com/custlink/3Dm...
    Arduino 37 in 1 sensor modules
    www.banggood.com/custlink/KDK...
    MFRC522 RFID Reader
    www.banggood.com/custlink/KK3...
    Arduino Mega kit (19 % off)
    www.banggood.com/custlink/vmD...
    Basic Electronic kit
    www.banggood.com/custlink/DmG...
    RFID starter kits V2
    www.banggood.com/custlink/3Km...
    Nodemcu ESP8266
    www.banggood.com/custlink/3GG...
    DISCLAIMER: This video and description contain affiliate links, which means that if you click on one of the product links, I will receive a small commission. This helps support the channel and allows me to continue to make videos like this. Thank you for your support!
    ****************
    For More Projects and Tutorials visit our Website:
    www.highvoltages.co
    Follow us on Facebook
    / highvoltagestech
    For business enquires and sponsorships, email me
    highvoltages670@gmail.com
    For Arduino, Raspberry Pi, IoT, and programming projects check my Fiverr profile,
    www.fiverr.com/emmiasim67
    Video Tags:
    ESP8266
    Raspberry pi
    MQTT
    How to MQTT
    How to esp8266 MQTT
    Nodemcu
    esp8266 publishing dht22 readings with mqtt to raspberry pi
    esp8266 mqtt client
    esp8266 mqtt tutorial
    esp8266 mqtt example
    esp8266 dht11 mqtt
    esp8266 dht11 mqtt home assistant
    nodemcu mqtt client
    nodemcu mqtt home assistant
    esp8266 raspberry pi wireless communication
    esp8266 iot tutorial
    esp8266 iot projects
    esp8266 talking to raspberry pi
    internet of things
    #ESP8266 #RaspberryPI #MQTT #HowtoMQTT ---------------------------------------------------------------------------
    BUY ELECTRONICS COMPONENTS FROM INDIA'S BEST DIY STORE
    DIY Usthad Official store diyusthad.store/hv
    --------------------------------------------------------------------------- Hire me on fiverr: www.fiverr.com/emmiasim67 Hire me on Fiverr: www.fiverr.com/s/z2dj0R
    ~-~~-~~~-~~-~
    Please watch: "How to Set Up Wokwi for IoT Simulation in VS Code with PlatformIO"
    • Simulating IoT project...
    ~-~~-~~~-~~-~
  • วิทยาศาสตร์และเทคโนโลยี

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

  • @HighVoltages
    @HighVoltages  3 ปีที่แล้ว

    Watch How to use ESP8266 with MQTT broker on a cloud.
    th-cam.com/video/eQvlHKTlYCE/w-d-xo.html

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

    You already know youre getting the best when the indish accent starts.

  • @ZersoLP
    @ZersoLP 3 ปีที่แล้ว +4

    Some comments say the music is distracting but I think its fine. Instead you should get a better microphone to hear your voice clearer over the music. Great video!

  • @tavreensalman9212
    @tavreensalman9212 4 ปีที่แล้ว +2

    Well done 👍👍👍

  • @DJosh-cs5vx
    @DJosh-cs5vx 2 ปีที่แล้ว +1

    Thanks

  • @JKFCV
    @JKFCV 3 ปีที่แล้ว

    What is the fastest speed of communication? That is how many values per second can be transmitted?

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

    taaaannkkkks ttooo muuuuch bbrroooo

  • @chrisw1462
    @chrisw1462 4 ปีที่แล้ว +6

    You have a very strong accent, to an American, and the background music is just a little too loud. Together it makes listening very hard.

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

      Yes i realised that too. I will improve in my upcoming videos.

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

    What do need to do, if the Raspberry pi and the esp32 arr not on the same wifi? In other words, how subscribe Mqtt Messages over internet? Thank you for the video!

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

      I will make this video in the coming days :)

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

    I’m using DS18b20 sensor on D2 (only pin that seems to work) & 128X32 i2c OLED to display Current temp on D1&D2. Can you assist with code? I can get each to work independently but not together. Great videos!

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

      Sure, the problem you have is the sensor only works on D2 and because of that you cannot use multiple sensors ?

    • @bradlevan3121
      @bradlevan3121 3 ปีที่แล้ว +2

      High Voltages DS18b20 only works (shows correct temp) on D2 yes, if I put it on any other GPIO it says it’s -120degreesF. I guess the problem is I cannot add OLED to display current temp while seeing temp reading on MQTT from DS18b20

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

      @@bradlevan3121 please email me the code so i can comment.

  • @Joshrp59
    @Joshrp59 4 ปีที่แล้ว +2

    Hi, is there a way to publish to MQTT with retained flag active from this MCU?

  • @mommypotatottv
    @mommypotatottv 3 ปีที่แล้ว +2

    is there a tuto of how to link the node mcu or the gateway with cloud

    • @HighVoltages
      @HighVoltages  3 ปีที่แล้ว

      Here it is . th-cam.com/video/eQvlHKTlYCE/w-d-xo.html

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

    Sir,
    How to send one digital input and receive one digital output? Say, we have two esp8266 through adafruit broker. One esp digital input will make another esp digital output high and vice versa. Please help me out.

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

      you can read input from one esp8266 and publish on a topic lets say "input" and the other esp will subscribe to same topic and then whenever the other esp will recieve any data, write a code to change the output.

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

      @@HighVoltages Sir,
      Please help with the code.

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

    so esp8266 don't have to connect to WIFI?

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

      you can connect both esp8266 and pi to the same WiFi or you can use Raspberry pi as an access point and esp8266 can connect to it, in both cases they are on same network but it can work without internet.

  • @ezclap0379
    @ezclap0379 3 ปีที่แล้ว

    Allen Pan has 100 percent been here

  • @wajdibrahem7617
    @wajdibrahem7617 3 ปีที่แล้ว

    the portal config won't open ! some one help me plz !

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

    Can we connect our local pi network to firebase to publish data?

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

      Yes, we can. In the case of this tutorial, sensors are connected to a local broker i.e. Raspberry pi and raspberry pi can publish that data on firebase.

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

      @@HighVoltages thank you.. Can u plz make a video on that as well!

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

      @@hayafatime8998 Sure i will in upcoming days.

  • @dsdridi5362
    @dsdridi5362 3 ปีที่แล้ว

    hi , ican u help me ?
    my esp8266 dont reconnect to mqtt broker ( on node red raspberry pi ) after when the pi reboot .

    • @HighVoltages
      @HighVoltages  3 ปีที่แล้ว

      Are you using reconnect function in your loop body ?

  • @moshebensal7109
    @moshebensal7109 4 ปีที่แล้ว +2

    Very interesting.
    It's not clear to me, why we need background music?
    This is very disturbing to me, and I'm sure many more people,
    Too bad.

    • @HighVoltages
      @HighVoltages  4 ปีที่แล้ว

      Thank you for your feedback and i believe that music added with learning canhelp you learn better and i may be wrong. But if my audience finds it annoying, i will make videos wothout music. Thanks :)

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

      Yes, just a little too loud, too.

    • @HighVoltages
      @HighVoltages  4 ปีที่แล้ว

      @@chrisw1462 i will improve in the next videos, thank you for the feedback :)

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

    Raspberry pi send data to nodemcu via local or globall

    • @HighVoltages
      @HighVoltages  3 ปีที่แล้ว

      Locally, but same code can be used for global transmission using any external mqtt cloud.

  • @tejaranganath9517
    @tejaranganath9517 3 ปีที่แล้ว

    Arduino: 1.8.13 (Windows Store 1.8.42.0) (Windows 10), Board: "Generic ESP8266 Module, 80 MHz, Flash, Legacy (new can return nullptr), All SSL ciphers (most compatible), dtr (aka nodemcu), 26 MHz, 40MHz, DOUT (compatible), 1MB (FS:64KB OTA:~470KB), 2, nonos-sdk 2.2.1+100 (190703), v2 Lower Memory, Disabled, None, Only Sketch, 115200"
    Multiple libraries were found for "ESP8266WiFi.h"
    Used: C:\Users\Puligilla\Documents\Arduino\libraries\ESP8266WiFi
    Not used: C:\Users\Puligilla\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.7.4\libraries\ESP8266WiFi
    In file included from C:\Users\Puligilla\Desktop\sketch_apr07a\sketch_apr07a.ino:1:0:
    C:\Users\Puligilla\Documents\Arduino\libraries\ESP8266WiFi\src/ESP8266WiFi.h:28:28: fatal error: wl_definitions.h: No such file or directory
    #include
    ^
    compilation terminated.
    exit status 1
    Error compiling for board Generic ESP8266 Module.
    This report would have more information with
    "Show verbose output during compilation"
    option enabled in File -> Preferences.
    i am getting these errors please help me sir

  • @ennaiarindhal3141
    @ennaiarindhal3141 3 ปีที่แล้ว

    Bro can read flow sensor Data using esp8266 raspberry pi

    • @HighVoltages
      @HighVoltages  3 ปีที่แล้ว

      Hello, Sorry your question is unclear but as far as i understand yes you can read flow sensor data using ESP8266.

    • @ennaiarindhal3141
      @ennaiarindhal3141 3 ปีที่แล้ว

      Ok how can i do that?

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

    please please stop the music!!!

    • @HighVoltages
      @HighVoltages  3 ปีที่แล้ว

      I will take care of it next time, sorry for this time :)

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

    background music is too laud and pointless we cannot even hear you