Xin chào!
Cho mình hỏi chút mạch esp32 khi bị mất mạng hoặc mất điện khi có mạng trở lại thì không tự động kết nối mạng được, mà phải bấm nút reset trên mạch thì mới tự kết nối được, các bác có cách nào giúp em cho nó tự kết nối lại được không. em sử dụng wifi
void loop()
noi
January 22, 2018, 1:00pm
2
Hi @nghoan.pt bạn sử dụng blynk connect or post code của bạn lên mình xem giúp nhé.
1 Like
Cho các mục đích cơ bản nhất, bạn đã đọc phần này trong docs của Blynk chưa? Tôi ko chia sẻ code cụ thể vì tôi chắc bạn sẽ đọc và làm được.
http://docs.blynk.cc/#blynk-firmware-virtual-pins-control-blynk_app_connected
Dù sao, Blynk cũng đã có code theo mình là khá hay nên bạn có thể tham khảo ở đây
/*************************************************************
Blynk is a platform with iOS and Android apps to control
Arduino, Raspberry Pi and the likes over the Internet.
You can easily build graphic interfaces for all your
projects by simply dragging and dropping widgets.
Downloads, docs, tutorials: http://www.blynk.cc
Sketch generator: http://examples.blynk.cc
Blynk community: http://community.blynk.cc
Follow us: http://www.fb.com/blynkapp
http://twitter.com/blynk_app
Blynk library is licensed under MIT license
This example code is in public domain.
*************************************************************
This sketch shows how to access WiFiClient directly in Blynk
1. This gives you full control of the connection process.
2. Shows a sensible way of integrating other connectivity hardware,
that was not supported by Blynk out-of-the-box.
This file has been truncated. show original