Actuation and Output
The actuation subsystem in Vayu converts control outputs into motor commands that drive the drone. It forms the final stage of the control pipeline, translating abstract control signals into hardware-level outputs.
Motor Mixing
The control outputs from the rate controller correspond to roll, pitch, and yaw corrections. These are combined with throttle input to generate individual motor commands using a mixing algorithm specific to the quadrotor configuration.
For a quadrotor layout, the motor outputs are computed as:
where:
is throttle
, , are roll, pitch, and yaw control outputs
This mixing ensures that control inputs are properly distributed across all motors to achieve the desired motion.
Output Normalization
To maintain valid actuator commands, the motor outputs are constrained within allowable limits. If any output exceeds bounds, all outputs are scaled proportionally to preserve control direction while ensuring safe operation. Similarly, negative outputs are shifted to maintain non-negative motor commands.
Throttle Handling
At low throttle values, control authority is reduced proportionally to prevent instability during arming and low-power operation. This ensures smooth motor behavior and avoids abrupt responses.
Hardware Output
The final motor commands are applied using pulse-width modulation (PWM) generated by hardware timers (TIM1). This provides precise and deterministic control of motor speeds with minimal CPU overhead.
System Behavior
The actuation pipeline ensures that control outputs are translated into smooth and stable motor responses. The combination of mixing, normalization, and hardware-timed output enables reliable execution of control commands in real time.
Overall, the actuation subsystem completes the control loop by bridging the gap between control computation and physical system response.