axis_protocol
axis_protocol
Structural protocol that all axis backend implementations must satisfy.
Axis
Bases: Protocol
Structural interface for a single controllable axis.
Both EdconAxis (Modbus/festo-edcon backend) and
FPosBAxis (FPosBAPI backend)
satisfy this protocol structurally — no explicit inheritance required.
All position values are in millimetres (mm). All velocity values are in mm/s.
move
Move the axis to position at velocity.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
position
|
float
|
Target position in mm (absolute or relative depending on
|
required |
velocity
|
float
|
Move speed in mm/s. |
required |
**kwargs
|
Backend-specific options (e.g. |
{}
|
Returns:
| Type | Description |
|---|---|
bool
|
|
Source code in src/applied_motion/backends/axis_protocol.py
home
get_current_axis_position
Return the current axis position in mm.
Returns:
| Type | Description |
|---|---|
float
|
Current position in mm. |
is_homed
Return whether this axis reports a valid homed/reference state.
Returns:
| Type | Description |
|---|---|
bool
|
|
stopped
Return True when the axis is not currently in motion.
Returns:
| Type | Description |
|---|---|
bool
|
|
acknowledge_faults
enable_powerstage
Turn on torque to motor controlling this axis.
Source code in src/applied_motion/backends/axis_protocol.py
disable_powerstage
current_position
current_velocity
jog_task
jog_task(
jog_positive: bool = True,
jog_negative: bool = False,
incremental: bool = False,
duration: float = 0.0,
) -> bool
Jog the axis according to backend-specific jog semantics.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
jog_positive
|
bool
|
When |
True
|
jog_negative
|
bool
|
When |
False
|
incremental
|
bool
|
Backend-specific incremental jog mode flag. |
False
|
duration
|
float
|
Optional jog duration in seconds. A value of |
0.0
|
Returns:
| Type | Description |
|---|---|
bool
|
|
Source code in src/applied_motion/backends/axis_protocol.py
ready_for_motion
Return True when the axis is ready to accept a move command.
Returns:
| Type | Description |
|---|---|
bool
|
|