示例#1
0
    def __init__(self, name, config):
        wago_ip = config["controller_ip"]
        nb_filter = config["nb_filter"]
        try:
            #attenuator type (0,1 or 2, default is 0)
            att_type = config["att_type"]
        except:
            att_type = 0
        try:
            #wago card alternation (True or False, default False)
            wago_alternate = config["wago_alternate"]
        except:
            wago_alternate = False
        try:
            #wago status module (default value "750-436")
            stat_m = config["status_module"]
        except:
            stat_m = "750-436"
        try:
            #wago control module (default value "750-530")
            ctrl_m = config["control_module"]
        except:
            ctrl_m = "750-530"

        self.__control = MattControl(wago_ip, nb_filter, att_type,
                                     wago_alternate, stat_m, ctrl_m)

        self.__control.connect()
        wrap_methods(self.__control, self)
示例#2
0
    def __init__(self, name, config):
        wago_ip = config["controller_ip"]
        nb_filter = config["nb_filter"]
        try:
          #attenuator type (0,1 or 2, default is 0)
          att_type = config["att_type"]
        except:
            att_type = 0
        try:
            #wago card alternation (True or False, default False)
            wago_alternate = config["wago_alternate"]
        except:
            wago_alternate = False
        try:
            #wago status module (default value "750-436")
            stat_m = config["status_module"]
        except:
            stat_m = "750-436"
        try:
            #wago control module (default value "750-530")
            ctrl_m = config["control_module"]
        except:
            ctrl_m = "750-530"

        self.__control = MattControl(wago_ip, nb_filter, att_type, wago_alternate, stat_m, ctrl_m)

        self.__control.connect()
        wrap_methods(self.__control, self)
示例#3
0
   def __init__(self, name, config):
       wago_ip = config["controller_ip"]
       lenses = int(config["lenses"])
       pinhole = int(config["pinhole"])

       self.__control = tf_control.TfControl(wago_ip, lenses, pinhole, 3) # 3s. exec timeout
       self.__control.connect()
       wrap_methods(self.__control, self)
示例#4
0
    def __init__(self, name, config):
        wago_ip = config["controller_ip"]
        nb_filter = config["nb_filter"]
        try:
            # fixed energy
            self.energy = Energy(float(config["energy"]))
        except:
            # tunable energy: energy motor is expected
            self.energy = Energy(config["energy"])
        try:
            # attenuator type (0,1 or 2, default is 0)
            att_type = config["att_type"]
        except:
            att_type = 0
        try:
            # wago card alternation (True or False, default False)
            wago_alternate = config["wago_alternate"]
        except:
            wago_alternate = False
        try:
            # wago status module (default value "750-436")
            stat_m = config["status_module"]
        except:
            stat_m = "750-436"
        try:
            # wago control module (default value "750-530")
            ctrl_m = config["control_module"]
        except:
            ctrl_m = "750-530"
        try:
            datafile = config["datafile"]
        except:
            datafile = None

        self.__control = matt_control.MattControl(
            wago_ip, nb_filter, self.energy.read(), att_type, wago_alternate, stat_m, ctrl_m, datafile
        )

        self.__control.connect()
        wrap_methods(self.__control, self)