Control Interface#

The control interface provides real-time command and feedback for robot control. It is returned by the start_* methods of the Robot class.

ActiveControlBase Class#

class pylibfranka.ActiveControlBase#

Bases: pybind11_object

Base class for active robot control providing real-time command interface.

readOnce(self: pylibfranka._pylibfranka.ActiveControlBase) tuple#

Read robot state once.

@return Tuple of (RobotState, Duration) containing the robot state and time since last read operation

writeOnce(*args, **kwargs)#

Overloaded function.

  1. writeOnce(self: pylibfranka._pylibfranka.ActiveControlBase, arg0: franka::Torques) -> None

    Write torque command.

    @param command Torque command

  2. writeOnce(self: pylibfranka._pylibfranka.ActiveControlBase, arg0: franka::JointPositions) -> None

    Write joint position command.

    @param command Joint position command

  3. writeOnce(self: pylibfranka._pylibfranka.ActiveControlBase, arg0: franka::JointVelocities) -> None

    Write joint velocity command.

    @param command Joint velocity command

  4. writeOnce(self: pylibfranka._pylibfranka.ActiveControlBase, arg0: franka::CartesianPose) -> None

    Write Cartesian pose command.

    @param command Cartesian pose command

  5. writeOnce(self: pylibfranka._pylibfranka.ActiveControlBase, arg0: franka::CartesianVelocities) -> None

    Write Cartesian velocity command.

    @param command Cartesian velocity command

Methods#

readOnce#

ActiveControlBase.readOnce()

Read robot state once from the control loop.

Returns:

Tuple of (RobotState, Duration) containing the robot state and time since last read operation

Return type:

tuple(RobotState, Duration)

writeOnce (Torques)#

ActiveControlBase.writeOnce(command: Torques)

Write torque command to the robot.

Parameters:

command (Torques) – Torque command to send

writeOnce (JointPositions)#

ActiveControlBase.writeOnce(command: JointPositions)

Write joint position command to the robot.

Parameters:

command (JointPositions) – Joint position command to send

writeOnce (JointVelocities)#

ActiveControlBase.writeOnce(command: JointVelocities)

Write joint velocity command to the robot.

Parameters:

command (JointVelocities) – Joint velocity command to send

writeOnce (CartesianPose)#

ActiveControlBase.writeOnce(command: CartesianPose)

Write Cartesian pose command to the robot.

Parameters:

command (CartesianPose) – Cartesian pose command to send

writeOnce (CartesianVelocities)#

ActiveControlBase.writeOnce(command: CartesianVelocities)

Write Cartesian velocity command to the robot.

Parameters:

command (CartesianVelocities) – Cartesian velocity command to send

Command Types#

Torques#

class pylibfranka.Torques#

Bases: pybind11_object

Torque control command.

Torque control command for joint-level torque control.

Attributes:

tau_J: array_like

Joint torques [Nm] (7,)

motion_finished: bool

Set to True to finish motion and exit control loop

Constructor:

Torques(tau_J)#

Create torque command.

Parameters:

tau_J (array_like) – Joint torques [Nm] (7,)

property motion_finished#

Set to True to finish motion

property tau_J#

Joint torques [Nm] (7,)

JointPositions#

class pylibfranka.JointPositions#

Bases: pybind11_object

Joint position control command.

Joint position control command.

Attributes:

q: array_like

Joint positions [rad] (7,)

motion_finished: bool

Set to True to finish motion and exit control loop

Constructor:

JointPositions(q)#

Create joint position command.

Parameters:

q (array_like) – Joint positions [rad] (7,)

property motion_finished#

Set to True to finish motion

property q#

Joint positions [rad] (7,)

JointVelocities#

class pylibfranka.JointVelocities#

Bases: pybind11_object

Joint velocity control command.

Joint velocity control command.

Attributes:

dq: array_like

Joint velocities [rad/s] (7,)

motion_finished: bool

Set to True to finish motion and exit control loop

Constructor:

JointVelocities(dq)#

Create joint velocity command.

Parameters:

dq (array_like) – Joint velocities [rad/s] (7,)

property dq#

Joint velocities [rad/s] (7,)

property motion_finished#

Set to True to finish motion

CartesianPose#

class pylibfranka.CartesianPose#

Bases: pybind11_object

Cartesian pose control command.

Cartesian pose control command.

Attributes:

O_T_EE: array_like

End effector pose as homogeneous transformation matrix (16,) in column-major order

motion_finished: bool

Set to True to finish motion and exit control loop

Constructor:

CartesianPose(O_T_EE)#

Create Cartesian pose command.

Parameters:

O_T_EE (array_like) – Homogeneous transformation matrix (16,) in column-major order

property O_T_EE#

End effector pose (16,) column-major

property motion_finished#

Set to True to finish motion

CartesianVelocities#

class pylibfranka.CartesianVelocities#

Bases: pybind11_object

Cartesian velocity control command.

Cartesian velocity control command (twist).

Attributes:

O_dP_EE: array_like

End effector twist [vx, vy, vz, wx, wy, wz] in [m/s, rad/s] (6,)

motion_finished: bool

Set to True to finish motion and exit control loop

Constructor:

CartesianVelocities(O_dP_EE)#

Create Cartesian velocity command.

Parameters:

O_dP_EE (array_like) – End effector twist [vx, vy, vz, wx, wy, wz] in [m/s, rad/s] (6,)

property O_dP_EE#

End effector twist [m/s, rad/s] (6,)

property motion_finished#

Set to True to finish motion

See Also#

  • Robot – Main robot control interface

  • RobotState – Robot state information

  • Model – Dynamics model