예제 #1
0
    def set(self, value):
        """Set the value of a digital output.

        :param value: True is on, off is False
        :type  value: bool
        """
        hal.setDIO(self.handle, bool(value))
예제 #2
0
    def set(self, value):
        """Set the value of a digital output.

        :param value: True is on, off is False
        :type  value: bool
        """
        hal.setDIO(self.port, 1 if value else 0)
예제 #3
0
    def set(self, value):
        """Set the value of a digital output.

        :param value: True is on, off is False
        :type  value: bool
        """
        hal.setDIO(self.port, 1 if value else 0)
예제 #4
0
    def set(self, value):
        """Set the value of a digital output.

        :param value: True is on, off is False
        :type  value: bool
        """
        if self.port is None:
            raise ValueError("operation on freed port")
        hal.setDIO(self.port, 1 if value else 0)
예제 #5
0
    def set(self, value):
        """Set the value of a digital output.

        :param value: True is on, off is False
        :type  value: bool
        """
        if self.port is None:
            raise ValueError("operation on freed port")
        hal.setDIO(self.port, 1 if value else 0)
예제 #6
0
    def set(self, value: bool) -> None:
        """Set the value of a digital output.

        :param value: True is on, off is False
        """
        hal.setDIO(self.handle, bool(value))