Post · 1 min read· pp. 407–410

Closed loop motion control

BLDC motors Stepper motors

This is the standard motion control approach where the position sensor is used to provide feedback to the motion control loop. The motion control loop (motor.move()) will calculate the target torque (current or voltage) to be applied to the motor using the underlying torque/FOC control loop (motor.loopFOC()) in order to achieve the desired motion.

SimpleFOClibrary gives you the choice of using 3 different Closed-Loop control strategies:

cpp
// set FOC loop to be used
// MotionControlType::torque
// MotionControlType::velocity
// MotionControlType::angle
// MotionControlType::angle_nocascade
motor.controller = MotionControlType::angle;
Torque controlVelocity controlPosition/angle control
MotionControlType::torqueMotionControlType::velocityMotionControlType::angle or MotionControlType::angle_nocascade
Go to Torque control docsGo to Velocity control docsGo to Position/angle control docs

How it works?

BLDC motors Stepper motors

Choose the motion control type:

Position control (Cascaded) Position control (Non-Cascaded) Velocity control Torque control


Copyright © 2026. Distributed by an MIT license.