MicroPython - MQTT tutorial on ESP32

preview_player
Показать описание
What if you want to remote control a drone, or create a smart home lighting system, or collect sensor data from many devices? Enter MQTT: a robust and flexible IoT protocol that lets us do all that and more!

0:00 Intro
0:56 MQTT Architecture
3:18 Installing mosquitto
4:58 Configuring mosquitto
7:11 Publish & subscribe
9:16 ESP32 hardware setup
10:04 Select ESP32 in Thonny
11:15 Connect ESP32 to WiFi
11:51 Connect to MQTT broker
15:33 Publish from ESP32
20:27 Button publish demo
21:34 Subscribe from ESP32
26:39 Subscription callback demo
28:03 Set up second ESP32
29:11 Final project demo
30:10 MQTT benefits
30:56 Join for more MicroPython!
Рекомендации по теме
Комментарии
Автор

really helped me to create an LED smart light for my room! Great going Bhavesh, more more more

unrealcompanymusic
Автор

Hi Bhavesh, thanks a lo for your tutorials and in particular for responding to my request with detailed answers. I followed your advice to use a usb serial adapter for the uart port and finally managed to get the data flowing over the serial port. Thanks a lot

premprasad
Автор

You are so good ; I really hope you will have 10 million subscribers soon

premprasad
Автор

Hello from Australia, i have a question. I am working on micropython code for an esp32, it has 4x ds18b20 temp probes, each publishing temps to my mqtt broker on 4x topics. I have a node red handling thermostat duties, publishing either a 1 or zero to the mqtt broker on topics relay1, relay2, relay3 and relay4. The question is, can the esp32 subscribe to all 4 topics and then control 4 gpio outputs for my relay board?

benedwards
Автор

Congratulations for your video !!! This is great quality and I have learned a lot about using mqtt with micropython. I have a micropython project with neopixel matrix connected to esp8266 (connected to wifi) and I was wondering if the same protocol could be used to send json files or arrays ? Many thanks and looking forward to your next video. best.

laurentstrodiot
Автор

Great video man keep it up! Question for you can you run the broker off a 3rd esp32 as well?

case
Автор

How to send data from micropython on esp32 to python running on pc using pyserial module ? And vice versa ?

Can you do this quickly plesae ? I tried . It works on arduino, on microbit but not when esp32 is running micropython !!

premprasad
Автор

I tried it on Raspberry Pi PICO temperature measurement, it works. But if broker goes offline then PICO does not connect back to the broker. What could be the solution?

mansurbhamani
Автор

Nice work 👏
I was trying to use AWS broker online but have been having issues with building the connection, especially the certificate and private key. It would very helpful if I could connect to an online IOT cloud.

safwanshaib
Автор

great but i want to redirect remotely.
for example: I want to know the temperature in my house from my workplace. how can do this? your current local connection

omerberkaykaynar
Автор

lol 10 million subscribers! ....in binary

DJNilu
join shbcf.ru