Skid Steer Tank Motor Test Problem

I’m an Ardupilot Rover novice.
I want to control a skid steered tank (zero turn mower) using 2 linear actuators
I can’t get my motors to correctly run in Mission Planner motor test
(Note: when I say motors I mean the leds on the motor control board that will drive the linear actuators - no motors are connected)

I’m using a pixhawk 2.4.8
I’m using Misssionplanner 1.3.7 on a windows PC
I’m using a Taranis QX7 Inputs= AETR Mixer= AETR to a X8R receiver
I’m using Ardurover chibios Ardurover v4.0.0.0 standard version Rover

Servo1_function = Throttle Left 73
Servo3_function = Throttle Right 74
PILOT_STEER_TYPE = 1 (two paddles) (I have also tried =0)
Cruise_throttle = 50%
Cruise_speed 2.0 m/s
Mot_thr_max = 100%
Mot_Thr-Min =0%
Frame_class= Rover
Mot_PWM_Type = normal
Radio Calibration: Left stick FB is Throttle, Right stick FB is Pitch
Pixhawk servo outputs: RC Ch 3= left and RC ch 2= right
RC Map: Pitch=2, Roll=1, Throttle=3, Yaw=4
Servos set to Min=1100, Trim=1500, Max=1900

In Manual Mode the left stick successfully operates the left motor and the right operates the right.
(forward stick = forward motor, back stick reverses motor).

In Motor Test at 55% Minimum- pressing Motor D will activate the left motor
In Motor Test at 100% I can’t get the right motor to activate. (Tried C then A & B)

This also seems to be true in Auto mode with a waypoint
The left motor will activate depending on heading but I get nothing from the right motor.

Log file attached: Skid steer 1 10:45 1/10/20

I would appreciate help in getting motors to run or any other advice.
Thank you.

This wiki page is perhaps one of the most relevant to this issue.

It’s important to understand that inputs and outputs are configured separately and should be tested separately.

Let’s start with the outputs. It sounds like the SERVO1_FUNCTION and SERVO3_FUNCTION params are set correctly as mentioned on this wiki page. It should be possible to test that the motors work using the Mission Planner’s motor test screen. “Test Motor C” should make the left motor turn forward, “Test Motor D” should make the right motor turn forward. If it doesn’t then we’ve got a problem with some of the SERVOx_ parameters or there is an issue with the motor driver hardware (aka ESC). Could you provide a dataflash log ideally or a parameter file?

P.S. it seems like nearly everyday we have a user struggling with the setup of inputs and outputs and often confusing the two. I suspect this means we need an improved wiki page and/or tutorial video explaining it.

1 Like

Does the motor control board have an integrated skid steer mixer?

Thanks for the reply
I tried to upload the file but it quit at 74%, it’s 3.5mb, perhaps too big.
Here is a link to the bin file:
Let me know if this works.

Thanks for the reply.
The motor control board is a pololu VHN5019 being driven by an Arduino.
The code takes the pixhawk servo outputs 2 and 3 and tests for PWM.
Based on PWM it sends motor commands to the Pololu for forward, stop and reverse.
It works fine in manual mode. Code attached.Motor test V6 PWM2 4sw v1 pdf.pdf (27.7 KB)

I had a look at the code. First thing I noticed: Why do you set the switching values to 1200us and 1700us, while the neutral input is at ca. 1500us? This means you have ca. 200us of deadzone for forward input, but almost 300us deadzone for reverse. I would use the exact neutral values of both inputs and add/subtract the same values, not add/substract from the input min/max values.
The other question is, if ardurover can work with such large deadzones.
You take away a large amount of the proportional control ardurover usually expects. This may also be the reason, why the control works in manual mode, but not in auto etc. In manual you just move the stick till the leds light up, but the other modes will not work as expected during bench testing.
There is at least one guy in this forum, who also converted a zero turn ride on mower to ardurover. I guess we should just ping him!:wink: Perhaps he has some tips for you. @ktrussell

Thanks for the reply and the suggestions. At this point, I am coding the linear actuators for only three states but your suggestion is great- especially if I need to use the more expensive linear servos. Thanks also for the referral.

In pursuing your suggestions, I got motor test to work by setting the Servo function for both Servo1 and Servo 2 to 73 and leaving Servo 3 at 74. I’m not sure this is an acceptable solution but it does make the motor test work for both C & D and auto mode now seems to be driving both motors on the Pololu board. To make Manual mode work I then needed to change the RC map from P2,R1,T3,Y4 to P1,R2,T3,Y4. At this point the Pololu board can be driven in both manual and auto mode. Now I need to start testing/tuning to see what that means in reality.

Thanks for your help,

I had a quick look at the log file and having SERVO2_FUNCTION set to “52” (rcin2) is suspicious especially if the autopilot’s servo2 output is connected to the motor driver. Maybe you’ve already resolve this now by setting it to “73”. There really should be only two pwm connections from the autopilot to the ESCs/motor control board.

