public Board(string name, TransportBase tport = null) { if (name == null) { throw new ArgumentNullException("name"); } logger.Trace("I: Board(): construct {0}{1}", name, (tport == null?"":" with supplied transport")); Name = name; _transport = tport; // Each TEC heater has its own address _tec_heaters = new List <TecHeater>(); for (uint ii = 0; ii < nTecHeaters; ++ii) { _tec_heaters.Add(new TecHeater(this, Tec0 + ii)); _tec_heaters[(int)ii].ErrorReceived += Board_ErrorReceived; } // The two resistive heaters share an address _res_heaters = new List <ResistiveHeater>(nResHeaters); for (uint ichannel = 0; ichannel < nResHeaters; ++ichannel) { _res_heaters.Add(new ResistiveHeater(this, Res0, ichannel)); _res_heaters[(int)ichannel].ActivationValueProxy = this.ResistiveHeaterActivationValue; _res_heaters[(int)ichannel].ErrorReceived += Board_ErrorReceived; } _fans = new FanController(this, Fans0); _fans.ErrorReceived += Board_ErrorReceived; _pollees = new List <BoardDevice>(); _pollees.AddRange(_tec_heaters); _pollees.AddRange(_res_heaters); _pollees.Add(_fans); _poll_timer = new System.Threading.Timer(OnPoll); logger.Trace("O: Board()"); }
internal Fan(FanController controller, string command) { _active = false; _controller = controller; _command = command; }
internal Thermistor(FanController controller, string command) { _controller = controller; _command = command; Available = false; }