Questions tagged [motor]

Use this tag for questions about connecting, controlling, and safely operating motors using an Arduino board.

Filter by
Sorted by
Tagged with
-1
votes
2answers
1k views

How to switch 12V water pump

I found this pump: https://www.aliexpress.com/item/Free-Shipping-Ultra-quiet-DC-12V-3M-240L-H-Brushless-Submersible-Water-Pump-High-Qualtiy-mini/32472119699.html Now, I want to control it from an ...
2
votes
1answer
88 views

Is analogWrite() inferior to writing directly into registers?

I'm trying to control a DC motor's speed with my Arduino Mega analogWrite(), but it doesn't seem to function properly. The motor never completely slows down, just slows down a bit (which is still ...
2
votes
0answers
339 views

Servo.attach method causing strange issue [closed]

I am using the L298N motor driver for a robotics project to control 4 motors. 2 motors in each input and output terminal. I have this connected to an Arduino Uno which is powered by about 7-8v from ...
1
vote
1answer
133 views

use only one input pin in L293?

I have an L293 motor driver chip, in which the two input pins are used in order to turn the motor forward or reverse, or stop it. So I wοnder if I could use only one input pin, ... For running mode: ...
0
votes
1answer
335 views

How to power two stacked motor shields with one 3S Lipo battery (11.1V)?

I have these 2 motor shields: Adafruit Motor Shield V2 and Seed Motor Shield V2. They are stacked on top of an Arduino UNO. My question is, how can I power 2 of those motor shields with one 3S Lipo ...
-1
votes
2answers
57 views

How do i test whether my code fulfills the timing requirement?

I at the moment trying to interface to an stepper motor control board - (ST330-V3) I wrote the code, but aren't sure how i should test it. Is there someway i could scope it, such that also can be ...
2
votes
1answer
836 views

Using an LM339 IC as a motor driver

I have an LM339 IC from Radioshack that I am hoping to use as a motor driver. I read many resources on how the L239D can be used as one. I don't have enough circuit experience to truly know the ...
4
votes
1answer
109 views

Motor running slowly when connected to digital pins, but fine with 5V pins

