API Reference v9.2.0

Ge1xGripperclass

Module: ZaberMotionProduct

Class representing a gripper in the GE1x series.

The following example illustrates how you can obtain an instance of this type:

import ZaberMotionProduct

let ge1xGripper = try await Ge1xGripper.openConnection(portName: "COM3")
Related Guides:

Constants

c

defaultDeviceAddress

Ge1xGripper.defaultDeviceAddress
Int The default device address for a gripper in the GE1x series.
Value
1

Properties

p

connectionId

readonly
ge1xGripper.connectionId
Int The identifier for the connection.

Methods

m

activatePreset()

asyncthrows
try await ge1xGripper.activatePreset(presetNumber, waitUntilIdle = true)
Activates a preset, causing the gripper to move to the preset position using the preset force and speed.
Arguments
NameTypeDescription
presetNumberIntThe preset number to activate, from 1 to 4.
waitUntilIdleBoolWait until the move has completed before returning.
m

calibrate()

asyncthrows
try await ge1xGripper.calibrate(saveToFlash = true)
Performs a calibration of the travel range by moving to the fully open and fully closed positions.
Arguments
NameTypeDescription
saveToFlashBoolSave the calibration results to flash memory so they are retained on power cycle.
m

clearError()

asyncthrows
try await ge1xGripper.clearError()
Clears the current error of the gripper.
m

close()

asyncthrows
try await ge1xGripper.close()
Closes the connection to the gripper.
m

driverDisable()

asyncthrows
try await ge1xGripper.driverDisable()
Disables the gripper driver.
m

driverEnable()

asyncthrows
try await ge1xGripper.driverEnable()
Enables the gripper driver.
m

getCurrent()

asyncthrows
try await ge1xGripper.getCurrent()
Gets the current current of the gripper.
Return Value
Int The current current of the gripper in milliamps.
m

getError()

asyncthrows
try await ge1xGripper.getError()
Gets the current error of the gripper.
Return Value
Ge1xGripperError The current error of the gripper.
m

getIoInputPresetNumber()

asyncthrows
try await ge1xGripper.getIoInputPresetNumber()
Gets the preset number currently activated by the gripper IO input.
Return Value
Int The current preset number activated by the gripper IO input.
m

getPosition()

asyncthrows
try await ge1xGripper.getPosition()
Gets the current position of the gripper.
Return Value
Double The current position of the gripper as a percentage, where 0 is closed and 100 is open.
m

getState()

asyncthrows
try await ge1xGripper.getState()
Gets the current state of the gripper.
Return Value
Ge1xGripperState The current state of the gripper.
m

home()

asyncthrows
try await ge1xGripper.home(waitUntilIdle = true)
Homes gripper by moving it to its homing position.
Arguments
NameTypeDescription
waitUntilIdleBoolWait until homing has completed before returning.
m

isHomed()

asyncthrows
try await ge1xGripper.isHomed()
Checks if the gripper has been homed.
Return Value
Bool True if the gripper is homed, false otherwise.
m

move()

asyncthrows
try await ge1xGripper.move(position, waitUntilIdle = true)
Moves the gripper to a specified position.
Arguments
NameTypeDescription
positionDoubleThe target position for the gripper as a percentage, where 0 is closed and 100 is open.
waitUntilIdleBoolWait until the move has completed before returning.
m

moveClose()

asyncthrows
try await ge1xGripper.moveClose(waitUntilIdle = true)
Moves the gripper to the closed position.
Arguments
NameTypeDescription
waitUntilIdleBoolWait until the move has completed before returning.
m

moveOpen()

asyncthrows
try await ge1xGripper.moveOpen(waitUntilIdle = true)
Moves the gripper to the open position.
Arguments
NameTypeDescription
waitUntilIdleBoolWait until the move has completed before returning.
s

openConnection()

