Introduction To Blynk
1. Setting Up Blynk App
Install Blink app from play store or ios store
Create your Account
After that choose New project then, enter the project name which you like
Choose Device as NodeMCU and connection type as Wi-Fi
Then click create
After that a authentication code is sent to your registered E-mail ID
2. Creating Buttons
Click on Add button and choose Button
Then click on the button you created and provide name for button
In output session choose Digital PIN and D1 PWM
In MODE swap to SWITCH that's it
You can configure other 3 buttons like this by changing D2, D3, D4 PWM or whatever you want.
Coding To ESP8266
Connect NODE ESP8266 to PC
Open Arduino In top Sketch > Include Library > Manage library
Search For Blynk Then install The latest Version
Go To File > Examples > Blynk > Boards_WiFi > ESP8266_standalone
In the Code Modify --
After that Provide Your Auth Code That you get from registering in Blynk
// You should get Auth Token in the Blynk App.
// Go to the Project Settings (nut icon).
char auth[] = "YourAuthToken";
Eg:
char auth[] = "7816d601drd348876af72848024ec1e0";
Change This also:
// Your WiFi credentials.
// Set password to "" for open networks.
char ssid[] = "YourNetworkName";
char pass[] = "YourPassword";
Provide Your Wi-Fi ssid and password
Eg:
char ssid[] = "My-Wi-Fi";
char pass[] = "HelloWorld123";
Hit The Upload Button. In the case of any error during uploading you can refer This
Connection for LED
connect like this.
Refer my video
Hope You Enjoy!
إرسال تعليق