MEGA DASJLCPCBBob Alsone
Published © Apache-2.0

High torque servo motor control

High torque servo motors are special, so here is a special tutorial to learn how to use them with Arduino baord.

BeginnerFull instructions provided2 hours25
High torque servo motor control

Things used in this project

Hardware components

Arduino Nano R3
Arduino Nano R3
We used this Arduino in our tutorial to control the servo motor
×1
SG90 Micro-servo motor
SG90 Micro-servo motor
You can use this smal size servo to test your skills, we used another servo which is the Carson CS6 (high torque servo)
×1
Rotary potentiometer (generic)
Rotary potentiometer (generic)
analog input controller to monitor the servo
×1
Breadboard (generic)
Breadboard (generic)
×1
EMax 12g ES08MD high Sensitive servo
Seeed EMax 12g ES08MD high Sensitive servo
×1
Arduino UNO & Genuino UNO
Arduino UNO & Genuino UNO
×1

Software apps and online services

Arduino IDE
Arduino IDE
EasyEDA
JLCPCB EasyEDA
We used EasyEDA to create the wiring diagram for the testing circuit

Story

Read more

Schematics

Circuit diagram

Code

Arduino Knob example from the vservo library

Arduino
/*
 Controlling a servo position using a potentiometer (variable resistor)
 by Michal Rinott <http://people.interaction-ivrea.it/m.rinott>

 modified on 8 Nov 2013
 by Scott Fitzgerald
 http://www.arduino.cc/en/Tutorial/Knob
*/

#include <Servo.h>

Servo myservo;  // create servo object to control a servo

int potpin = 0;  // analog pin used to connect the potentiometer
int val;    // variable to read the value from the analog pin

void setup() {
  myservo.attach(9);  // attaches the servo on pin 9 to the servo object
}

void loop() {
  val = analogRead(potpin);            // reads the value of the potentiometer (value between 0 and 1023)
  val = map(val, 0, 1023, 0, 180);     // scale it to use it with the servo (value between 0 and 180)
  myservo.write(val);                  // sets the servo position according to the scaled value
  delay(15);                           // waits for the servo to get there
}

Credits

MEGA DAS

MEGA DAS

23 projects • 204 followers
MEGA Development of Automated System is a free community responsible for creating automated systems standing on robotics engineering field
JLCPCB

JLCPCB

0 projects • 3 followers
JLCPCB, is the largest PCB prototype enterprise in China creates this platform to Develop and Provide Worldwide with PCB and PCB assembly.
Bob Alsone

Bob Alsone

6 projects • 2 followers

Comments

Add projectSign up / Login