I am trying to connect a Dagu DG01D motor to my Arduino Uno. First I tried connecting the black wire to GND and the red wire to digital pin 7. My code: void setup() { pinMode(7, OUTPUT); ...
0
votes
3answers
91 views

Need help modelling and coding a feedback scenario

Above illustration is the basic setup for the question. The scenario will be the following: A potentiometer(providing 0 to 5V) is an analog input to A0. This potentiometer voltage is converted to ...
0
votes
1answer
375 views

Reverse DC motor direction every second automatically

I have the Arduino Starter Kit and I'm on project 10 Zoetrope. I've removed the switch that changes the direction as I don't want the reverse to happen when I press a switch. I want the reverse to ...
2
votes
2answers
626 views

analogRead DC Motor - Negative value

I was trying to play with Arduino this weekend and connected a DC motor to A0 and GND to measure the voltage it provides when I rotate it. However, when I rotate the DC motor with my fingers to test ...
1
vote
2answers
2k views

Controlling 5 DC motors with Arduino

I am looking to purchase the correct hardware to be able to control 5 DC Motors from an Arduino (UNO preferred, MEGA if necessary). The Specs of the Motors are as follows: 12 V nominal, 3 → 12 V dc, ...
1
vote
1answer
198 views

Can I use a DAC with an L293D driver?

I'm trying to provide analog control to a Bluetooth controlled car, via Arduino. I have joystick app (as the pot). It send values between 0 to 255 So I'm thinking... Whether this flow down here 👇 ...
1
vote
1answer
85 views

Servomotor losing its connection right after being connected to Arduino

I am working with two servomotors and both are having the same problem: right after i connect them to the arduino and upload the code, they do as the code says for a really small amount of time (0.1s ...
0
votes
1answer
1k views

How to turn servo to a specific location and then turn over

I work on my first arduino car project and i want to turn my servo to a position with a letter input This is my code so far #include <Servo.h> Servo servo; void setup() { Serial.begin(...
0
votes
1answer
184 views

Arduino servo motor on pushbutton

I'm working on my first arduino project and i have my first problem dealing with servo motor , i'm trying to control the servo from my pc with this code but it just spining : #include <Servo.h&...
0
votes
3answers
910 views

How to use relay shield to control dc motor speed and direction?

I tried l298n before but its output voltage wasn't high so I use relay shield but it seems that the car can only go forward or stop Can I control the speed and direction of dc motors?
0
votes
1answer
104 views

Start to build a robot

I would like to start with a very simple robot, which should be based on an arduino uno. I already have an uno and made the decision fpr my robot chassie: https://www.roboter-bausatz.de/en/diy-...
4
votes
1answer
601 views

Arduino - stepper motor wrong steps number

I just bought a new stepper motor (400 steps for revolution, 0.9°/step) and I would like make a turn of 180° by 200 steps, but it doesn't work as expected. It looks like the motor needs only 110 steps ...
2
votes
2answers
155 views

Problem with wrapping Adafruit Motor Controller function calls in a class

I'm working on an Arduino robot and I ran into a problem when reorganizing my code. I have an Adafruit Motor Shield v2.3 connected to an Arduino Uno. My robot can be controlled using a bluetooth ...
1
vote
1answer
149 views

Bluetooth radio control of a motor

I need to purchase the correct bluetooth module for interfacing some simple functionality between an arduino and a motor. The tricky bit is getting the bluetooth radio to play nice with android and ...
1
vote
4answers
4k views

Arduino Driver can I use only PNP?

is it possible to use a normal PNP transistor to drive a motor? I'm kinda new to this stuff so I want to be on the safe side, so I don't damage my Arduino Uno because of the motor. I have made a ...
0
votes
1answer
131 views

Should I control each of the four robot wheel separately or wire two from each side together?

I am making a remote controlled Arduino robot. I has 4 DC motors for wheels. I have 2 motor drivers available that control two dc motors each. I was wondering what the downsides are of wiring 2 dc ...
2
votes
2answers
243 views

Bizarre transistor behavior and voltage with DC motor in simple circuit

I started a new motor related project recently with a new Arduino Uno, beginning with several tutorial circuits included in the Vilros Arduino guide. The circuit in question is #10, a simple DC motor ...
1
vote
1answer
2k views

Arduino : How to control AC Motor Speed [closed]

Controlling speed of DC Motor from arduino could be done via PWM and H-Bridge, but how can i control an AC Motor? Thank you.
0
votes
1answer
1k views

Relay for controlling a water pump motor

I want to switch on and off a motor with arduino, used for pumping water. I need to have a idea which relay could be used with arduino. Here is a photo of a similar motor:
2
votes
2answers
2k views

Precise rotation (steering direction to a given angle) on obstacle avoidance robot

Forgive my lack of knowledge of some robotic related terms, but the way my two wheel drive robot steers is simply by having each wheel move at different speeds; for left, for example, the left wheel ...
1
vote
1answer
907 views

How to control a DC Motor with Hall Encoder using Arduino and Motor Driver?

I'm using a DC motor with Hall Encoder. I bought it from DX. I have made all the connections to motor driver and arduino and I suppose all are correct. I've connected m1 and m2 pins of motor to that ...
1
vote
2answers
8k views

How to run stepper motor at its maximum speed

I am running a stepper motor using arduino and IC l293d. What is the maximum possible speed of rotation that I can achieve with the IC and what should be the applied voltage for the same? Earlier, I ...
0
votes
1answer
151 views

Calibrating ESC and then using it [closed]

i have 30Amp ESC which i can move motor by providing values , but i am unable to know what is the minimum and maximum throttle speed of the motor.... how to achieve that level of info through ...
0
votes
1answer
5k views

Connecting 4 servos, 2 motors, hc-05, sr-04 and L293D to Arduino

I am trying to make an obstacle avoiding robot with robotic arm. First, I am from software programming field with no experience in electronics, circuits and Arduino. Using online tutorials so far I am ...
0
votes
1answer
823 views

Code: Switch case and loop problem [closed]

Please am working on this automatic drink dispenser, i got a sample code as am still an amature. I seem to be stuck and i please need assistance. Components: I2C, keypad, LCD peristaltic pump. ...
3
votes
2answers
5k views

How can I control 4 DC motors with an Arduino?

In a few months, I am planning to construct an Arduino robot with multiple sensors etc. I will use an arduino mega and a 4wd chassis like the one here: Chassis. The chassis uses 4 DC motors. I was ...
0
votes
1answer
314 views

how do I power my motor shield without an arduino uno?

I want to power my motor shield without my UNO. I have connected the +ve and -ve terminals resulting in lighting up of the LED. Is there any way to control the motors in this arrangement from the ...
0
votes
1answer
44 views

Motor control using arduino board

I want to control 2 dc motors using the arduino board directly. One motor must rotate clockwise and the other counter clockwise. The directions doesn't change only the speed of each motors. Can this ...
1
vote
0answers
25 views

is it possible to code microservo automatically stop when the speed of rotation getting slower?

my group is doing a project which call automatic bed maker. we want to use a servomotor to pull the sheet of the bed. can we possibly make the servomotor stop rotate when the speed of rotation ...
0
votes
2answers
122 views

Good Arduino motor drivers

I need some motor drivers that can control a DC motor with 10-15 A and 25 V. I can't find any shield that can do the job. I need to control 4 motors with these. Can you suggest some models that are ...
1
vote
1answer
480 views

Controlling 2 DC Motors with L293D and 6 V battery pack?

Sorry if my question looks newbie, but I'm just starting to delve into robotics and electronics, and my first project was building a small arduino collision-avoidance robot with a ultrasonic range ...
0
votes
1answer
260 views

Peristaltic Pump Project

I am designing a peristaltic pump and need some advice for parts. I am using an Arduino Leonardo and also have an UNO and am planning on adding a temperature and pH sensor as well. I have two ...
0
votes
1answer
24 views

Sketch not running as expected

I wrote this sketch along with an HC - SR 04 Ultrasonic transducer and a DC motor. Whenever the HC-SR 04 reads any distance less than 15 cm, the motor stops, otherwise it keeps running. The problem ...
0
votes
1answer
201 views

Power motor with Uno

I am trying to power a small peristaltic pump using an UNO R3. I have it powered using usb, and I tried running the blink program to see if I could power it using digital write, and extended the delay ...
5
votes
2answers
5k views

DC Motor Speed Measurement using Rotary Encoder

I have written the following code to measure the speed of a unidirectional DC Motor.I have attempted to measure the time between successive interrupts in order to calculate speed. boolean check; ...
0
votes
1answer
32 views

Can this Motor shield support other arduino functions?

http://www.flipkart.com/grab-em-l293d-motor-driver-arduino-shield/p/itmehvzzpzj4wyby?pid=ETYEHVZZFFHRFMFG I want to ask whether this shield will allow me to use the free pins of arduino for other ...
0
votes
1answer
51 views

2 Direction Motor [closed]

Using an Arduino-Nano, I'm trying to make a circuit that will change the direction of a motor based on two inputs. The input from the Arduino will be amplified by a transistor. Here's the code: int ...
0
votes
1answer
467 views

My Arduino is heating up

I am working on a simple Arduino project where I am controlling 5 TowerPro servos. I read that each takes up 2.2 V each so that means the Arduino can only handle about 2 , if using 5V. So far Ive ...
1
vote
1answer
558 views

Electric interference from cnc spindle

I've got a CNC machine and I recently started using a spindle for it. At first it was running smoothly with no issues, but after the first brush pair wore off (I've replaced them later on) it started ...
0
votes
1answer
649 views

connect arduino to battery with 12V motor

I am looking at this(instructable with circuit picture) tutorial for making a self-balancing robot. However, I am confused about how the battery connects to the arduino. I know the 12 V must go to ...
1
vote
1answer
88 views

Decreasing large DC motor power usage by coasting [closed]

I'm working on a class project - an electric bike competition. Part of the requirements for the final grade is having a "race advantage system" on your bike. Basically, just something unique that will ...
0
votes
2answers
2k views

Powering two L298N motor boards with external supply [closed]

I have been struggling with this as I'm a complete electronics and arduino beginner. I am trying to power two DVD-drive stepper motors using two L298N motor boards. For some reason, I can't figure ...
-1
votes
3answers
476 views

Low current in a motor used in a line following robot

I'm trying to make a line following robot for my students, the problem is that I have not done any calculations (I don't know how). The motor can't move the robot unless I connect it directly to the ...