pylabrobot.brooks.precise_flex.PreciseFlex#

class pylabrobot.brooks.precise_flex.PreciseFlex(host: str, gripper_length: float, gripper_z_offset: float, closed_gripper_position: float, port: int = 10100, timeout: int = 20, is_dual_gripper: bool = False, has_rail: bool = False, read_kinematics_from_device: bool = True, recover_out_of_range: bool = True, parking_position: Dict[int, float] | None = None)#

Bases: object

Driver for PreciseFlex robotic arms.

Owns the Socket I/O connection and device-level operations (power, attach, home, response mode). Exposes send_command as the generic wire method.

Documentation and error codes available at https://www2.brooksautomation.com/#Root/Welcome.htm

Attributes

Methods

__init__(host, gripper_length, ...[, port, ...])

are_grippers_closed()

(Dual Gripper Only) Tests if each gripper is fully closed by checking the end-of-travel sensors.

attach([attach_state])

Attach or release the robot, or get attachment state.

change_config([grip_mode])

Change Robot configuration from Righty to Lefty or vice versa using customizable locations.

change_config2([grip_mode])

Change Robot configuration from Righty to Lefty or vice versa using algorithm.

dest_c([arg1])

Get the destination or current Cartesian location of the robot.

dest_j([arg1])

Get the destination or current joint location of the robot.

detach()

Detach the robot.

drop_at_joint_position(position, resource_width)

Drop at the specified joint position.

drop_at_location(location, direction, ...[, ...])

Drop at the specified Cartesian location.

halt()

Stops the current robot immediately but leaves power on.

here_c(location_index)

Record the current position of the selected robot into the specified Location as Cartesian.

here_j(location_index)

Record the current position of the selected robot into the specified Location as angles.

home()

Home the robot associated with this thread.

home_all()

Home all robots.

is_gripper_closed()

(Single Gripper Only) Tests if the gripper is fully closed by checking the end-of-travel sensor.

move_gripper(width[, force_sensing])

Move the PreciseFlex gripper jaws.

move_rail(rail_position)

Move the rail to the specified position.

move_through_cartesian_poses(poses[, ...])

Move through a sequence of Cartesian poses using one planned IK route.

move_to_joint_position(position[, speed_pct])

Move the arm to the specified joint position.

move_to_location(location, direction[, ...])

Move the arm to the specified Cartesian location.

nop()

No operation command.

park()

Move to self.parking_position; defaults at setup, reassignable at runtime.

pick_up_at_joint_position(position, ...[, ...])

Pick up at the specified joint position.

pick_up_at_location(location, direction, ...)

Pick up at the specified Cartesian location.

power_off_robot()

Power off the robot.

power_on_robot()

Power on the robot.

recover_axes_within_limits([speed_pct, ...])

Bring out-of-range axes back inside their soft limits, one axis at a time.

recover_from_fault()

Recover after a collision / fault that stopped the arm and dropped power, leaving it usable.

release_brake(axis)

Release the axis brake.

request_axis_count()

Number of servoed axes.

request_axis_mask()

Capability/option bit field (rail, dual gripper, ...).

request_base()

Get the robot base offset.

request_controller_model()

request_controller_serial()

request_extra_axis_count()

Number of non-servoed (extra) axes.

request_gpl_version()

Controller firmware/runtime version (distinct from request_version, the TCS app).

request_gripper_pose()

Get the current pose using our kinematics model (no firmware wherec).

request_hardware_version()

request_joint_limits([hard])

Per-axis travel limits as {Axis: (min, max)}.

request_joint_position()

Get the current joint position of the arm.

request_kinematic_parameters()

Build PF400Params from the controller's stored geometry.

request_link_lengths()

(l1, l2) SCARA link lengths in mm: shoulder->elbow, elbow->wrist.

request_manufacturer()

request_max_acceleration_percent()

Global cap on the acceleration percentage (one value, applies to all joints).

request_max_deceleration_percent()

Global cap on the deceleration percentage (one value, applies to all joints).

request_max_speed_percent()

Global cap on the speed percentage (one value, applies to all joints).

request_mode()

Get the current response mode.

request_monitor_speed()

Get the global system (monitor) speed.

request_motion_profile_values(profile)

