MotionController

class ingeniamotion.MotionController

Bases: object

Motion Controller.

servo_name(servo='default')

Get the servo name.

Parameters:

servo (str) – servo alias to reference it. default by default.

Return type:

str

Returns:

The servo name.

get_register_enum(register, servo='default', axis=1)

Get a register enum.

Parameters:
  • register (str) – The register UID.

  • servo (str) – servo alias to reference it. default by default.

  • axis (int) – axis force read errors in target axis. None by default.

Return type:

IntEnum

Returns:

The register enum as an IntEnum.

is_alive(servo='default')

Check if the servo is alive.

Parameters:

servo (str) – servo alias to reference it. default by default.

Return type:

bool

Returns:

True if the servo is alive, False otherwise.

property motion_nodes: mappingproxy[str, MotionNode]

Read only dict of motion nodes indexed by alias.

Return type:

mappingproxy[str, MotionNode]

create_motion_node(alias, servo, network)

Helper to create and register a motion node.

Parameters:
  • alias (str) – alias to reference the motion node.

  • servo (Servo) – servo instance to associate with the motion node.

  • network (Network) – network instance to associate with the motion node.

Return type:

MotionNode

Returns:

The created motion node instance.

remove_motion_node(alias)

Helper to unregister a servo and cleanup its network.

This will remove the servo from the internal registry, remove the servo->network mapping, delete the FSoE master handler for the servo if present, and delete the network entry when no more servos use it.

Parameters:

alias (str) – alias used to reference the servo to remove.

Return type:

None

property servos: mappingproxy[str, Servo]

Mapping of ingenialink.Servo connected indexed by alias.

Return type:

mappingproxy[str, Servo]

Returns:

A mapping of connected servos indexed by alias.

property net: mappingproxy[str, Network]

Dict of ingenialink.Network connected indexed by alias.

Return type:

mappingproxy[str, Network]

register_network(alias, network)

Register a network instance with an alias.

Parameters:
  • alias (str) – alias to reference the network.

  • network (Network) – network instance to register.

Return type:

None

remove_network(network)

Remove a network instance from the registry.

Return type:

None

property servo_net: mappingproxy[str, str]

Get the servo network dictionary.

Return type:

mappingproxy[str, str]

Returns:

The servo network dictionary.

property configuration: Configuration

Instance of Configuration class.

Return type:

Configuration

property motion: Motion

Instance of Motion class.

Return type:

Motion

property capture: Capture

Instance of Capture class.

Return type:

Capture

property communication: Communication

Instance of Communication class.

Return type:

Communication

property tests: DriveTests

Instance of DriveTests class.

Return type:

DriveTests

property errors: Errors

Instance of Errors class.

Return type:

Errors

property info: Information

Instance of Information class.

Return type:

Information

property fsoe: FSoEMaster

Instance of FSoEMaster class.

Return type:

FSoEMaster

property fsoe_is_installed: bool

Indicates if the FSoE Module is available.

Return type:

bool

property io: InputsOutputs

Instance of InputsOutputs class.

Return type:

InputsOutputs