How to control main motors from offboard

I am trying to use the pixhawk purely as an interface to control my motors. I have it connected via serial to an offboard TX1 which is running the controller, and am trying to send actuator commands to my quadrotor motors via the pixhawk. I know there may be a significant amount of latency with this setup, but for now I don’t really care about that.

Now in order to control the motors I have been trying to use the actuator control message as seen in this example.

I have updated the code and have had success with it working. However, in this example the actuator control message he is sending is still sending r,p,y and throttle, whereas I want to control the motors individually.

Now in order to do this it seems like I need to change the mixer on in order to just passthrough the direct motors commands. On actuator_msg channel 0,1,2,3. However, how I am supposed to do this is what I am stuck on? I have tried this two ways.

The first thing I was to load the mixer via the mavlink console in qgroundcontrol. Using this command
mixer load /dev/pwm_output0 /etc/mixers/FMU_pass.mix

I then run my above code, but my motors do not spin. However, by running
pwm info -d /dev/pwm_output0

I am able to see that my pwm values have changed.

I have also tried it on dev/pwm_output1.

Due to the pwm values changing in the console I believe I am on the right track, but am just missing one or two extra steps which I can not seem to figure out.

The other way I have attempted this is to is to create a new file in init.d and have that load the FMU_Pass.mix and then load that configuration onto the board. That also ended in failure though.

So if anyone has any idea on what steps I may be missing I would appreciate the help. Also if you know a better way to send direct motor commands rather then messing with mixer values, then I am all ears.

Hi edwinem, did you fix it? I recommend you to use the aux channels. Setting the mixer to use the control group 3, you can control the PWM of your motors if you connect them to aux1, aux2 and aux3. I checked that it works and probably, setting control group 1 you would be able to use aux0 to aux3.