using Mesnac.Action.ChemicalWeighing.Entity;
using Mesnac.PlcUtils;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace Mesnac.Action.ChemicalWeighing.EngineeringDebuggingMode
{
public class PlcCommunicationUtil
{
///
/// 从PLC中读取值
///
/// 要读取的属性
///
public static string GetDataToString(string dmValue)
{
return new DataKeyValue(dmValue).NowValue.ToString();
}
///
/// 从PLC中读取值
///
/// 要读取的属性
///
public static string GetDataToString(string dmName, string dmValue)
{
return GetDataToString(dmName + dmValue);
}
}
}