Action Graph for swerve drive robot #482
Replies: 4 comments 6 replies
-
|
Can you give more details on what specifically you plan on doing? do you want to implement a swerve drive controller in sim, and send a cmd_vel, and let the controller resolve your velocity, or will you send the direct joint action commands for the 4 swerve and 4 drive joints? |
Beta Was this translation helpful? Give feedback.
-
|
Good question — you’re on the right track. You can indeed define a custom OmniGraph node with a .ogn plus a corresponding Python implementation, and placing them alongside existing controller nodes (like OgnHolonomicController) inside an extension is a valid pattern. The key piece you’re missing is that OmniGraph discovers nodes through extensions, so the files need to live in an enabled extension that’s on Isaac Sim’s extension search path, not just as loose files. There are two common workflows:
Once your extension is enabled, your OgnSwerveDriveController node should appear in the Action Graph “Add Node” menu under the extension’s namespace, and you can wire it similarly to the Holonomic Controller example. If it doesn’t show up, double‑check the language field and uiName in the .ogn, the Python class name, and that you don’t have syntax errors in the node implementation. |
Beta Was this translation helpful? Give feedback.
-
|
@ShauryaJain03 — the main reason the action graph “is not working” is a mismatch between your Swerve node’s outputs and what the Articulation Controller expects, not a bug in your .py/.ogn logic. Your OgnSwerveDriveController node has two outputs:
The Articulation Controller node has a single position input and a single velocity input, each meant for all commanded joints. Per the Articulation Controller usage guidelines:
For a 4‑wheel swerve (8 DOFs: 4 steer + 4 drive), that means you must feed: positionCommand — one array of length 8 (steer angles in the steer-joint slots, in the same order as your robot’s joints) |
Beta Was this translation helpful? Give feedback.
-
|
Closing as resolved — the root cause (output array shape mismatch between the custom swerve node and Articulation Controller) was identified above. To summarize: merge your 4-element steeringAngleCommand and driveVelocityCommand into single 8-element positionCommand/velocityCommand arrays matching your robot's joint order. Feel free to reopen or start a new discussion if you hit further issues. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi!
My robot is a 4 wheel swerve drive robot and I want to setup the action graph for it so I can control it using ROS2, how can we configure swerve drive action graph in Isaac Sim?
Thanks.
Beta Was this translation helpful? Give feedback.
All reactions