Skip to content

Commit

Permalink
Added plate crane set speed function, for real this time
Browse files Browse the repository at this point in the history
  • Loading branch information
caseystone committed Jun 25, 2024
1 parent 2820074 commit 7f9366f
Showing 1 changed file with 22 additions and 12 deletions.
34 changes: 22 additions & 12 deletions src/platecrane_driver/platecrane_driver.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,16 @@
import re
import time

from platecrane_driver.resource_defs import locations, plate_definitions
from platecrane_driver.resource_types import PlateResource
from platecrane_driver.serial_port import (
SerialPort, # use when running through WEI REST clients
)

# from serial_port import SerialPort # use when running through the driver
# from resource_defs import locations, plate_definitions
# from resource_types import PlateResource
# from serial_port import SerialPort # use when running through the driver
# from resource_defs import locations, plate_definitions
# from resource_types import PlateResource
# from platecrane_driver.resource_defs import locations, plate_definitions
# from platecrane_driver.resource_types import PlateResource
# from platecrane_driver.serial_port import (
# SerialPort, # use when running through WEI REST clients
# )

from serial_port import SerialPort # use when running through the driver
from resource_defs import locations, plate_definitions
from resource_types import PlateResource


"""
# TODOs:
Expand Down Expand Up @@ -93,6 +91,18 @@ def lock_joints(self):
command = "limp FALSE\r\n"
self.__serial_port.send_command(command)

def set_speed(self, speed: int):
"""Sets the speed of the plate crane arm.
Args:
speed (int): (units = % of full speed) Speed at which to move the PlateCrane EX. Appies to all axes
Returns:
None
"""
command = "SPEED " + str(speed)
self.__serial_port.send_command(command)

def get_location_list(self):
"""Displays all location information stored in the Plate Crane EX robot's memory"""

Expand Down

0 comments on commit 7f9366f

Please sign in to comment.