Servers by jDrones

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.

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:https://drive.google.com/file/d/1L3DVBbZkGW7IOlyJZrPQOUcedi3HE7yd/view?usp=sharing
Let me know if this works.
Thanks

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

Sebastian:
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,
Paul

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
Servers by jDrones