SiemensS7PlusReadFromCoreServerAsync 方法 (CommunicationPipe, Byte, Boolean, Boolean) |
使用指定的管道来进行数据通信,发送原始数据到管道,然后从管道接收相关的数据返回,本方法无锁
命名空间:
HslCommunication.Profinet.Siemens
程序集:
HslCommunication (在 HslCommunication.dll 中) 版本:12.1.2.0 (12.1.2.0)
语法 public override Task<OperateResult<byte[]>> ReadFromCoreServerAsync(
CommunicationPipe pipe,
byte[] send,
bool hasResponseData = true,
bool usePackAndUnpack = true
)
Public Overrides Function ReadFromCoreServerAsync (
pipe As CommunicationPipe,
send As Byte(),
Optional hasResponseData As Boolean = true,
Optional usePackAndUnpack As Boolean = true
) As Task(Of OperateResult(Of Byte()))
public:
virtual Task<OperateResult<array<unsigned char>^>^>^ ReadFromCoreServerAsync(
CommunicationPipe^ pipe,
array<unsigned char>^ send,
bool hasResponseData = true,
bool usePackAndUnpack = true
) override
abstract ReadFromCoreServerAsync :
pipe : CommunicationPipe *
send : byte[] *
?hasResponseData : bool *
?usePackAndUnpack : bool
(* Defaults:
let _hasResponseData = defaultArg hasResponseData true
let _usePackAndUnpack = defaultArg usePackAndUnpack true
*)
-> Task<OperateResult<byte[]>>
override ReadFromCoreServerAsync :
pipe : CommunicationPipe *
send : byte[] *
?hasResponseData : bool *
?usePackAndUnpack : bool
(* Defaults:
let _hasResponseData = defaultArg hasResponseData true
let _usePackAndUnpack = defaultArg usePackAndUnpack true
*)
-> Task<OperateResult<byte[]>>
参数
- pipe
- 类型:HslCommunication.Core.PipeCommunicationPipe
管道信息 - send
- 类型:SystemByte
等待发送的数据 - hasResponseData (Optional)
- 类型:SystemBoolean
是否需要返回的数据 - usePackAndUnpack (Optional)
- 类型:SystemBoolean
是否进行封包,拆包操作
返回值
类型:
TaskOperateResultByte是否成功的结果对象
参见