点击或拖拽改变大小

OpenProtocolNetReadCustomerAsync 方法

使用自定义的命令读取数据,需要指定每个参数信息,然后返回字符串数据内容,根据实际的功能码,解析出实际的数据信息
To use a custom command to read data, you need to specify each parameter information, then return the string data content, and parse the actual data information according to the actual function code

命名空间:  HslCommunication.Profinet.OpenProtocol
程序集:  HslCommunication (在 HslCommunication.dll 中) 版本:12.1.2.0 (12.1.2.0)
语法
public Task<OperateResult<string>> ReadCustomerAsync(
	int mid,
	int revison,
	int stationId,
	int spindleId,
	List<string> parameters
)

参数

mid
类型:SystemInt32
The MID is four bytes long and is specified by four ASCII digits(‘0’…’9’). The MID describes how to interpret the message.
revison
类型:SystemInt32
The revision of the MID is specified by three ASCII digits(‘0’…’9’).The MID revision is unique per MID and is used in case several versions are available for the same MID.
stationId
类型:SystemInt32
The station the message is addressed to in the case of controller with multi-station configuration.The station ID is 1 byte long and is specified by one ASCII digit(‘0’…’9’).
spindleId
类型:SystemInt32
The spindle the message is addressed to in the case several spindles are connected to the same controller. The spindle ID is 2 bytes long and is specified by two ASCII digits (‘0’…’9’).
parameters
类型:System.Collections.GenericListString
The Data Field is ASCII data representing the data. The data contains a list of parameters depending on the MID.Each parameter is represented with an ID and the parameter value.

返回值

类型:TaskOperateResultString
结果数据信息
参见