/// <summary> /// 设置测试流程其他机种需要修改,默认NU9流程{ ":01", ":02", ":04", ":20", "SYS_AUDIO:23", "SUB_TOUCH:24", "SUB_LED:26", "RF2:19", ":50" } /// </summary> /// <param name="flow"></param> public static Route CheckStation(Shopfloor sf, string SN, string Station, ref string OutStr, string[] flow = null) { try { if (flow != null) { Flow = flow; } string dbret = sf.SwapData("SWDL", "querydata", "SN=" + SN + ";$;station=QueryData;$;SWDateTime=" + DateTime.Now.ToString("yyyyMMddHHmmss") + ";$;MonitorAgentVer=VW20151102.01;$;").ToUpper(); OutStr = dbret; if (dbret.Contains("STATUS=") && dbret.Contains("SF_CFG_CHK=PASS")) { string Status = Shopfloor.GetStrInner(dbret, "STATUS=", ";"); int fix = 10, dut = -1; for (int i = 0; i < Flow.Length; i++) { if (Flow[i].Contains(Station)) { fix = i - 1; } if (Flow[i].Contains(Status)) { dut = i; } } if (dut == -1) { return(Route.Failed); } if (dut == fix) { return(Route.Pass); } if (dut > fix) { return(Route.Tested); } if (dut < fix) { return(Route.Lost); } } return(Route.None); } catch (Exception) { return(Route.None); } }