gripper_configuration
=====================

.. py:module:: gripper_configuration


Attributes
----------

.. autoapisummary::

   gripper_configuration.TGripperConfiguration


Classes
-------

.. autoapisummary::

   gripper_configuration.GripperConfiguration
   gripper_configuration.GripperStateConfiguration


Module Contents
---------------

.. py:data:: TGripperConfiguration

   The configuration type a motion or mapping is bound to; concrete consumers bind it to
   one configuration subclass.


.. py:class:: GripperConfiguration

   Bases: :py:obj:`krrood.patterns.subclass_safe_generic.SubClassSafeGeneric`, :py:obj:`abc.ABC`, :py:obj:`Generic`\ [\ :py:obj:`TGripperConfiguration`\ ]


   A configuration a gripper can be commanded into.

   Carries the end effector the configuration configures and the joint positions to
   reach, so both the action and the motion that consume it share one object instead of
   resolving the end effector and looking up the joint state independently.


   .. py:attribute:: end_effector
      :type:  semantic_digital_twin.robots.robot_parts.EndEffector

      The end effector this configuration configures.



   .. py:attribute:: joint_state
      :type:  semantic_digital_twin.datastructures.joint_state.JointState

      The positions the end effector's connections are commanded to.



   .. py:attribute:: finger_velocity
      :type:  float | None
      :value: None


      Maximum finger joint velocity (in m/s) enforced during the motion.

      ``None`` leaves the speed unconstrained.



   .. py:method:: from_state_type(end_effector: semantic_digital_twin.robots.robot_parts.EndEffector, state_type: semantic_digital_twin.datastructures.definitions.GripperState) -> Self
      :classmethod:


      :param end_effector: The end effector whose declared state is used.
      :param state_type: The state type to build the configuration for.
      :return: The configuration for the declared state of the given type.
      :raises NoJointStateWithType: If the end effector declares no such state.



.. py:class:: GripperStateConfiguration

   Bases: :py:obj:`GripperConfiguration`


   The configuration a robot description already declares for a gripper, selected by
   its :class:`~semantic_digital_twin.datastructures.definitions.GripperState`.


