Example #1
0
        private void fq_detect()
        {
            try
            {
                float pef = 0f;
                switch (UseFqy)
                {
                case "FLA_502":
                {
                    if (fla_502 != null)
                    {
                        while (true)
                        {
                            Thread.Sleep(500);
                            Exhaust.Fla502_data ex_temp = fla_502.GetData();
                            pef = fla_502.Getdata_PEF();
                            Msg(ex_temp.HC, ex_temp.NO, ex_temp.CO, ex_temp.CO2, pef, ex_temp.O2);
                            Thread.Sleep(100);
                        }
                    }
                }
                break;

                case "FLA_501":
                {
                    if (fla_501 != null)
                    {
                        while (true)
                        {
                            Thread.Sleep(500);
                            Exhaust.Fla501_data ex_temp = fla_501.Get_Data();
                            pef = fla_501.Getdata_PEF();
                            Msg(ex_temp.HC, ex_temp.NO, ex_temp.CO, ex_temp.CO2, pef, ex_temp.O2);
                            Thread.Sleep(100);
                        }
                    }
                }
                break;
                }
            }
            catch (Exception)
            {
            }
        }