Method WriteByteAsync
WriteByteAsync(int, byte, CancellationToken)
Asynchronously writes a value to an 8-bit unsigned integer register with the specified address.
public Task WriteByteAsync(int address, byte value, CancellationToken cancellationToken = default)
Parameters
address
intThe address of the register to write.
value
byteThe value to be stored in the register.
cancellationToken
CancellationTokenA CancellationToken which can be used to cancel the operation.
Returns
- Task
The task object representing the asynchronous write operation.
WriteByteAsync(int, byte[], CancellationToken)
Asynchronously writes an array of values to an 8-bit unsigned integer register with the specified address.
public Task WriteByteAsync(int address, byte[] values, CancellationToken cancellationToken = default)
Parameters
address
intThe address of the register to write.
values
byte[]The values to be stored in the register.
cancellationToken
CancellationTokenA CancellationToken which can be used to cancel the operation.
Returns
- Task
The task object representing the asynchronous write operation.