Get the current motion profile values for the specified profile index on the PreciseFlex robot.

request_parameter(data_id[, unit_number, ...])

Get the value of a numeric parameter database item.

request_payload()

Get the payload percent value for the current robot.

request_power_state()

Get the current robot power state.

request_profile_acceleration(profile_index)

Get the acceleration property of the specified profile.

request_profile_acceleration_ramp(profile_index)

Get the acceleration ramp property of the specified profile.

request_profile_deceleration(profile_index)

Get the deceleration property of the specified profile.

request_profile_deceleration_ramp(profile_index)

Get the deceleration ramp property of the specified profile.

request_profile_in_range(profile_index)

Get the InRange property of the specified profile.

request_profile_speed(profile_index)

Get the speed property of the specified profile.

request_profile_speed2(profile_index)

Get the speed2 property of the specified profile.

request_profile_straight(profile_index)

Get the Straight property of the specified profile.

request_reference_acceleration()

Per-axis rated acceleration at 100%.

request_reference_cartesian_acceleration()

Rated Cartesian (translational) acceleration at 100%, in mm/s^2.

request_reference_cartesian_speed()

Rated Cartesian (translational) speed at 100%, in mm/s.

request_reference_speed()

Per-axis rated speed at 100%; J1/J5 in mm/s, J2-J4 in deg/s.

request_robot_name()

request_robot_type()

Built-in kinematic model id (PF400 = 12).

request_selected_robot()

Get the number of the currently selected robot.

request_signal(signal_number)

Get the value of the specified digital input or output signal.

request_state()

Return state of motion.

request_system_state()

Controller power/system-state word (the sysState command, == DataID 234).

request_tool_length()

Wrist->TCP distance in mm (z of the tool-offset transform).

request_tool_transformation_values()

Get the current tool transformation values.

request_version()

Get the current version of TCS and any installed plug-ins.

reset(robot_number)

Reset the threads associated with the specified robot.

select_robot(robot_number)

Change the robot associated with this communications link.

send_command(command)

set_axis_parameter(data_id, axis, value[, ...])

Change one joint's element of a per-axis parameter array (pc).

set_base(x_offset, y_offset, z_offset, ...)

Set the robot base offset.

set_brake(axis)

Set the axis brake.

set_monitor_speed(speed_pct)

Set the global system (monitor) speed.

set_motion_profile_values(profile, ...)

Set motion profile values for the specified profile index on the PreciseFlex robot.

set_parameter(data_id, value[, unit_number, ...])

Change a value in the controller's parameter database.

set_payload(payload_pct)

Set the payload percent of maximum for the currently selected or attached robot.

set_power(enable[, timeout])

Enable or disable robot high power.

set_profile_acceleration(profile_index, ...)

Set the acceleration property of the specified profile.

set_profile_acceleration_ramp(profile_index, ...)

Set the acceleration ramp property of the specified profile.

set_profile_deceleration(profile_index, ...)

Set the deceleration property of the specified profile.

set_profile_deceleration_ramp(profile_index, ...)

Set the deceleration ramp property of the specified profile.

set_profile_in_range(profile_index, ...)

Set the InRange property of the specified profile.

set_profile_speed(profile_index, speed_pct)

Set the speed property of the specified profile.

set_profile_speed2(profile_index, speed2_pct)

Set the speed2 property of the specified profile.

set_profile_straight(profile_index, ...)

Set the Straight property of the specified profile.

set_response_mode(mode)

Set the response mode.

set_signal(signal_number, value)

Set the specified digital input or output signal.

setup([skip_home])

Initialize the PreciseFlex driver.

start_freedrive_mode([free_axes])

Enter freedrive mode, allowing manual movement of the specified joints.

stop()

Stop the PreciseFlex driver.

stop_freedrive_mode()

Exit freedrive mode for all axes.

zero_torque(enable[, axis_mask])

Sets or clears zero torque mode for the selected robot.

Parameters:
  • host (str)

  • gripper_length (float)

  • gripper_z_offset (float)

  • closed_gripper_position (float)

  • port (int)

  • timeout (int)

  • is_dual_gripper (bool)

  • has_rail (bool)

  • read_kinematics_from_device (bool)

  • recover_out_of_range (bool)

  • parking_position (Dict[int, float] | None)