Dev/hougantc/teleop controllers
Description
This MR does the following:
- Introduces Quest retargeters for G1 env loco-manipulation tasks. This enables lower body control via the quest controller joysticks, and upper body control via controller tracking.
- Refactors the retargeters to not depend on OpenXRDevice, instead move enums into DeviceBase and allow retargeters to be used across devices.
- Adds XrAnchor "pinning" to a specific robot prim so that the XR view follows the robot in the scene.
Fixes # (issue)
Type of change
- New feature (non-breaking change which adds functionality)
- Breaking change (existing functionality will not work without user modification)
- Documentation update
Screenshots
Please attach before and after screenshots of the change if applicable.
Checklist
- [x] I have read and understood the contribution guidelines
- [x] I have run the
pre-commitchecks with./isaaclab.sh --format - [x] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings
- [x] I have added tests that prove my fix is effective or that my feature works
- [x] I have updated the changelog and the corresponding version in the extension's
config/extension.tomlfile - [x] I have added my name to the
CONTRIBUTORS.mdor my name already exists there
@greptile
@greptile
Overall, LGTM. Added a few comments that can be handled in different PR.
Greptile Summary
- Adds Quest motion controller support for G1 robot locomanipulation with joystick-based locomotion and hand tracking
- Refactors retargeter architecture to be device-agnostic by moving enums to
DeviceBaseand introducing requirement-based feature collection - Implements XR anchor "pinning" to robot prim with configurable rotation modes (fixed, follow, smoothed) for camera tracking during locomotion
Confidence Score: 3/5
- This PR requires fixes for several bugs before merging safely.
- Score reflects multiple syntax errors (typos) and logic bugs that will cause runtime failures, though the overall architecture is sound and well-tested.
- Pay close attention to
xr_anchor_utils.py(potential None access),retargeter_base.py(typo in method name),g1_motion_controller_locomotion.py(missing super call), andopenxr_device.py(inconsistent import pattern).
Important Files Changed
| Filename | Overview |
|---|---|
| source/isaaclab/isaaclab/devices/openxr/xr_anchor_utils.py | New XR anchor synchronization utility with potential None access bug in rotation toggle logic (line 169) |
| source/isaaclab/isaaclab/devices/device_base.py | Refactored to add shared enums and requirement-based feature collection for retargeters |
| source/isaaclab/isaaclab/devices/retargeter_base.py | Added requirement system with typo in method name (get_requirements vs GetRequirments) |
| source/isaaclab/isaaclab/devices/openxr/openxr_device.py | Major refactor adding motion controller support and anchor synchronization with XRCoreEventType import inconsistency |
| source/isaaclab/isaaclab/devices/openxr/retargeters/humanoid/unitree/g1_motion_controller_locomotion.py | New motion controller locomotion retargeter with missing super().init call |
Sequence Diagram
sequenceDiagram
participant User
participant Env as "LocomanipulationG1Env"
participant Device as "OpenXRDevice"
participant Sync as "XrAnchorSynchronizer"
participant Retargeter as "G1MotionControllerRetargeter"
participant Robot as "G1Robot"
User->>Env: "Initialize environment"
Env->>Device: "OpenXRDevice(cfg, retargeters)"
Device->>Sync: "XrAnchorSynchronizer(xr_core, xr_cfg)"
Sync->>Sync: "Subscribe to pre_sync_update event"
Device->>Device: "Aggregate retargeter requirements"
User->>Env: "Step simulation"
Env->>Device: "advance()"
Device->>Device: "_get_raw_data()"
Device->>Device: "Query motion controller pose and inputs"
Device->>Retargeter: "retarget(controller_data)"
Retargeter->>Retargeter: "Map thumbsticks to locomotion commands"
Retargeter->>Retargeter: "Map triggers/squeeze to hand joints"
Retargeter-->>Device: "Return concatenated tensor"
Device-->>Env: "Return robot commands"
Env->>Robot: "Apply commands to robot joints"
Note over Sync: "Pre-sync callback triggered"
Sync->>Sync: "sync_headset_to_anchor()"
Sync->>Sync: "Read robot pelvis world pose"
Sync->>Sync: "Calculate anchor position and rotation"
Sync->>Device: "set_world_transform_matrix(anchor_path)"
Looks like this pr depends on 3897, overall looks good in the first pass, it will be nice to give a second pass with 3897 merged first : )
@ooctipus @kellyguo11 This MR should be ready for review now that the precursor MR has merged.
@greptile
looks like some tests and doc build job are failing, @rwiltz could you take a look pls?
looks like some tests and doc build job are failing, @rwiltz could you take a look pls?
Weird I am also seeing the doc build failing on main locally... investigating.
looks like some tests and doc build job are failing, @rwiltz could you take a look pls?
Weird I am also seeing the doc build failing on main locally... investigating.
@kellyguo11 Should be addressed now
@greptile