Reseting environment with spacemouse in the imitation learning tutorial in isaac orbit


I’m using the spacemouse compact to control the robot and so far it works when it comes to control the robot and the gripper. I have tested the imitation learning tutorial “” where the code has the L letter to reset the env when using a keyboard.

# add teleoperation key for env reset
    teleop_interface.add_callback("L", env.reset)

How can I bind for example the left button of the spacemouse to reset the env? The help in documentation says that the import Se3SpaceMouse uses the same add_callback function, here the link:

Orbit help

I have looked into the source code of the function add_callback, and I see that L and R are the only options. In the simulation, pressing those buttons only open and closes the gripper. What am I missing? I would like to reset the environment so I can do more than one demonstration.

def add_callback(self, key: str, func: Callable):
        # check keys supported by callback
        if key not in ["L", "R"]:
            raise ValueError(f"Only left (L) and right (R) buttons supported. Provided: {key}.")
        # TODO: Improve this to allow multiple buttons on same key.
        self._additional_callbacks[key] = func