dryhops
Posts: 4
Joined: Fri Feb 14, 2020 7:44 pm

Cat Sprayer Turret: Voltage drop running servos and motor simultaneously

Fri Feb 14, 2020 8:45 pm

I am making an automated water turret, purpose built to keep cats off of the counter. I call this, Counterstrike.

The hardware design consists of a raspberry pi 3b+, two MG996R servos which provide pan and tilt controlled by a PCA9685 servo controller. The sprayer is a 5v pump - this is the component I need help with.

The pan tilt system works flawlessly. Cat targets are properly acquired by a tensorflow object detector, and then tracked with a lucas-kanade based tracker. However, once the target is locked and I energize the 5v spray pump via a relay, there is a significant voltage drop and the servos go haywire, losing the target.

I already experienced this issue when I was first setting up the servos and suffered from servo jitters. I added a dedicated power supply and the servo controller, which fixed the jitter issues. This new power supply is 5v 2A, so I expected it to be able to run two servos and the sprayer motor. But running the motor and servos simultaneously isn't working.

So far I have tried:
-Running the motor of the RPi power supply, causes the RPi to reset
-Wiring the motor directly to the servo power supply. Causes the servos to behave erratically
-Wired the motor to the servo controller, in the hopes the on board capacitor would stabilize the power drops. There didn't seem to be a difference.

I really don't want to add another powersupply just for a motor, as I already have two. Do I just need a bigger one, like a 10A? What else can I try?

Thanks for your time!

pcmanbob
Posts: 7935
Joined: Fri May 31, 2013 9:28 pm
Location: Mansfield UK

Re: Cat Sprayer Turret: Voltage drop running servos and motor simultaneously

Sat Feb 15, 2020 11:18 am

Well the data sheet for the servos states
MG996R Servo Motor Features

Operating Voltage is +5V typically
Current: 2.5A (6V)
you have not given details of your pump , but assuming 2-3A at 5V , I would say your power supply is way way underrated at 5V 2A.
We want information… information… information........................no information no help
The use of crystal balls & mind reading are not supported

LTolledo
Posts: 2557
Joined: Sat Mar 17, 2018 7:29 am
Location: Anime Heartland

Re: Cat Sprayer Turret: Voltage drop running servos and motor simultaneously

Sat Feb 15, 2020 12:17 pm

Power the RPi and the pump-motor (and servo) loads separately
connecting their grounds.

for the motor loads (including servos) add the total amperes as if all are running at the same time at max.
as a safety factor, multiply the sum by 1.25 (or even 1.5)
that will be the preferred ampere requirement for the motor load PSU ....

also check the regulation of the PSU....for motor loads, 10% regulation is preferable...
"Don't come to me with 'issues' for I don't know how to deal with those
Come to me with 'problems' and I'll help you find solutions"

Some people be like:
"Help me! Am drowning! But dont you dare touch me nor come near me!"

Return to “Automation, sensing and robotics”