Utility Scripts · Physical Controls
Drive Priority and Sleeping
When multiple drives are configured, the highest eligible priority controls the mechanism's single motor.
| Item | Meaning / default |
|---|---|
| 1. Fixed lock | Holds the current pose and pauses the mechanism and resistance. |
| 2. Absolute detent | Captured absolute point. |
| 3. Periodic detent | Captured periodic point. |
| 4. Position motor | Holds its target even after reached. |
| 5. Phase motor | Holds the selected target turn. |
| 6. Speed motor | Including the speed:0 brake. |
| 7. Torque mode | Direct signed torque. |
This order applies to Wheel/Crank. Limited types and joystick use Fixed, enabled return to target, then detent. Resistance is separate and acts concurrently except under Fixed. Disabling a higher drive may restore an earlier lower request; configurations are not added together.
Example#
wheel = jolt_control_wheel({speed_motor: {speed: 90, max_torque: 5}});
wheel.set_position_motor({angle: 360, speed: 180, max_torque: 10});
// Speed remains enabled, but active is false.
var speed_state = wheel.get_speed_motor();
// Once target holding is released, speed resumes:
wheel.set_position_motor({enabled: false});Sleeping#
Passive controls, resistance alone, held detents, Fixed, a settled speed:0 brake and reached position/phase targets may sleep. Nonzero speed or torque remains an active task even when stalled; unfinished position travel does too. Getters, identical settings and changes only to paused configuration should not unnecessarily wake the higher owner.