It might be a good idea to remove the Arduino from the setup and directly connect the autopilot’s servo1 and servo3 outputs to the motor driver if possible. I’m just worried that a string of issues related to the arduino’s problems will distract from the AP setup.

Thanks for the reply. I now have Servo 1 at 73, Servo 2 at 52 and Servo 3 at 74 and motor test is working. The dual motor controller is connected to Servo 1 & 3 outputs. It looks like all I had to do was change the outputs from 1&2 to 1&3 and the RC map from Pitch=2, Roll=1, Throttle=3, Yaw=4 to 1234.

I agree with your idea to remove the Arduino. I was trying to use the Arduino and Pololu and some $35 linear actuators to avoid paying for the more expensive linear servos. I’m now thinking that the complexity isn’t worth the savings and will try linear servos directly connected to the Pixhawk running Ardurover and see how that works. I noticed ktrussell 's Hitec D845WP solution for dealing with a hydro-gear, which is what I have, but at this point I’m experimenting with Actuonix R16-140-150-6-R linear servos.

I appreciate your checking my log file and your suggestions. Thanks, Paul

1 Like

Hi Paul! I have been not checked the Ardupilot discussion forum as regularly as I should and am just now seeing this thread. Glad to see you are working on a zero-turn and making progress. You are going through many of the same issues I did when starting out, but I see that you are getting the help you need here!

