I am working on a custom airframe using the PixHawk mini board where we need two additional servo PWM outputs. We would like them to operate as pass through from RC inputs. This is possible on the larger boards through the RC_MAP_AUXx parameters, but auxiliary pins are not pulled out on the mini board so we cannot use that feature. It is also possible using ardupilot by setting SERVOx_FUNCTION to 1. However, I cannot seem to figure out how to get it to work using PX4 with the PixHawk mini board.
I have tried creating a custom airframe with a mixer file. I am able to change the mixes for the first four channels (for instance swapping the elevator and rudder outputs). However, I am unable to get changing output on channels 6 and 7.
For reference, here is the mixer file I have been trying:
Custom mixer file
Inputs to the mixer come from channel group 0 (vehicle attitude), channels 0
(roll), 1 (pitch) and 3 (thrust).
Also channels 6 and 7 to output to servos 6 and 7.
Aileron mixer (1)
Two scalers total (output, roll).
This mixer assumes that the aileron servos are set up correctly mechanically;
depending on the actual configuration it may be necessary to reverse the scaling
factors (to reverse the servo movement) and adjust the offset, scaling and
endpoints to suit.
As there is only one output, if using two servos adjustments to compensate for
differences between the servos must be made mechanically. To obtain the correct
motion using a Y cable, the servos can be positioned reversed from one another.
M: 1
O: 10000 10000 0 -10000 10000
S: 0 0 10000 10000 0 -10000 10000
Elevator mixer (2)
Two scalers total (output, roll).
This mixer assumes that the elevator servo is set up correctly mechanically;
depending on the actual configuration it may be necessary to reverse the scaling
factors (to reverse the servo movement) and adjust the offset, scaling and
endpoints to suit.
M: 1
O: 10000 10000 0 -10000 10000
S: 0 1 -10000 -10000 0 -10000 10000
Motor speed mixer (3)
Two scalers total (output, thrust).
This mixer generates a full-range output (-1 to 1) from an input in the (0 - 1)
range. Inputs below zero are treated as zero.
M: 1
O: 10000 10000 0 -10000 10000
S: 0 3 0 20000 -10000 -10000 10000
Rudder mixer (4)
Two scalers total (output, yaw).
This mixer assumes that the rudder servo is set up correctly mechanically;
depending on the actual configuration it may be necessary to reverse the scaling
factors (to reverse the servo movement) and adjust the offset, scaling and
endpoints to suit.
M: 1
O: 10000 10000 0 -10000 10000
S: 0 2 10000 10000 0 -10000 10000
Nothing mixer (5)
xxx
Z:
Leftwing servo (6)
xxx
try to get left wing features
M: 1
O: 10000 10000 0 -10000 10000
S: 0 5 10000 10000 0 -10000 10000
Rightwing servo (7)
xxx
try to get right wing features
M: 1
O: 10000 10000 0 -10000 10000
S: 0 6 10000 10000 0 -10000 10000
Does anyone know how how to do this using PX4?