/// <summary> /// establish communication request by host /// </summary> void handleS1F13() { SubScenarioName = Resource.Intialize_Scenario_3; EquipmentBaseInfo message = new EquipmentBaseInfo(); message.Parse(PrimaryMessage.SecsItem); //this._equipmentBaseInfo = message; PrimaryMessage.S1F14(_equipmentBaseInfo.MDLN ?? String.Empty, _equipmentBaseInfo.SOFTREV ?? String.Empty, "0"); }
/// <summary> /// 启动建立连接进程 online by Unit /// </summary> /// <returns></returns> public bool LaunchOnlineProcess(EquipmentInfo equipmentInfo) { SubScenarioName = Resource.Intialize_Scenario_1; this._equipmentBaseInfo = equipmentInfo.EquipmentBase; this._equipmentStatusInfo = equipmentInfo.EquipmentStatus; // send estublish communication request var replyMsg = S1F13(_equipmentBaseInfo.SecsItem); if ((replyMsg != null && replyMsg.GetSFString() == "S1F14")) { var ack = replyMsg.GetCommandValue(); if (ack != 0) { CIMBASE.WriteLog(LogLevel.INFO, "Host denies establish communication request."); return(false); } } if (replyMsg == null) { return(false); } replyMsg = S1F1(); if (replyMsg == null || replyMsg.F == 0) {// host denies online request CIMBASE.WriteLog(LogLevel.INFO, "Host denies online request."); return(false); } CIMBASE.WriteLog(LogLevel.DEBUG, "Host grants online."); if (launchControlStateProcess((int)CRST.R)) { if (LaunchDateTimeUpdateProcess()) { return(launchControlStateProcess(114)); } } CIMBASE.WriteLog(LogLevel.ERROR, "estublish communication with host failed."); return(false); }