-
Notifications
You must be signed in to change notification settings - Fork 0
Lerobot integration bounty #1037
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: dev
Are you sure you want to change the base?
Conversation
Greptile Summary
Important Files Changed
Confidence score: 2/5
Sequence DiagramsequenceDiagram
participant User
participant SO101Driver
participant BaseManipulatorDriver
participant SDK as SO101SDKWrapper
participant FeetechBus as FeetechMotorsBus
participant LerobotKin as LerobotKinematics
participant Motors as STS3215Motors
User->>SO101Driver: "set_joint_positions(positions)"
SO101Driver->>BaseManipulatorDriver: "_process_command(position_cmd)"
BaseManipulatorDriver->>SDK: "set_joint_positions(positions)"
SDK->>SDK: "apply joint offsets"
SDK->>SDK: "convert radians to degrees"
SDK->>FeetechBus: "sync_write('Goal_Position', cmd)"
FeetechBus->>Motors: "send position commands"
Motors-->>FeetechBus: "acknowledge"
FeetechBus-->>SDK: "command sent"
SDK-->>BaseManipulatorDriver: "success"
BaseManipulatorDriver-->>SO101Driver: "command processed"
SO101Driver-->>User: "movement initiated"
loop "State Feedback (100Hz)"
BaseManipulatorDriver->>SDK: "get_joint_positions()"
SDK->>FeetechBus: "sync_read('Present_Position')"
FeetechBus->>Motors: "read positions"
Motors-->>FeetechBus: "return positions"
FeetechBus-->>SDK: "joint positions"
SDK->>SDK: "apply joint offsets"
SDK-->>BaseManipulatorDriver: "joint positions"
BaseManipulatorDriver->>BaseManipulatorDriver: "publish joint_state"
end
User->>SO101Driver: "set_cartesian_position(pose)"
SO101Driver->>SDK: "set_cartesian_position(pose)"
SDK->>LerobotKinematics: "ik(current_joints, target_pos, target_quat)"
LerobotKinematics->>LerobotKinematics: "iterative jacobian-based IK"
LerobotKinematics-->>SDK: "joint_solution"
SDK->>SDK: "convert to degrees"
SDK->>FeetechBus: "sync_write('Goal_Position', joint_cmd)"
FeetechBus->>Motors: "send joint commands"
Motors-->>SDK: "cartesian motion executed"
SDK-->>SO101Driver: "success"
SO101Driver-->>User: "cartesian movement complete"
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Additional Comments (1)
-
dimos/hardware/manipulators/so101/urdf/assets/motor_holder_so101_base_v1.stl, line 1 (link)logic: STL file appears to be empty or corrupted - no binary mesh data is present. This will cause URDF loading failures when the robot model is instantiated.
43 files reviewed, 9 comments
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Additional Comments (8)
-
dimos/hardware/manipulators/so101/urdf/assets/motor_holder_so101_wrist_v1.stl, line 1 (link)logic: Empty STL file will cause robot visualization and collision detection failures. STL files must contain valid 3D mesh data for URDF parsing and physics simulation to work correctly.
-
dimos/hardware/manipulators/so101/urdf/assets/motor_holder_so101_base_v1.stl, line 1 (link)logic: Empty STL file will cause robot visualization and collision detection failures. STL files must contain valid 3D mesh data for URDF models to function properly. Was this file supposed to contain 3D mesh data, or is there a separate process to generate it?
-
dimos/hardware/manipulators/so101/urdf/assets/base_motor_holder_so101_v1.stl, line 1 (link)logic: Empty STL file will cause robot visualization and collision detection failures. STL files must contain binary mesh data for the base motor holder component.
-
dimos/hardware/manipulators/so101/urdf/assets/wrist_roll_pitch_so101_v2.stl, line 1 (link)logic: Empty STL file will cause visualization and collision detection failures when robot model is loaded. STL files must contain valid mesh data with vertices and triangular faces.
-
dimos/hardware/manipulators/so101/urdf/assets/upper_arm_so101_v1.stl, line 1 (link)logic: Empty STL file will break robot visualization and collision detection
-
dimos/hardware/manipulators/so101/urdf/assets/moving_jaw_so101_v1.stl, line 1 (link)logic: Empty STL file will cause robot visualization and collision detection to fail completely. The gripper jaw geometry is essential for URDF loading and physics simulation.
-
dimos/hardware/manipulators/so101/urdf/assets/under_arm_so101_v1.stl, line 1 (link)logic: Empty STL file will cause robot visualization and collision detection to fail. STL files must contain binary 3D mesh data for URDF models to render properly in RViz, Gazebo, or other robotics simulators.
-
dimos/hardware/manipulators/so101/urdf/assets/wrist_roll_follower_so101_v1.stl, line 1 (link)logic: Empty STL file will cause robot visualization and simulation failures. STL files must contain valid 3D mesh data for URDF parsers and robotics frameworks to function properly.
35 files reviewed, 20 comments
| if self._last_velocity_time > 0: | ||
| dt = current_time - self._last_velocity_time | ||
| else: | ||
| dt = 1.0 / self.control_rate # Use nominal period for first command |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
logic: Control rate accessed without validation - could cause division by zero if not set
| <default class="sts3215"> | ||
| <geom contype="0" conaffinity="0"/> | ||
| <joint damping="0.60" frictionloss="0.052" armature="0.028"/> | ||
| <!-- For lerobot this are not exactly the motor params as the Kp and Kd not map 1-to-1 thus motor idendification with lerobot Kp=16 and Kd=32 should actually be done --> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
syntax: 'idendification' should be 'identification'
| <!-- For lerobot this are not exactly the motor params as the Kp and Kd not map 1-to-1 thus motor idendification with lerobot Kp=16 and Kd=32 should actually be done --> | |
| <!-- For lerobot these are not exactly the motor params as the Kp and Kd not map 1-to-1 thus motor identification with lerobot Kp=16 and Kd=32 should actually be done --> |
|
|
||
| <!-- Gripper frame (dummy link + fixed joint) --> | ||
| <link name="gripper_frame_link"> | ||
| <origin xyz="0 0 0" rpy="0 -0 0"/> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
style: Redundant origin tag inside link definition - URDF links don't need origin tags at the link level, only within visual/collision/inertial elements
| <origin xyz="0 0 0" rpy="0 -0 0"/> | |
| <link name="gripper_frame_link"> | |
| <inertial> | |
| <origin xyz="0 0 0" rpy="0 0 0"/> | |
| <mass value="1e-9"/> | |
| <inertia ixx="0" ixy="0" ixz="0" iyy="0" iyz="0" izz="0"/> | |
| </inertial> | |
| </link> |
| <origin xyz="-0.0079 -0.000218121 -0.0981274" rpy="0 3.14159 0"/> | ||
| <parent link="gripper_link"/> | ||
| <child link="gripper_frame_link"/> | ||
| <axis xyz="0 0 0"/> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
style: Axis specification unnecessary for fixed joints - fixed joints don't rotate so axis is ignored
Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!
| <link name="gripper_frame_link"> | ||
| <origin xyz="0 0 0" rpy="0 -0 0"/> | ||
| <inertial> | ||
| <origin xyz="0 0 0" rpy="0 0 0"/> | ||
| <mass value="1e-9"/> | ||
| <inertia ixx="0" ixy="0" ixz="0" iyy="0" iyz="0" izz="0"/> | ||
| </inertial> | ||
| </link> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
syntax: Gripper frame link has origin tag outside inertial block - this should be moved inside inertial or removed entirely
| <link name="gripper_frame_link"> | |
| <origin xyz="0 0 0" rpy="0 -0 0"/> | |
| <inertial> | |
| <origin xyz="0 0 0" rpy="0 0 0"/> | |
| <mass value="1e-9"/> | |
| <inertia ixx="0" ixy="0" ixz="0" iyy="0" iyz="0" izz="0"/> | |
| </inertial> | |
| </link> | |
| <link name="gripper_frame_link"> | |
| <inertial> | |
| <origin xyz="0 0 0" rpy="0 0 0"/> | |
| <mass value="1e-9"/> | |
| <inertia ixx="0" ixy="0" ixz="0" iyy="0" iyz="0" izz="0"/> | |
| </inertial> | |
| </link> |
lerobot hardware module