public ThreadPlaySound(int recordid, int cnt, System.Collections.BitArray Status, TouchPanelManager touch_panel_mgr,Controller controller) { this.recordid = recordid; this.cnt = cnt; this.Status = Status; this.touch_panel_mgr = touch_panel_mgr; this.controller = controller; }
public Controller(int id, string WirelessComPort, string TouchPanelComPort,string IOComPort) { this.id=id; this.WirelessComPort = WirelessComPort; this.TouchPanelComPort = TouchPanelComPort; this.IOComPort = IOComPort; this.kenwood = new KenWood((byte)id, WirelessComPort, false); try { this.IOCard = new KenWood((byte)0, IOComPort, true); } catch (Exception ex) { IOCard = null; } kenwood.OnSlaveReceiveEvent += kenwood_OnSlaveReceiveEvent; this.touch_panel_mgr = new TouchPanelManager(TouchPanelComPort); touch_panel_mgr.OnPanelCmdEvent += touch_panel_mgr_OnPanelCmdEvent; IOStatusThread = new Thread(IOTask); IOStatusThread.Start(); // recoder = new Recoder(); // new System.Threading.Thread(new ParameterizedThreadStart(PlaySpeech)).Start(new int[] { 0, 3 }); }