diff --git a/interbotix_xs_toolbox/interbotix_xs_modules/interbotix_xs_modules/xs_robot/arm.py b/interbotix_xs_toolbox/interbotix_xs_modules/interbotix_xs_modules/xs_robot/arm.py index ed3ab3b0..52184fec 100644 --- a/interbotix_xs_toolbox/interbotix_xs_modules/interbotix_xs_modules/xs_robot/arm.py +++ b/interbotix_xs_toolbox/interbotix_xs_modules/interbotix_xs_modules/xs_robot/arm.py @@ -801,6 +801,15 @@ def get_joint_efforts(self) -> List[float]: for name in self.group_info.joint_names ] + def get_number_of_joints(self) -> int: + """ + Get the number of joints in the arm group. + + :return: number of joints + """ + self.core.get_node().logdebug('Getting number of joints') + return self.group_info.num_joints + def _update_Tsb(self) -> None: """Update transform between the space and body frame from the current joint commands.""" self.core.get_node().logdebug('Updating T_sb')