点击或拖拽改变大小

AllenBradleyNetReadTagAsync 方法

从PLC里读取一个指定标签名的原始数据信息及其数据类型信息
Read the original data information of a specified tag name and its data type information from the PLC

命名空间:  HslCommunication.Profinet.AllenBradley
程序集:  HslCommunication (在 HslCommunication.dll 中) 版本:11.3.3.0 (11.3.3.0)
语法
public Task<OperateResult<ushort, byte[]>> ReadTagAsync(
	string address,
	int length = 1
)

参数

address
类型:SystemString
PLC的标签地址信息
length (Optional)
类型:SystemInt32
读取的数据长度

返回值

类型:TaskOperateResultUInt16, Byte
包含原始数据信息及数据类型的结果对象
备注
数据类型的定义,可以参考 AllenBradleyHelper 的常量资源信息。
参见