示例#1
0
    def getPosition(self) -> float:
        """Get the PWM value in terms of a position.

        This is intended to be used by servos.

        .. note::

            :func:`setBounds` must be called first.

        :returns: The position the servo is set to between 0.0 and 1.0.
        """
        return hal.getPWMPosition(self.handle)
示例#2
0
    def getPosition(self) -> float:
        """Get the PWM value in terms of a position.

        This is intended to be used by servos.

        .. note::

            :func:`setBounds` must be called first.

        :returns: The position the servo is set to between 0.0 and 1.0.
        """
        return hal.getPWMPosition(self.handle)