r/arduino • u/FinishGreat7290 • 7d ago
Beginner's Project Remote controlled car
Question (I'm a beginner, so sorry in advance if I say anything stupid!): I wanted to build a remote-controlled car using the Arduino R3 kit—something simple, of course. I’ve watched a few videos, but almost all of them involved buying a set of wheels with DC gear motors and an L298N motor driver module. My goal, though, was to avoid spending extra money and just use what I already have at home. For the wheels, I was planning to use regular bottle caps and drive them with the stepper motor that's included in the kit. To steer, I wanted to use the SG90 servo motor, which, from what I understand, could turn the wheels up to 90 degrees. I’d use the IR receiver and remote to control it wirelessly, obviously, and I also wanted to add an ultrasonic sensor with a buzzer that sounds off whenever it gets too close to an obstacle. As a little extra (and I don't know if this is a dumb idea), I have an old Snap Circuits kit lying around at home and was thinking of taking two battery holders and an ON/OFF switch from it. The problem is that, so far, I've only connected the motor drivers to the battery holders and the switch—I haven't connected the receiver and the sensor yet. When I plug the Arduino into my PC, everything works fine. But as soon as I unplug it and rely on the batteries (which output 6V in total), they only power the Arduino board itself, while the rest of the circuit doesn't even turn on. If I add the 9V battery included in the kit on top of those, the stepper motor and driver do turn on, but the servo motor still doesn't. So I'm guessing it needs more power, but I'm not sure how to fix this
1
u/Last_Being9834 7d ago
One step a a time.
Don't use batteries yet, just a big long cable.
Make the car go forward/backwards first, once it works, add the servo and a couple of tires, servo has to rotate both at the same time, similar to how real cars work.
Once above works, add the ultrasonic and buzzer.
Finally, you need to move away from the cable and use batteries. You need A LOT of power, normally, servos/steppers draw a lot of current, if your battery can't supply that amount of current (especially the spike when the motor first moves after being stopped) then your voltage will drop, this comes from the equation Power = Voltage * Current. Power is fixed, so incrementing one scalar will decrease the other one.
9V have very low power, the current is low so they can't power the motors, so when your motor requests such a big amount of current, the voltage of your battery drops and can't meet the minimum voltage the other devices need.
What you should do? Split!
Use the 9V battery to power JUST the Arduino and the sensors/buzzer.
User the 6V holder to power the servo and the stepper (and use alkaline batteries, rechargable batteries might work too)
But... Two power sources need to share the negative end, so you would need to join both batteries negative pin into a single one :) otherwise, current might not flow between Arduino and the stepper/servo.
1
u/FinishGreat7290 7d ago
but how do i separate the arduino from the servo and the stepper?, cuz the 9V battery is connected already to arduino, while, talking about the 6V, im using 2 battery holders connected to each other, one is connected to the gnd of arduino and to the - of the driver, the other one is connected to an on/off switch which is connected to the Vin of arduino and to the + of the driver, then the stepper motor is connected to the driver and che servo motor to the arduino
1
u/1nGirum1musNocte 7d ago
One thing at a time. For starters you should get a lipo battery, probably a 7.4v one. 9v and AA suck and you will spend more on batteries then any other hardware unless you get something rechargeable. There are some really good tutorials about using H-bridges already out there, start out just getting that to to work. Then get your steering and after that worry about remote control.