Class Driver

Inheritance Relationships

Derived Types

Class Documentation

class Driver

Subclassed by robotiq_driver::DefaultDriver, robotiq_driver::FakeDriver

Public Types

enum class ActivationStatus

Values:

enumerator RESET
enumerator ACTIVE
enum class ActionStatus

Values:

enumerator STOPPED
enumerator MOVING
enum class GripperStatus

Values:

enumerator RESET
enumerator IN_PROGRESS
enumerator COMPLETED
enum class ObjectDetectionStatus

Values:

enumerator MOVING
enumerator OBJECT_DETECTED_OPENING
enumerator OBJECT_DETECTED_CLOSING
enumerator AT_REQUESTED_POSITION

Public Functions

virtual void set_slave_address(uint8_t slave_address) = 0
virtual bool connect() = 0

Connect to the gripper serial connection.

virtual void disconnect() = 0

Disconnect from the gripper serial connection.

virtual void activate() = 0

Activates the gripper.

Throws:

serial::IOException – on failure to successfully communicate with gripper port

virtual void deactivate() = 0

Deactivates the gripper.

Throws:

serial::IOException – on failure to successfully communicate with gripper port

virtual void set_gripper_position(uint8_t pos) = 0

Commands the gripper to move to the desired position.

Parameters:

pos – A value between 0x00 (fully open) and 0xFF (fully closed).

virtual uint8_t get_gripper_position() = 0

Return the current position of the gripper.

Throws:

serial::IOException – on failure to successfully communicate with gripper port

Returns:

uint8_t A value between 0x00 (fully open) and 0xFF (fully closed).

virtual bool gripper_is_moving() = 0

Returns true if the gripper is currently moving, false otherwise.

virtual void set_speed(uint8_t speed) = 0

Set the speed of the gripper.

Parameters:

speed – A value between 0x00 (stopped) and 0xFF (full speed).

virtual void set_force(uint8_t force) = 0

Set how forcefully the gripper opens or closes.

Parameters:

force – A value between 0x00 (no force) or 0xFF (maximum force).