示例#1
0
    def __init__(self, dummy=False):
        """
        Setting some "global" variables.

        If dummy=True no wasco runtime libraries will be loaded.

        """

        self.wascocard = Wasco(dummy=dummy)  # create wasco object
        self.wasco_boardId = self.wascocard.boardId

        self.red_out = DAOUT3
        self.green_out = DAOUT4
        self.blue_out = DAOUT2
        self.low_threshold = 0x200  # min voltages must be integer
        self.low_warning = 0x400  # low warning voltages must be integer
        self.high_threshold = 0xFFF  # max voltages must be integer

        # voltage which is set at the moment
        self.U_r = self.high_threshold
        self.U_b = self.high_threshold
        self.U_g = self.high_threshold