asyncthrows
try await Ge1xGripper.openConnection(portName, deviceAddress = Ge1xGripper.defaultDeviceAddress, timeout = 500)
Opens a serial connection to a gripper.
Arguments
NameTypeDescription
portNameStringThe name of the serial port to connect to.
deviceAddressIntThe address of the gripper to connect to.
timeoutIntThe timeout in milliseconds for any request sent using this connection.
Return Value
Ge1xGripper A Ge1xGripper instance representing the connection to the gripper.
m

readRegister()

asyncthrows
try await ge1xGripper.readRegister(registerAddress)
Reads a single register value from the gripper.
Arguments
NameTypeDescription
registerAddressIntThe address of the register to read.
Return Value
Int The data at the specified register address.
m

setAutoHome()

asyncthrows
try await ge1xGripper.setAutoHome(enabled, saveToFlash = true)
Enables or disables automatic homing on power up.
Arguments
NameTypeDescription
enabledBoolTrue to enable automatic homing on power up, false to disable.
saveToFlashBoolSave the auto home setting to flash memory so it is retained on power cycle.
m

setForce()

asyncthrows
try await ge1xGripper.setForce(force)
Sets the gripping force of the gripper.
Arguments
NameTypeDescription
forceIntThe gripping force as a percentage from 20 to 100.
m

setHomeDirection()

asyncthrows
try await ge1xGripper.setHomeDirection(direction, saveToFlash = true)
Sets the home direction for the gripper.
Arguments
NameTypeDescription
directionGe1xGripperDirectionThe home direction to set.
saveToFlashBoolSave the home direction setting to flash memory so it is retained on power cycle.
m

setIoEnabled()

asyncthrows
try await ge1xGripper.setIoEnabled(enabled, saveToFlash = true)
Enables or disables IO control for the gripper. When enabled, the gripper will not move to a preset position until the IO input changes.
Arguments
NameTypeDescription
enabledBoolTrue to enable IO control, false to disable.
saveToFlashBoolSave the IO enabled setting to flash memory so it is retained on power cycle.
m

setIoInputFilter()

asyncthrows
try await ge1xGripper.setIoInputFilter(duration, saveToFlash = true)
Sets the debounce filter time for the gripper IO input to suppress noise.
Arguments
NameTypeDescription
durationIntThe IO input filter time in milliseconds.
saveToFlashBoolSave the IO input filter setting to flash memory so it is retained on power cycle.
m

setPreset()

asyncthrows
try await ge1xGripper.setPreset(presetNumber, position, force = 100, speed = 100, saveToFlash = true)
Saves a position, force, and speed as a preset that can be enabled using I/O or the activatePreset() method. Note that presets are only activated by I/O when the I/O input changes to that preset number.
Arguments
NameTypeDescription
presetNumberIntThe preset number to save the preset to, from 1 to 4.
positionDoubleThe target position for the preset as a percentage, where 0 is closed and 100 is open.
forceIntThe gripping force for the preset as a percentage from 20 to 100.
speedIntThe maximum speed for the preset as a percentage from 1 to 100.
saveToFlashBoolSave the preset to flash memory so it is retained on power cycle.
m

setSpeed()

asyncthrows
try await ge1xGripper.setSpeed(speed)
Sets the maximum speed of the gripper.
Arguments
NameTypeDescription
speedIntThe maximum speed as a percentage from 1 to 100.
m

stop()

asyncthrows
try await ge1xGripper.stop(waitUntilIdle = true)
Stops the gripper from moving.
Arguments
NameTypeDescription
waitUntilIdleBoolWait until the gripper has stopped before returning.
m

waitUntilIdle()

asyncthrows
try await ge1xGripper.waitUntilIdle()
Waits until the gripper has stopped moving.
m

writeRegister()

asyncthrows
try await ge1xGripper.writeRegister(registerAddress, data)
Writes a single register value to the gripper.
Arguments
NameTypeDescription
registerAddressIntThe address of the register to write.
dataIntThe data to write to the specified register address.