LeRobot documentation

OMX

Hugging Face's logo
Join the Hugging Face community

and get access to the augmented documentation experience

to get started

OMX

OMX

订购并组装部件

首先,按照官方组装指南组装 OMX 硬件。

OMX 组装指南:https://ai.robotis.com/omx/assembly_guide_omx.html

OMX 机器人出厂前已预配置完成。电机 ID、通信参数和关节偏移量均已设置,因此在使用 LeRobot 之前无需进行额外的电机设置或校准。

安装 LeRobot 🤗

要安装 LeRobot,请遵循我们的安装指南

除了这些说明之外,您还需要安装 Dynamixel 电机支持:

pip install -e ".[dynamixel]"

连接机器人

要查找每个总线舵机适配器的端口,请运行此脚本:

lerobot-find-port

This command runs and when prompted, disconnect the USB cable from either the leader or follower arm and press Enter. The output will show ‘The port of this MotorsBus is [port]’. This identifies the port for the disconnected arm. Repeat for the other arm to identify both ports.

Mac
Linux

macOS 上的示例输出:

Finding all available ports for the MotorBus.
['/dev/tty.usbmodem575E0032081', '/dev/tty.usbmodem575E0031751']
Remove the USB cable from your MotorsBus and press Enter when done.

[...Disconnect corresponding leader or follower arm and press Enter...]

The port of this MotorsBus is /dev/tty.usbmodem575E0032081
Reconnect the USB cable.

找到的端口为:/dev/tty.usbmodem575E0032081,对应您的 leader 或 follower 机械臂。

远程操作

在确定正确的端口后,您可以直接使用主臂直接遥操作从臂。

Mac
Linux

无相机远程操作

lerobot-teleoperate \
  --robot.type=omx_follower \
  --robot.port=<your_follower_port> \
  --robot.id=omx_follower_arm \
  --teleop.type=omx_leader \
  --teleop.port=<your_leader_port> \
  --teleop.id=omx_leader_arm

在遥操作过程中,主臂的动作会实时镜像到从臂上。OMX 已预先配置好,无需任何校准步骤即可立即开始遥操作。

使用相机进行远程操作

你还可以通过为从动臂提供相机配置,在遥操作期间启用相机输入。

lerobot-teleoperate \
  --robot.type=omx_follower \
  --robot.port=<your_follower_port> \
  --robot.id=omx_follower_arm \
  --robot.cameras="{front: {type: opencv, index_or_path: '/dev/video0', width: 640, height: 480, fps: 30}}" \
  --teleop.type=omx_leader \
  --teleop.port=<your_leader_port> \
  --teleop.id=omx_leader_arm \
  --display_data=true

启用摄像头后,摄像头流会实时显示并与机器人状态保持同步。此设置适用于视觉监控,并且可以稍后复用于演示录制和模仿学习。

恭喜 🎉,你的机器人已准备好自主学习任务。

如果您有任何问题或需要帮助,请在 Discord 上联系我们。

Update on GitHub