I am working on a custom submarine using the Navigator shield. I would like to implement a PWM output for a pin based on the values of the axes in Cockpit. For instance, when axis 0 is 1.00, I want the PWM output to be 1900 for servo 1. Based on the discussion here, I believe that the general method would be to create a compound variable that reads the value of axis 0 and then inputs it into parameter 2 for the MAVLINK command MAV_CMD_DO_SET_SERVO. Is it possible to do this?
That said, depending on your vehicle frame it may be possible to set a servo value based directly on an axis value by configuring the relevant SERVOn_FUNCTION parameter to the corresponding input channel. There is also a potential workaround where an unused motion axis can be sent control signals from the control station software, which are then read back in to Cockpit through MAVLink, at which point the values could be read from the data lake for use in a custom Action.