I’m having a rather odd issue with my 6ch Maestro. I have two 18v7 motor controllers hooked up (RC mode) to channels 0 and 1, driving two motors. Neither is providing power to the Maestro and they are the only other pieces of hardware wired to it. When I drive them both with a 1ms pulse both motors run fine and seem like they would be happy to do so all day. When I try to drive them both with a 1.75ms or greater pulse (that’s what I’ve tested) the motors will run fine for some amount of time between ~ 5 to 10 seconds (varies with the pulse time: shorter run time with higher pulse time) and then the Maestro will appear to have a firmware crash which triggered a watch dog reset, according to the LEDs. I can also make this happen near instantly if I turn other servo channel (ei. #2) on and drive it to 2ms. Oddly, this does not happen when both motor controllers are off. I originally thought this might be a power issue with the usb but the more I look into it that doesn’t seem to be the case. My only thought it that there is too much current being sunk by the signal wires and that is causing a chip reset? That’s about all I can come up with right now.
Anyone know what could be causing this?
Any help would be appreciated.
Hello, Angry Monk.
Are the included blue capacitors soldered into your 18v7 motor controllers? Did you remember to connect the Maestro’s ground to the GND of the Simple Motor Controllers?
Could you describe how you are powering your system and fully describe all the connections you have made?
Are you sure it is a watchdog reset? The red and yellow LEDs would blink in unison when the Maestro starts up.
It’s unlikely that there is too much current being sunk by the signal pins, because the Maestro’s signal pins have a 220 Ohm resistor to protect them.
I got the 18v7’s fully assembled so all the components are in place, including the blue caps.
As for power and connections, I have the Maestro plugged into the USB and on outputs 0 and 1 I have a standard servo extension (GND, +, and S) going to their respective 18v7’s on the first RC input channel. So each 18v7 has a GND, +, and S connection to the Maestro. I am not supplying power back through these lines to the Maestro from either 18v7, so the positive wire is there but unused. Also, I am not powering the servo channels on the Maestro with any source. I have a single 8 cell Ni-MH pack providing power to both 18v7’s (one pack, two controllers). And of course I have the motor wired into the appropriate outputs on each 18v7. As far as I know, its all the standard connections, nothing special.
And yes, both the yellow and red LEDs flash when the Maestro resets.
Also, when the Maestro resets the two controllers don’t seem to be phased by this. The only error they appear to display is an invalid input signal error which makes sense since the Maestro is no longer outputting a signal.
Thanks for your help.
I just tried reversing the polarity of the motors as a simple experiment to see what would happen. I wanted to see if the Maestro would continue to cut out with a 2ms RC pulse with the motors running the opposite way as I had previously tested (one would think motor direction would have no influence on this problem). So I tried that and guess what? It ran fine. I switched to a 1ms RC pulse and the Maestro cut out as usual. … Interesting. It appears to be dependent on motor direction for some odd reason. Then I tried wrapping the signal and ground wires between the 18v7 and Maestro through a ferrite bead. That seemed to help at first, however the Maestro still failed after 20 or 30 seconds.
Is it possible there is some feedback from the motors, going back through the 18v7’s, that is screwing up the Maestro?
Thank you for the detailed descriptions. What kind of motors are you using? Do you know what the capacity (mAh) of your battery pack is?
Yes, this is possible. I recommend simplifying your system to the simplest possible thing that still exhibits the problem. Could you try disconnecting both motors from the 18v7’s and see if the problem still happens?
I’m using two “Barber-Colman FYQF-63310, 12VDC, reversible, 300 rpm, body dimen, 1-3/8 dia x 2-3/4” long, shaft 0.1875" dia x 13/16" long" geared brushed motors with the 18v7s. They are probably drawing about 1-3 amps each while running. The battery is a 9.6v 1600mAh pack.
I tried disconnecting both motors and the system seems to be cooperating well. I could not recreate the problem.
I did notice through my own tests, since the addition of the ferrite beads which seemed to help a great deal, that the problem seems to arise when the motors are changing speed or direction quickly. To put it in context, these two motors are setup to drive a robot. I tend to see more failures when I’m starting/stopping the motors, changing directions rapidly, or transitioning from a hard floor to carpet (where there is a ‘bump’ that that the robot needs to traverse). If the robot is traversing at an angle each motor/wheel can make and break contact several times and cause variable loading on the motor. I’m wondering if this ‘current shock’ caused by this could be doing anything.
A couple more interesting things I’ve found out tonight…
The problem seems to get worse when driving the motors at a lower PWM frequency… I found this out when changing the settings on the 18v7 from 12khz to ~1khz and then 5.5khz.
But by far the most interesting discovery was this:
When I try to drive the motors while directly connected to the 18v7s via usb/serial I get a failure. It occurs around 50% speed for both motors but only while they are spinning in one direction. The direction is the same for both motors. When the error occurs the motor are locked in at their current speed and the 18v7 appears to have lost connection to the computer, and I get the following error message:
“There was an error setting the speed. Control transfer failed. Error code 0x1f”
If I try to reconnect to the 18v7 w/o resetting the power/usb I get this error message:
“Error connecting to device. There was an error getting the firmware version from the device. Control transfer failed. Error code 0x1f”
Interesting to say the least. There might be something odd going on in the motors. I’ll try to get them apart and see if there is anything out of the ordinary.
Hello, Angry Monk.
Before you take your motors apart, I recommend soldering capacitors to the motor leads to reduce the motor noise. Please see this document for more information:
I already have one on each motor. I’ll try to get 4 more to solder from each lead to the case as well.
You think adding decoupling caps to the ground and power that run the microcontrollers on each 18v7/Maestro would help as well?
Adding more decoupling capacitors might help, but before you do anything extreme I recommend continuing to simplify your system more. We’ve already found that if you take the motors away, the problem disappears. What if you take the Meastro and one of the motor controllers away? Do you get USB errors when you just have a Simple Motor Controntroller, a power supply, and a motor?
Also, could you send us some pictures of your setup? Do you have an oscilloscope available?
I tried just running one of the motor controller by itself with nothing attached and the problem was still present. I tried this with both controllers. I noticed they each failed when the motors were running in the same direction. Interesting, to say the least. I figure since the motors were used this speaks to some degree about the direction they might have been run in.
Afterwards I added two more capacitors to each motor (from each lead to the can). Now each motor has 3 capacitors. That seemed to fix the problem. I have driven my robot around a fair amount since the fix and have had no problems.
So I guess long story short, if you have issues with Maestro or motor controller crashing and it seems to be caused by the motors then add lots of capacitors to them.
Thanks a ton for you help, David.
I’m very glad you were able to fix your problem. It is interesting that the direction of the motor matters. For the sake of future people who are having trouble, what capacitance are the 3 capacitors you are using on each motor?