Arduino tutorial | How to control servo motor with joystick and arduino

preview_player
Показать описание
hello!
In this video,you can learn how to use servo motor using joystick.

materials:-
Arduino uno
Servo motor
Joystick
breadboard
Jumper wires
arduino radar system=

Arduino Tutorials | How to measure distance with arduino using ultrasonic sensor=

Please subscribe for more videos
Рекомендации по теме
Комментарии
Автор

If your servo motor is going left and right when youre turning it to the left side, make the delay to 1 at void loop

skullboosts
Автор

The Code:

#include <Servo.h>
const int Y_pin = A0; // analog pin connected to Y output

Servo myservo;

int val;

void setup() {
myservo.attach(7);
}

void loop() {
val = analogRead(Y_pin);
val = map(val, 0, 1023, 0, 180);
myservo.write(val);
delay(15);
}

scryptio
Автор

hi, it works, only do u know why my servo motor shakes when turning to the left and works normal when turning to the right?
edit: i found the solution, i prolonged the delay time to 150 and it works, not sure if this has other consequences doh?

wardwyseur
Автор

You know what beats' the heck out of music. Actually talking about what your doing.

bgrant
Автор

Welcome done bro i is very easy for everyone this project is amazing

lakshyaprojectwithfunnyvid
Автор

Nice video bro, i was doing a project where i could control a webcam with a servo and joystick and needed a video 2 do it b4 i put a webcam on it, thx bro!

sirvix
Автор

I can't find the code in the description

dhanunjayareddysuggu
Автор

It pauses for a few seconds when i hook it up to the battery andyone know how to fix this problem

fonnieswonderfuladventures
Автор

it works but we have to do some augments

aspect_zach
Автор

And if i want use 2 ou 3 more servo motor with another 2 or 3 joytick? how is the code? a little example please. Thks bro

juliao
Автор

hi great explainatino have you done one where we could attach another motor on the x axis an get it to stay where it is when you take finger off.want tp controll webcam for 3d printer cheers

goflydrone
Автор

Hey im not a programmer but is there a way to make the servo motors hold the position even if the thumbstick goes to 0

evanmason
Автор

it all works great until i plug in my batterie. any ideas?

Studs_Studio
Автор

The screen recorder cut off the first 3 digits of code at the final bit, and the link in the description does nothing. Help me.

jimmyneutron
Автор

Yeah whenever I ran the code I was prompted with Failed to compile to arduino uno

krigga
Автор

Does this work with continuos rotation motors or no

LoganLikesPizza
Автор

2 more questions( noob here) why does the arduino pause/restart every x seconds?
and why does it turn more to the right and less to the left?

wardwyseur
Автор

Is there a way you can do the same thing with the raspberry pi?

catcatwoof
Автор

Is it just my thing saying too few arguments?

epicz
Автор

what is the page where you configure the servos

fernandoetonnant