Control Servo Motor Using ATOM Matrix ESP32 & Visuino

by RonFrtek in Circuits > Arduino

147 Views, 1 Favorites, 0 Comments

Control Servo Motor Using ATOM Matrix ESP32 & Visuino

Control Servo Motor Using ATOM Matrix ESP32

In this tutorial we will use Servo Motor and ATOM Matrix ESP32, and Visuino to control servo motor degree position using only a few components thus making this project Super Simple.

Watch the video.

What You Will Need

2022-07-27_11-05-19.jpg
micro-servo-sg90-3-600x600.png
VisuinoAdvrtisemenESPNowESP32C3-1.jpg
F5OFEUQJJ4ZYFKY.LARGE.jpg
  1. ATOM Matrix ESP32
  2. Jumper wires
  3. Servo motor
  4. Visuino program: Download Visuino


The Circuit

2023-09-06_19-49-17.jpg
  • Connect Servo pin [VCC] to Atom Matrix pin [5V]
  • Connect Servo pin [GND] to Atom Matrix pin [GND]
  • Connect Servo pin [Signal] to Atom Matrix pin [G25]


Start Visuino, and Select the Atom Matrix Board Type

select-board-uno.jpg
2022-07-27_11-14-14.jpg

Start Visuino as shown in the first picture Click on the "Tools" button on the Arduino component (Picture 1) in Visuino When the dialog appears, select "Atom Matrix" as shown on Picture 2

In Visuino Add Components

2023-09-06_20-19-04.jpg
2023-09-06_20-20-48.jpg
2023-09-06_20-21-47.jpg
  • Add "Counter" component
  • Add "Integer To Analog" component
  • Add "Servo" component

In Visuino Set Components

2023-09-06_20-24-48.jpg
2023-09-06_20-25-08.jpg
  • Select "Counter1" and in the properties window set "Max">"Value" to 10
  • Select "IntegerToAnalog1" and in the properties window set "Scale" to 0.1

In Visuino Connect Components

2023-09-06_20-32-21.jpg
  • Connect "M5 Stack ATOM Matrix" > "Button" pin [Out] to "Counter1" pin [In]
  • Connect "Counter1" pin [Out] to "IntegerToAnalog1" pin [In]
  • Connect "IntegerToAnalog1" pin [Out] to "Servo1" pin [In]
  • Connect "Servo1" pin [Out] to "M5 Stack ATOM Matrix" pin [GPIO 25]


Generate, Compile, and Upload the Arduino Code

F24Q49GL626WFXY.jpg

In Visuino, at the bottom click on the "Build" Tab, make sure the correct port is selected, then click on the "Compile/Build and Upload" button.

Play

If you power the ATOM Matrix module and press the Atom button the servo motor will start to rotate.

Congratulations! You have completed your project with Visuino. Also attached is the Visuino project, that I created for this tutorial, you can download it and open it in Visuino: https://www.visuino.eu

Downloads