SERVO MOTOR CONTROL USING WIFI
by Santhana_krishnan in Circuits > Arduino
1768 Views, 3 Favorites, 0 Comments
SERVO MOTOR CONTROL USING WIFI
Hi Guys,
In this instructable , let us learn how to control movement of a servo motor through WiFi using Node MCU and Blynk App.
Components Required
- Node MCU
- SG 90 Micro Servo Motor
- Male-Female Jumper Wires
- 5v power supply (9v Battery will be good)
- Bread Board
Connections
- Use a 9v Battery in the Place of 5v mentioned in the circuit diagram.
- Connect the Signal Pin of the servo to the D8 PIN of the Node MCU.
- Connect the GND of the Servo Motor, Battery and the Node MCU together.
Note:
SERVO MOTOR PIN CONFIGURATION
- SIGNAL -- ORANGE pin
- VCC / +ve terminal -- RED pin
- GND / -ve terminal -- BROWN pin
Code
Upload the Following Code in your Node MCU.
Before that, if you don't have NODE MCU and Blynk Libraries.
Follow these steps to add them first.
Step 1:
Click the links separately ->
https://github.com/blynkkk/blynk-library/releases/... For Blynk
https://github.com/esp8266/Arduino/archive/refs/heads/master.zip For Node MCU
zip files will be downloaded.
(For the Node MCU click on Clone or download button and download zip file)
Step 2: open Sketch ->Libraries ->Add zip library -> a new window will popup
Step 3:search for the downloaded libraries and click open. The library will be added.
Downloads
Blynk App
Download Blynk App from Playstore
- Login with Facebook/Gmail
- Click create new project
- Type a project name and Select node MCU board
- Author token will be sent to your Gmail.
- Click on the + icon in the new window and Select Slider button
- Click on the Slider button , Set pin as V3 (Virtual pin)
- Click on the back button and your Blynk App will be ready.
- Switch ON your Mobile Hot spot.
- Keep the Data (Internet) ON in your mobile.
- Click on the Play button on the Project widow
- Now, Click on the Board icon on the top.
- Your Node MCU will be connected to your Phone.
It Works!
After the Node MCU is connected to the Blynk App,
Slide the Slider button and release it to move the servo motor.
Refer to my previous INSTRUCTABLES to know more about Node MCU.
https://www.instructables.com/id/NODE-MCU-BASIC/