コード例 #1
0
ファイル: counter.py プロジェクト: robotpy/robotpy-wpilib
    def setReverseDirection(self, reverseDirection: bool) -> None:
        """Set the Counter to return reversed sensing on the direction. This
        allows counters to change the direction they are counting in the case
        of 1X and 2X quadrature encoding only. Any other counter mode isn't
        supported.

        :param reverseDirection: True if the value counted should be negated.
        """
        hal.setCounterReverseDirection(self.counter, reverseDirection)
コード例 #2
0
ファイル: counter.py プロジェクト: warrenlp/robotpy-wpilib
    def setReverseDirection(self, reverseDirection: bool) -> None:
        """Set the Counter to return reversed sensing on the direction. This
        allows counters to change the direction they are counting in the case
        of 1X and 2X quadrature encoding only. Any other counter mode isn't
        supported.

        :param reverseDirection: True if the value counted should be negated.
        """
        hal.setCounterReverseDirection(self.counter, reverseDirection)
コード例 #3
0
ファイル: counter.py プロジェクト: arilotter/robotpy-wpilib
    def setReverseDirection(self, reverseDirection):
        """Set the Counter to return reversed sensing on the direction. This
        allows counters to change the direction they are counting in the case
        of 1X and 2X quadrature encoding only. Any other counter mode isn't
        supported.

        :param reverseDirection: True if the value counted should be negated.
        :type  reverseDirection: bool 
        """
        if self.counter is None:
            raise ValueError("operation on freed port")
        hal.setCounterReverseDirection(self.counter, reverseDirection)
コード例 #4
0
    def setReverseDirection(self, reverseDirection):
        """Set the Counter to return reversed sensing on the direction. This
        allows counters to change the direction they are counting in the case
        of 1X and 2X quadrature encoding only. Any other counter mode isn't
        supported.

        :param reverseDirection: True if the value counted should be negated.
        :type  reverseDirection: bool 
        """
        if self.counter is None:
            raise ValueError("operation on freed port")
        hal.setCounterReverseDirection(self.counter, reverseDirection)