FujiSPBHelperWriteAsync 方法 (IReadWriteDevice, Byte, String, Boolean) |
写入一个Bool值到一个地址里,地址可以是线圈地址,也可以是寄存器地址,例如:M100, D10.12,地址可以携带站号信息,例如:s=2;D10.12
Write a Bool value to an address. The address can be a coil address or a register address, for example: M100, D10.12.
The address can carry station number information, for example: s=2;D10.12
命名空间:
HslCommunication.Profinet.Fuji
程序集:
HslCommunication (在 HslCommunication.dll 中) 版本:12.1.2.0 (12.1.2.0)
语法 public static Task<OperateResult> WriteAsync(
IReadWriteDevice device,
byte station,
string address,
bool value
)
Public Shared Function WriteAsync (
device As IReadWriteDevice,
station As Byte,
address As String,
value As Boolean
) As Task(Of OperateResult)
public:
static Task<OperateResult^>^ WriteAsync(
IReadWriteDevice^ device,
unsigned char station,
String^ address,
bool value
)
static member WriteAsync :
device : IReadWriteDevice *
station : byte *
address : string *
value : bool -> Task<OperateResult>
参数
- device
- 类型:HslCommunication.CoreIReadWriteDevice
PLC设备通信对象 - station
- 类型:SystemByte
当前的站号信息 - address
- 类型:SystemString
地址信息,举例:M100, D10.12 - value
- 类型:SystemBoolean
写入的bool值
返回值
类型:
TaskOperateResult是否写入成功的结果对象
参见