T-Series/Commands/Set Closed-Loop Mode
Set Closed-Loop Mode - Cmd 118
Warning: This is an "include" page. As such, its contents may be included in multiple other pages. To see a list of all pages that include this page, click on "What links here" in the bottom left navbar. If you make changes to this page, be sure that your changes are appropriate to all pages on which this content will be included. You are also encouraged to review our Zaber Wiki Editing Guidelines. This header will not be included in other pages.
| Instruction Name | Set Closed-Loop Mode |
|---|---|
| Applies to | A-Series and X-Series motorized closed-loop devices |
| Firmware Version | 6.xx |
| Command Number | 118 |
| Command Type | Setting |
| Command Data | Closed-Loop Mode |
| Reply Data | Closed-Loop Mode |
| Safe to retry? | Yes |
| Returns Current Position? | No |
| Persistence | Non-Volatile |
| Summary | Sets the closed-loop (slip, stall, and displacement detection and recovery) control mode for encoder embedded devices. |
This command configures the closed-loop behavior of a device, determining its reaction to slips, stalls, and displacement conditions. Behavior and available settings vary by encoder type.
Devices with Motor Mounted Encoders
| Closed-Loop Mode | Slip Detected1 | Stall Detected2 | Displaced While Stationary |
|---|---|---|---|
| 0 - Disabled |
|
|
|
| 1 - Passive Mode |
|
|
|
| 2 - Stall Detection |
|
|
|
| 3 - Position Correction (Default) |
|
|
|
| 4 - Stall Recovery |
|
|
|
| 5 - Displace Recovery |
|
|
|
1 - A stepper motor has slipped when the encoder feedback lags the Current Position - Cmd_60 by two full steps of the motor or more.
2 - A device has stalled when the motor has failed to make progress towards the targeted position for the Stall Timeout - Cmd 120 period.
Devices with Direct Reading or Linear Encoders
| Closed-Loop Mode | Approaching Targeted Position | Stall Detected3 | Displaced While Stationary |
|---|---|---|---|
| 0 - Disabled |
|
|
|
| 1 - Passive Mode |
|
|
|
| 2 - Stall Detection |
|
|
|
| 3 - Position Correction (Default) |
|
|
|
| 4 - Stall Recovery |
|
|
|
| 5 - Displace Recovery |
|
|
|
3 - A device has stalled when the motor has failed to make progress towards the targeted position for the Stall Timeout - Cmd 120 period.
Voice Coil Devices
| Closed-Loop Mode | Stall Detected4 | Displaced While Stationary5 |
|---|---|---|
| 0 - Disabled |
|
|
| 1 - Passive Mode |
|
|
| 2 - Stall Detection |
|
|
| 3 - Position Correction |
|
|
| 4 - Stall Recovery |
|
|
| 5 - Displace Recovery (Default) |
|
|
4 - A voice coil device is considered to have stalled when the motor has output its maximum force for over the Stall Timeout (Cmd 120) period during a position controlled movement.
5 - A voice coil device has been displaced if it has been held at a new location for the Stall Timeout (Cmd 120) period in position control mode.
Closed-loop (slip/stall/displacement recovery) mode can be enabled on devices with a built-in encoder.
To use closed-loop modes with a third party encoder, use ASCII mode to configure encoder.mode and all encoder related settings. Set encoder.dir so that encoder.count increments in the same direction as pos. Adjust cloop.steps and cloop.counts to reflect the correct ratio between motor full steps and encoder counts.