I used Actuonix P16 servos with the built-in feedback potentiometers and Actuonix control boards (only $20 each when bought with the servos directly from Actuonix) for an entire season with the mower. I was using the slowest ones ( to get the most force. The servos were very sluggish, but Ardurover was able to do a pretty good job in auto after many days of tuning. It took some practice to learn to drive it in manual because I had to anticipate turns and the ends of turns as I operated the joysticks. That was the reason I decided to try the heavy duty rotary servos (D845WP).

As I was switching to the new servos, I noticed that there was a spring on each rear wheel transmission that acted in both directions to add resistance to the stick movement. When I removed these springs, the force required to move the sticks became way less. I think I could have gone with a faster, less powerful 16P and been OK. So check that on your mower.

As far as choosing linear versus rotary servos, there are these pros and cons in my mind:

  1. A linear actuator/servo just seems like a good fit for what we are trying to do. We want to move the stick back and forth, perfect for a linear actuator’s motion. My Bad Boy mower had a perfect place to mount the little 16P in the place of the pneumatic “struts” that were there. I only had to drill one small hole for each actuator. It was nice. With the rotary servo, I designed a mechanism to translate the rotary motion to linear - not rocket science, but something else to do.
  2. With a linear actuator, you cannot easily move the actuators in and out by hand. This means that if your mower is way across a field and something fails with the automation, you can’t drive it home with the sticks without taking loose the actuators. If you do try it, you risk damaging the actuators. A rotary servo can be operated manually when no power is applied to it. It is probably not good for it, however. I try to be gentle when i have to do it, but you can drive the mower in the normal way in a pinch.
  3. The speed of the rotary servo is very fast and the force is very adequate for my mower. The linear servo I used was very slow. Again, though, you may be able to use a faster one, especially if you remove the spring I mentioned, if your mower has that.
  4. Each type of actuator has its own safety implications. On my mower, when the power is removed or accidentally killed to the servo, the stick can fall forward (I have half the stick removed, even, but still…) and cause the mower to move forward. In the case of the linear actuator, if the power is lost, the actuator holds its previous position, which could be anywhere. So, the lesson here is you MUST have an independent safety cutoff for the engine and you should never leave the mower operating unattended unless you have a remote field where the mower cannot hurt anything if it runs away.

Sorry for the long reply… I am sooo due to update my Youtube channel… One day…
Keep us posted on your progress!

1 Like

Hi Kenny:
Thanks for the reply. I’ve been following your work and it’s really impressive. I got the impression that you had to write a bunch of special code for your zero turn?? Is this correct or did you use the ardupilot stuff?

I started out using a $30 Homend actuator and an Eco-worthy wireless motor controller to manually control the tank and it worked Ok. (Both from Amazon.)


But I’m really interested in the Auto mode so now I’m using the Actuonix R series linear servos (L16-140-150-6-R). I have them working in a test bed and when it gets warmer I will try them in the tank. The tank has a separate wireless engine kill and that seems to handle the safety issues. Since I’m directly controlling the sticks I have it set up so I can pull the pins if I need to override the actuators. I agree it would be nice to have a way to free wheel the servos when the automated system isn’t working.

Thanks again. I’ll keep you posted. Paul

I did not have to write ANY code for the operation of the mower. Ardurover runs a zero-turn “right out of the box!”

I wrote very simple code for 2 external devices:

  1. LoRa modules: I am using Adafruit Feather M0 LoRa modules for my RTK GPS communication from Base to Rover. It is about 100 lines of code on the receive end and 75 on the transmit end. I have the code posted on GitHub ( One could use different telemetry or the MAVLink injection method that many use and not have to write code.

  2. Safety Controller: I use an Arduino Nano to monitor the RC Receiver to determine if the mower loses communication with the RC transmitter for more that 20 seconds. If it does, it shuts down the mower. I have this completely independent of the Pixhawk. It is 75 lines of very easy code. I’ll be happy to share that with anyone with a disclaimer that it is experimental and I do not guarantee it in any way. I probably should put it on GitHub.

Looking forward to seeing more of your project!

Hi Kenny,
I’m now at the stage of trying to tune the tank. As you can imagine it is quite ponderous and slow to turn. I have had success with single waypoint straight run in Auto mode. I’ve read the information on tuning L1 and reduced the WP_Pivot_Rate from 90 to 60. I set up a two waypoint track with a 90 degree turn at waypoint one. The tank executed it perfectly on the first try and then I couldn’t get it to do it again. The tank would keep overcorrecting, sometimes on it’s initial ramp up from the home point. I also tried decreasing WP_Pivot Angle from 60 to 30 with no improvement. Can you give me some advice on basic tuning for a skid steered tank.
Thanks, Paul

I am sorry to be so long in replying. I will try to send more info later with any tips I can think of.
One thing I do feel strongly is that you will not get consistent, accurate pivot turns if your compass is off. This is particularly difficult to achieve if your vehicle has metal moving parts or electromechanical devices, such as my mower. My turns are almost never perfect, but they are fairly repeatable which works OK for my purposes. I posted a video just the other day illustrating this point:

Other than that, experimenting with the pivot turn rate as you have is worthwhile. For a long time, I thought that the problem with my pivot turns was due to the very slow linear actuators I was using for my left and right throttle actuation. But when I switched to must faster servos, the problem stayed about the same and then I noticed that even if I slowed the turns down to a very low rate, it overshot exactly the same. I believe it all goes back to having an accurate heading from your compass, which make sense considering that while the rover is in one place pivoting, the heading information from the GPS is of no value (unless you are using 2 GPSes in a Moving Base configuration, which is a different situation).

As you probably know, the Pivot Angle setting only determines how sharp of a turn in the mission will trigger a pivot turn as opposed to normal navigation.

I’m sure you have seen @rmackay9’s tutorial on the subject: Those are certainly worth following.

Please report back your progress. I will keep thinking…

Hi Kenny,
Thanks for the reply. I did some speed tests this morning and the tank has a maximum speed in manual mode of about 0.5 m/s. I also did some straight runs (one waypoint) in auto and it seemed to be correcting nicely. I have attached a video of the tank doing a two waypoint run with a 90 degree turn to the left at waypoint one. I’ve also attached a video of the track. It does the first waypoint turn nicely (overcorrecting slightly) then gets into lots of overcorrecting as it tries to get to waypoint 2. The tank solenoids take a while to activate. Did I read somewhere that there was a parameter for deadzone MOT THR MIN. I tried it but when I went to manual mode one stick went forward (left) and the other back. So maybe it’s not for skid steer??
Thanks for the video. I’m not getting any AHRS errors. I appreciate your help.


1 Like

That is an awesome vehicle!!! Did you build that from scratch, buy a kit, or what! I NEED ONE!!!

A few tips:
Be sure that mechanically the vehicle is pretty true, in that it goes straight in manual mode when you give it forward and reverse throttle only.

I would try to tune the speed controller in STEERING mode, using the graph of PID_desired versus PID_achieved. (See Randy Mackay’s tutorial:

Then tune the steering in STEERING mode, using the graph of PID_desired versus PID_achieved. (See Randy Mackay’s tutorial: You should be able to move the steering stick to a certain point and hold it and see that the “achieved” line matches the “desired” after a relatively small time. It may overshoot and then come into the desired but you don’t want it to oscillate. You don’t have to get this perfect.

You may need to alternate between the tuning steering and throttle as they do interact to some degree. When you get one working well, go back to the other, etc.

Once you get the steering and throttle tuning to where the tank drives well in STEERING mode, then work with AUTO. Theoretically if you have the steering and throttle tuned well, then you now should only have to work with the NAV-L1 controller. It is an “outer-loop” that sends commands to the steering and throttle loops.

Also, while you are tuning, you would want to make sure pivot angle is set to a fairly high number such as 60 degrees so that the controller doesn’t kick into pivot turn mode when it is just trying to correct its course on a straight line.

It takes a lot of patience, especially with a very slow vehicle.

I don’t know if I am helping or not. If it makes you feel better, I spent countless hours tuning! I still need to do better, but I need to get some work done, so I just live with it being imperfect!

1 Like

Hi Kenny,
Thanks for all the great information. I purchased the tank used from a paintball park in New Hampshire. They are built in England and all the information on the purchase and modification can be found at

I’ll keep you posted on my progress.

Thanks again,


1 Like

That is very comprehensive and interesting information in your blog. Anyone planning a similar project could learn a lot from your blog! Nice work…

Great summary of the tuning process. Especially the patience part.

Somewhat tangential question, but did your mower need different steering and throttle tuning parameters on different terrain? I tuned my robot in my driveway, and then took it out in the backyard and had to play with the parameters again to optimize performance.