SiemensWebApiReadAsync 方法 (String, UInt16) |
从PLC中根据输入的数据标签名称,读取出原始的字节数组信息,长度参数无效,需要二次解析
According to the input data tag name, read the original byte array information from the PLC,
the length parameter is invalid, and a second analysis is required
命名空间:
HslCommunication.Profinet.Siemens
程序集:
HslCommunication (在 HslCommunication.dll 中) 版本:12.1.2.0 (12.1.2.0)
语法 public override Task<OperateResult<byte[]>> ReadAsync(
string address,
ushort length
)
Public Overrides Function ReadAsync (
address As String,
length As UShort
) As Task(Of OperateResult(Of Byte()))
public:
virtual Task<OperateResult<array<unsigned char>^>^>^ ReadAsync(
String^ address,
unsigned short length
) override
abstract ReadAsync :
address : string *
length : uint16 -> Task<OperateResult<byte[]>>
override ReadAsync :
address : string *
length : uint16 -> Task<OperateResult<byte[]>>
参数
- address
- 类型:SystemString
标签的地址信息,例如 "全局DB".Static_21 - length
- 类型:SystemUInt16
无效的参数
返回值
类型:
TaskOperateResultByte原始的字节数组信息
实现
IReadWriteNetReadAsync(String, UInt16)参见