include <ESP8266WiFi.h>
#include <BlynkSimpleEsp8266.h>
#include <Servo.h>
#define BLYNK_PRINT Serial
Servo servo;
//fill the "xxxxx"below with code you get from blynk app it will send you an email
char auth[] = "xxxxx";
//fill the "xxxxx"below with your WiFi id
char ssid[] = "xxxxx";
//fill the "xxxxx"below with your WiFi password
char pswd[] = "xxxxx";
void setup() {
Serial.begin(9600);
Blynk.begin(auth,ssid,pswd);
servo.attach(2);
}
void loop() {
Blynk.run();
}
BLYNK_WRITE(V1) {
servo.write(param.asInt());
}
Comments
Please log in or sign up to comment.