    def _generate_gripper_command(self, char, command):
        """Update the gripper command according to the character entered by the user."""
        if char == "a":
            command = outputMsg.Robotiq2FGripper_robot_output()
            command.rACT = 1
            command.rGTO = 1
            command.rSP = 255
            command.rFR = 150

        if char == "r":
            command = outputMsg.Robotiq2FGripper_robot_output()
            command.rACT = 0

        if char == "c":
            command.rPR = 255

        if char == "o":
            command.rPR = 0

        # If the command entered is a int, assign this value to rPR
        # (i.e., move to this position)
        try:
            command.rPR = int(char)
            if command.rPR > 255:
                command.rPR = 255
            if command.rPR < 0:
                command.rPR = 0
        except ValueError:
            pass
        return command
Update the gripper command according to the character entered by the user.
serl_robot_infra/robot_servers/robotiq_gripper_server.py