Dear RPate.1,
The position control mode is accessible from MC Workbench:
Control Unit> Firmware Drive Management> Drive Setting
Also I copied below some extract from the release note:
"Using the Position Control feature
The position control feature can be activated on any configuration that uses an Encoder for speed and position feedback. To activate it, open the Drive Settings dialog from the main configuration panel of the workbench, and select the Position Control item from the Control mode combo box. Dual drive configurations are also supported; the position control can then be activated on any motor equipped with an Encoder.
A set of new APIs is provided to exercise the feature. Among these, the most important ones are the following:
- void MC_ProgramPositionCommandMotor*(float fTargetPosition, float fDuration)
- to set the mechanical angle the rotor is to reach and the duration of the movement to reach it
- float MC_GetCurrentPosition1( void )
- to retrieve the current rotor position
- float MC_GetTargetPosition1( void )
- to get the target rotor position
- float MC_GetMoveDuration1( void )
- to get the duration of the programmed movement.
The
MC_ProgramPositionCommandMotor*
functions work as the other ramp functions of the API. For a complete description of this API, refer to the reference documentation of the Motor Control SDK.
Note that when the Position Control is activated on a motor, the speed and torque control mode cannot be used.
The Position Control feature uses floating point arithmetic. It may require a lot of CPU power on STM32F0 and STM32G0 devices that do not have an FPU."
We are also preparing a specific application note on this topic.
Thanks and best regards,
Claire