Skip to content

Commit 02a6909

Browse files
author
Tim
committed
your commit message
1 parent fa7874f commit 02a6909

27 files changed

+1642
-71
lines changed

README.md

Lines changed: 63 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,46 @@ A Python client library for interacting with [I2RT](https://i2rt.com/) products,
1111
- Visualization and gravity compensation using MuJoCo physics engine
1212
- Gripper force control mode and auto calibration
1313

14+
## Examples
15+
16+
We are continuously expanding our collection of examples with detailed documentation under [`examples/`](./examples). These examples are designed to help you get started quickly and demonstrate common use cases.
17+
18+
## Available Examples
19+
20+
### [Bimanual Lead Follower](./examples/bimanual_lead_follower/README.md)
21+
Demonstrates coordinated control of two robotic arms in a leader-follower configuration.
22+
23+
### [Record Replay Trajectory](./examples/record_replay_trajectory/README.md)
24+
Shows how to record and replay robotic trajectories for automation and testing.
25+
26+
### [Single Motor Position PD Control](./examples/single_motor_position_pd_control/README.md)
27+
Basic position control implementation using PD controller for single motor operations.
28+
29+
## Contributing
30+
31+
If you have suggestions for new examples or want to contribute your own, feel free to:
32+
- Open an issue to request specific examples
33+
- Submit a pr with your contribution
34+
- Share feedback on existing examples
35+
36+
We welcome community contributions that help others learn and implement robotic solutions!
37+
1438
## Installation
1539

40+
### Install uv from scratch
41+
42+
```
43+
git clone https://github.com/i2rt-robotics/i2rt.git && cd i2rt
44+
curl -LsSf https://astral.sh/uv/install.sh | sh
45+
source $HOME/.local/bin/env
46+
uv venv --python 3.11
47+
source .venv/bin/activate
48+
```
49+
1650
```bash
17-
pip install -e .
51+
sudo apt update
52+
sudo apt install build-essential python3-dev linux-headers-$(uname -r)
53+
uv pip install -e .
1854
```
1955

2056
## Basic CAN Usage
@@ -40,6 +76,11 @@ We have provided a convenience script to reset all CAN devices. Simply run
4076
sh scripts/reset_all_can.sh
4177
```
4278

79+
If you see this output after entering the can reset command, you may need to unplug/replug the usb can device to completely reset the canable.
80+
```bash
81+
RTNETLINK answers: Device or resource busy
82+
```
83+
4384
If you want the CAN interface to be automatically enabled on startup, you can run:
4485
```bash
4586
sudo sh devices/install_devices.sh
@@ -54,14 +95,14 @@ This script installs a udev rule that will automatically bring up all CAN device
5495
## Gripper type
5596

5697
Currently YAM supports Four different grippers:
57-
![YAM supported Grippers](./assets/photos/yam_three_grippers.png)
98+
![YAM supported Grippers](./assets/photos/yam_grippers.png)
5899

59100
| Gripper Name | Description |
60101
|---------------------|-------------|
61102
| `crank_4310` | Zero-linkage crank gripper, optimized for minimizing gripper width. |
62103
| `linear_3507` | Linear gripper with smaller DM3507 motor. Lightweight, but requires calibration or starting with the gripper in the closed configuration. |
63104
| `linear_4310` | Linear gripper with the standard DM4310 motor (not shown on photo above). Slightly heavier but can provide a bit more gripping force. |
64-
| `yam_teaching_handle`| Used for the leader arm setup. Includes a trigger to control the gripper and two customizable buttons that can be mapped to different functions. |
105+
| `yam_teaching_handle`| Used for the leader arm setup. Includes a trigger to control the gripper and two customizable buttons that can be mapped to different functions. For more information related to the teaching handle, please see [yam_handle_readme.md](doc/yam_handle_readme.md)|
65106

66107
The linear gripper requires an additional calibration step because its motor must rotate more than 2π radians to complete the full stroke.
67108

@@ -97,9 +138,9 @@ To launch the follower robot run.
97138
python scripts/minimum_gello.py --gripper $YOUR_FOLLOWER_ARM_GRIPPER --mode follower
98139
```
99140

100-
To launch the robot mujoco visualizer run
141+
To launch the robot with mujoco visualizer run
101142
```bash
102-
python scripts/minimum_gello.py --mode visualizer
143+
python scripts/minimum_gello.py --mode visualizer_local
103144
```
104145

105146
---
@@ -156,6 +197,7 @@ However, we understand that this feature may not always be desirable, especially
156197
To remove the timeout feature, run the following command.
157198
```bash
158199
python i2rt/motor_config_tool/set_timeout.py --channel can0
200+
python i2rt/motor_config_tool/set_timeout.py --channel can0
159201
```
160202

161203
To set the timeout feature, run the following command.
@@ -187,8 +229,23 @@ robot = get_yam_robot(channel="can0", zero_gravity_mode=False)
187229

188230
In this mode, the current joint positions (`qpos`) are used as the PD target, keeping the arm stable in its initial state.
189231

232+
One important way to reduce the risk of the arm going out of control is to avoid entering zero-gravity mode.
233+
234+
By default, the arm initializes in zero-gravity mode. As mentioned earlier, if the arm does not have a timeout but the gravity compensation loop fails, the motor controller will continue applying a constant torque. This can lead to unexpected and potentially unsafe behavior.
235+
236+
To prevent this, you should always set a PD target. With a PD target, the motor controller ensures the arm reaches a stable state rather than drifting under uncontrolled torque.
237+
238+
You can disable the default zero-gravity initialization like this:
239+
```python
240+
robot = get_yam_robot(channel="can0", zero_gravity_mode=False)
241+
```
242+
243+
In this mode, the current joint positions (`qpos`) are used as the PD target, keeping the arm stable in its initial state.
244+
190245
## Flow Base Usage
191246

247+
For unboxing instructions and hardware setup details, please refer to the [FlowBase README](./i2rt/flow_base/README.md).
248+
192249
### Running the demo
193250
You can control your flow base using a game controller.
194251
To run the joystick demo, run the following command.
@@ -212,6 +269,7 @@ while time.time() - start_time < 1:
212269
vehicle.set_target_velocity(user_cmd, frame="local")
213270
```
214271

272+
215273
## Contributing
216274
We welcome contributions! Please make a PR.
217275

assets/photos/yam_grippers.png

967 KB
Loading
-972 KB
Binary file not shown.

devices/FlowBase.desktop

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
Type=Application
33
Name=FlowBase
44
Comment=Run my Python program
5-
Exec=lxterminal -e "bash -c '/usr/bin/python3 /home/i2rt/i2rt/i2rt/flow_base/flow_base_controller.py --channel can0 --game_pad shanwan; echo; echo \"Process finished. Press Enter to close...\"; read'"
5+
Exec=lxterminal -e "bash -c '/usr/bin/python3 /home/i2rt/i2rt/i2rt/flow_base/flow_base_controller.py --channel can0; echo; echo \"Process finished. Press Enter to close...\"; read'"
66
Icon=/home/i2rt/Documents/base_icon.png
77
Terminal=true
88
Categories=Utility;

0 commit comments

Comments
 (0)