Add real robot devices and scripts to control real robot (#288)
Co-authored-by: Simon Alibert <alibert.sim@gmail.com>
This commit is contained in:
19
lerobot/common/robot_devices/utils.py
Normal file
19
lerobot/common/robot_devices/utils.py
Normal file
@@ -0,0 +1,19 @@
|
||||
class RobotDeviceNotConnectedError(Exception):
|
||||
"""Exception raised when the robot device is not connected."""
|
||||
|
||||
def __init__(
|
||||
self, message="This robot device is not connected. Try calling `robot_device.connect()` first."
|
||||
):
|
||||
self.message = message
|
||||
super().__init__(self.message)
|
||||
|
||||
|
||||
class RobotDeviceAlreadyConnectedError(Exception):
|
||||
"""Exception raised when the robot device is already connected."""
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
message="This robot device is already connected. Try not calling `robot_device.connect()` twice.",
|
||||
):
|
||||
self.message = message
|
||||
super().__init__(self.message)
|
||||
Reference in New Issue
Block a user