Exemplo n.º 1
0
 def get_joint_force(self) -> List:
     joint_force = []  #[fl, fr, bl. br]
     joint_force.append(sim.simGetJointForce(self.motorHandles[0]))
     joint_force.append(sim.simGetJointForce(self.motorHandles[1]))
     joint_force.append(sim.simGetJointForce(self.motorHandles[2]))
     joint_force.append(sim.simGetJointForce(self.motorHandles[3]))
     return joint_force
Exemplo n.º 2
0
    def get_joint_force(self) -> float:
        """Retrieves the force or torque applied along/about its active axis.

        This function retrieves meaningful information only if the joint is
        prismatic or revolute, and is dynamically enabled. With the Bullet
        engine, this function returns the force or torque applied to the joint
        motor (torques from joint limits are not taken into account). With the
        ODE and Vortex engine, this function returns the total force or torque
        applied to a joint along/about its z-axis.

        :return: The force or the torque applied to the joint along/about
            its z-axis.
        """
        return sim.simGetJointForce(self._handle)