Brushed with Relay Output for Multiple VFD's


I am working on implementing a Pixhawk 4 in an application that is running two industrial VFD’s as motor controllers. I am operating the Pixhawk in a skid steer mode. Each of motors (VFD’s) are required to move both forward and reverse.

Each VFD will require a relay signal to command either forward or reverse rotation plus a PWM output for the speed command. I have set the Pixhawk motor type to “Brushed with relay.” To be clear, for proper control each VFD requires two relay pins for rotational direction (one pin for FWD one for REV) and one PWM output for speed.

The setup for skid steer mode and brushed with relay motors tutorials appear, to me, to show that when configured in this way, I would end up with two relay outputs (AUX OUT 5&6) and two PWM outputs (Servo 1 & 3) by default. I have added additional relay outputs by changing the BRD_PWM_COUNT to “2” which gives the two additional relay pins I need.

My questions is, how do I now assign these 4 relay outputs (AUX OUT 3,4,5,6) to operate in conjunction with a particular servo output such that when commanded the appropriate relay output goes high to command rotation direction in conjunction with the correct servo PWM (speed) output?

To give an operational example, the intent is for an RC user to push the left joystick forward (from center position) resulting in the left motor being commanded to rotate in the FWD direction. The further forward the stick is pushed, the faster higher the PWM frequency from the servo output. If the joystick is pulled back past center, the VFD is commanded to rotate in reverse with increasing speed.

Any guidance is very much appreciated!


It sounds like you’re using ArduPilot firmware on your Pixhawk. If so, asking at may be better for you.