using System;
using SystemFramework;
using bizFacade;
namespace MesServerWork
{
public partial class MIS_BASE
{
///
/// 通过TagTypeName读取PLC数据
///
///
///
static private void Read_TagValueByTagTypeName(string cmd, string opName, out string tagValue)
{
tagValue = "-1";
int tagTypeID;
try
{
tagTypeID = Convert.ToInt32(MesDataFunction.OpcOperation.hashtable_TagType[cmd]);
string msg = "MES|" + tagTypeID.ToString() + "|" + opName + "|" + tagValue;
//tagValue = ChatService.MesReadWhisperMessage(msg);
MesDataFunction.OpcOperation.ReadTagValue(tagTypeID, opName, out tagValue);
}
catch (Exception err)
{
ApplicationLog.WriteLog(err, "Read_TagValueByTagTypeName_FUNC;工位号:"+ opName+";命令:"+ cmd+";值:"+ tagValue);
}
}
///
/// 通过TagID读取对应值
///
///
///
static private void Read_TagValueByTagID(string TagID, out object tagValue)
{
tagValue = "0";
try
{
MesDataFunction.OpcOperation.ReadPLC(TagID, out tagValue);
}
catch (Exception err)
{
ApplicationLog.WriteLog(err, "Read_TagValueByTagID_FUNC");
}
}
///
/// 根据数据类型代码、工位号获得对应值
///
///
///
///
private static void Read_TagValueByTagTypeID(int tagTypeID, string opName, out string tagValueStr)
{
tagValueStr = "-1";
try
{
MesDataFunction.OpcOperation.ReadTagValue(tagTypeID, opName, out tagValueStr);
}
catch (Exception err)
{
ApplicationLog.WriteLog(err, "Read_TagValueByTagTypeID_FUNC");
}
}
///
/// 根据数据类型代码、工位号获得对应值
///
///
///
///
private static void Read_TagValueByTagTypeID(int tagTypeID, string opName, out object tagValueStr)
{
tagValueStr = "-1";
try
{
tagValueStr = MesDataFunction.OpcOperation.ReadPLC(tagTypeID, opName);
}
catch (Exception err)
{
ApplicationLog.WriteLog(err, "Read_TagValueByTagTypeID_FUNC");
}
}
///
/// 读取数据通过(TagID)
///
///
///
public static void Read_TagID(string TagID, out object tagValueOb)
{
Read_TagValueByTagID(TagID, out tagValueOb);
}
///
/// 读取数据通过(TagTypeName&opName)
///
///
///
public static void Read_TagTypeName(string cmd, string opName, out string tagValueStr)
{
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
}
///
/// 读取数据通过(TagTypeID&opName)
///
///
///
public static void Read_TagTypeID(int tagTypeID, string opName, out string tagValueStr)
{
Read_TagValueByTagTypeID(tagTypeID, opName, out tagValueStr);
}
public static void Read_TagTypeID(int tagTypeID, string opName, out object tagValueStr)
{
Read_TagValueByTagTypeID(tagTypeID, opName, out tagValueStr);
}
///
/// 匹配结果(DBX3.4)(69)
/// 匹配是否成功
///
///
///
public static void Read_MatchSuccess(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "Match";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 是否匹配(DBX3.3)(68)
///
///
///
public static void Read_MatchingCompleted(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "MatchingCompleted";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// MES保存完数据(必须MIS)(X102.2)(20)
///
///
///
public static void Read_MesReadOver(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "MesReadOver";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
///
/// 发动机到位(X0.1)(2)
///
///
///
public static void Read_WorkStart(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "WorkStart";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
///
/// 发动机机型标志(INT4)(9)
///
public static void Read_EngineTypeID(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "EngineTypeID";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 发动机ID(STRING6.38)(10)
///
public static void Read_EngineID(string opName, out string tagValue)
{
tagValue = "";
string cmd = "EngineID";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = tagValueStr;
}
///
/// 发动机型号(STRING46.38)(11)
///
public static void Read_EngineType(string opName, out string tagValue)
{
tagValue = "";
string cmd = "EngineType";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = tagValueStr;
}
///
/// 工位直通(X101.6)(1006)
///
public static void Read_PartGoOver(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "PartGoOver";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 托盘到位(1)托盘离开(0) (DBX101.5)(13)
///
public static void Read_PartPalletStatus(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "PartPalletStatus";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
///
/// 加工时间变量目标时间 (DINT 106)(17)
///
public static void Read_MachineTime_TargetTime(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "TargetTime";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 加工时间变量实际时间 (DINT 110)(18)
///
public static void Read_MachineTime_ActualTime(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "ActualTime";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 质量数据总成合格标志(INT104)(21)
///
public static void Read_QualityMask(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "QualityMask";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
if (tagValueStr == "1" | tagValueStr.ToLower () == "true")
{
tagValueStr = "1";
}
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 机体流向标志(1 BYTE):
/// 0普通工位:
/// 1:上线(发动机上线);
/// 2:下线(发动机下线);(INT114)(41)
///
public static void Read_PartMoveDirection(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "PartMoveDirection";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 强制MES(X103.0)(78)
///
public static void Read_Mes_MustTest(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "IsMES";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 工位三种状态:在线、离线、屏蔽(0,1,2)(DBB116)(79)
///
public static void Read_OnLineState(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "OnLineState";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 变量类型代码=44 CF0.4
/// PLC向MES传递机型,机型代码,零件编号完成,通知PLC。
/// 机型可读
///
///
///
public static void Read_EngineGetOver_PLC(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "EngineTypeGetOverPLC";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
///
/// X100.2允许保存质量数据(19)
///
///
///
public static void Read_QualityData_Read_CF(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "MesRead";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt64(tagValueStr));
}
///
/// MES向PLC传递机型(DBX2.1)(5)
///
///
///
public static void Read_EngineTypeGetOver_MES(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "EngineTypeGetOverMES";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
///
/// X2.3 工作完成
///
///
///
public static void Read_MaterialVerifyOver(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "MaterialVerifyOver";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
///
/// 申请上线(DBX0.3)(43)
///
///
///
public static void Read_PartLoad(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "PartLoad";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
///
/// 上线完成(DBX0.3)(48)
///
///
///
public static void Read_PartLoad_OK(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "PartLoadOK";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
///
/// 合格放行(51)
///
///
///
public static void Read_ConfirmOkGo(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "ConfirmOkGo";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
///
/// 拧紧结束(DBX1.1)(59)
///
///
///
public static void Read_FixOK(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "FixOK";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
///
/// 蘑菇按钮(DBX1.3)(61)
///
///
///
public static void Read_NextPushButton(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "NextPushButton";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
///
/// 允许拧紧(DBX3.1)(66)
///
///
///
public static void Read_FixAllow(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "FixAllow";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
///
/// 拧紧结束确认(DBX3.2)(67)
///
///
///
public static void Read_FixOver(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "FixOver";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
///
///返修上线,在上线工位,MES依据工件情况,设定为返修件,PLC见到MES设定为1后,将返修标志写入到DBX0.2为1
///MES设定完返修返修上线后,MES清空该信号
///DBX3.7(72)
///
///
///
public static void Read_RepairUpline_MES(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "RepairUplineMES";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 匹配结果(DBX3.4)(69)
///
///
///
public static void Read_Match(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "Match";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 发动机机型代码(DBB404)(73)[false]
///
///
///
public static void Read_EngineTypeID_MES(string opName, out int EngineTypeID)
{
EngineTypeID = 0;
string cmd = "EngineTypeID_MES";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
EngineTypeID = Convert.ToInt32(tagValueStr);
}
///
/// 发动机机型(DBB446)(75)
///
///
///
public static void Read_EngineType_MES(string opName, out string EngineType)
{
EngineType = "";
string cmd = "EngineType_MES";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
EngineType = tagValueStr;
}
///
/// 发动机号(DBB406)(74)
///
///
///
public static void Read_EngineID_MES(string opName, out string EngineID)
{
EngineID = "";
string cmd = "EngineID_MES";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
EngineID = tagValueStr;
}
///
/// 拧紧序号(拧紧或者称重的顺序)(DBB88)(77)[false]
///
///
///
public static void Read_OrderBy(string opName, out int tagValue)
{
tagValue =0;
string cmd = "ProcessCode";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 工步属性(工作性质)(DBB90)(88)[false]
///
///
///
public static void Read_ProcessCode(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "ProcessCode";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 套筒号、子程序代码子程序(DBB26)(2025)[false]
///
///
///
public static void Read_BoltCode(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "BoltCode";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 托盘代码(DBB86)(80)
///
public static void Read_PalletCode(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "PartPalletCode";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 获得机型,零件编号,机型代码,托盘号,(从PLC)
///
///
///
///
///
///
public static void GetEngineTypeFromPLC(string opName, out int EngineTypeID, out string EngineType, out string EngineID, out int PartPallet_Code)
{
Read_EngineTypeID(opName,out EngineTypeID);
Read_EngineType(opName, out EngineType);
Read_EngineID(opName, out EngineID);
Read_PalletCode(opName, out PartPallet_Code);
}
///
/// 获得机型,零件编号,机型代码,托盘号,(从DB)
///
///
///
///
///
///
public static void GetEngineTypeFromDB(string opName, out int EngineTypeID, out string EngineType, out string EngineID, out int PartPallet_Code)
{
string orderForm = "";
int isRepair = 0;
string repairCode = "";
string palletCode = "0";
BaseDataSystemMES.OpName_MIS_Moby_Select(opName,
out orderForm, out EngineTypeID, out EngineType,
out EngineID, out palletCode, out isRepair, out repairCode);
PartPallet_Code = Convert.ToInt32(palletCode);
}
///
/// 0:不修改;1:可以修改。(上线工位)通知PLC。(DBX1.2)(76)
///
///
///
public static void Read_PartPalletCode_PLC_ToMES(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "PartPalletCodePLCToMES";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 通知写入托盘号(DBX3.5)(70)
///
///
///
public static void Read_PartPalletCode_PLC(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "PartPalletCodePLC";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 变量类型代码=86,打印第一行(机型),用于线首打印机。STRING 486 .38
///
///
///
public static void Read_PrintBarCode1_MES(string opName, out string tagValue)
{
tagValue = "";
string cmd = "PrintBarCode1MES";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = tagValueStr;
}
///
/// 变量类型代码=87,打印第二行(流水号),用于线首打印机。STRING 526 .38
///
///
///
public static void Read_PrintBarCode2_MES(string opName, out string tagValue)
{
tagValue = "";
string cmd = "PrintBarCode2MES";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = tagValueStr;
}
///
/// 上线工位。0:正常工作;1:空托盘放行(DBX2.2)(6)
///
///
///
public static void Read_PartPalletGoOver(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "PartPalletGoOver";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 自动手动申请工件编号,0是自动方式;1:手动方式。切换时,(DBX2.1)(71)
///
///
///
public static void Read_IsAutoGetEngineID(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "IsAutoGetEngineID";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 正常拧紧时选择(DBX100.3)(81)
///
///
///
public static void Read_Normal(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "Normal";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 备用拧紧时选择(DBX100.4)(82)
///
///
///
public static void Read_UnNormal(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "UnNormal";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 允许拧紧2(DBX100.5)(83)
///
///
///
public static void Read_FixAllow_2(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "FixAllow2";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 拧紧结束2(DBX100.6)(84)
///
///
///
public static void Read_FixOK_2(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "FixOK2";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 拧紧结束确认2(DBX100.7)(85)
///
///
///
public static void Read_FixOver_2(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "FixOver2";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 拧紧顺序2(DBX101.7)(1007)
/// MES通知PLC开始拧紧顺序(0为其他位,1为第一位置)(必须MES)
///
///
///
public static void Read_WriteShaft_2(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "WriteShaft2";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 返修上线(DBX2.6)(52)
///
///
///
public static void Read_PartLoadFinish(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "PartLoadFinish";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 返修上线后,PLC确认(DBX1.0)(58)
///
///
///
public static void Read_PartLoadOver(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "PartLoadOver";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 变量类型代码=22,读取托盘信息 DBW126
///
///
///
public static void Read_PalletInfo(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "PalletInfo";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 变量类型代码=23,读取托盘信息 DBW194
///
///
///
public static void Read_RepairStatus_PLC(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "RepairStatusPLC";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// PLC将MOBY信息成功写入到了对应的DB,然后通知MES(DBX1.5)(63)
///
///
///
public static void Read_PalletMobyReadOver(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "PalletMobyReadOver";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 在线返修状态(DBX4.0)(91)
///
///
///
public static void Read_OnlineRepair(string opName, out int tagValue)
{
tagValue = 0;
string cmd = "OnlineRepair";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToInt32(tagValueStr);
}
///
/// 离线返修状态(DBX4.1)(92)
///
///
///
public static void Read_OutLineRepair(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "OutLineRepair";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
///
/// MES通知PLC修改托盘状态成功(DBX4.2)(93)
///
///
///
public static void Read_UpdatePalletOK(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "UpdatePalletOK";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
///
/// MES向PLC要求申请下线(DBX0.7)(50)
///
///
///
public static void Read_PalletDown(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "PalletDown";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
///
/// 物料检测(99)
///
///
///
public static void Read_CheckMaterial(string opName, out object tagValue)
{
tagValue = new bool[16];
string cmd = "CheckMaterial";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
///
/// 备用功能是否启用(95)
///
///
///
public static void Read_BakOpNameIsWork(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "BakOpNameIsWork";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
///
/// 质量呼叫(DBX301.2)(2011)
///
///
///
public static void Read_QualityCall(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "QualityCall";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
///
/// 物料呼叫(DBX301.3)(2012)
///
///
///
public static void Read_MaterialCall(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "MaterialCall";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
///
/// 故障呼叫(DBX301.4)(2013)
///
///
///
public static void Read_FaultCall(string opName, out bool tagValue)
{
tagValue = false;
string cmd = "FaultCall";
string tagValueStr;
Read_TagValueByTagTypeName(cmd, opName, out tagValueStr);
tagValue = Convert.ToBoolean(Convert.ToInt32(tagValueStr));
}
}
}