Writes bit value to address using Modbus function code
0x05(force single coil).
The function returns the following error codes:
E_MODBUS if writing the registers failed.E_NULL if the Modbus context is not associated.| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(modbus_type), | intent(inout) | :: | modbus |
Modbus RTU/TCP type. |
||
| integer, | intent(in) | :: | address |
Address to write to. |
||
| integer, | intent(in) | :: | value |
Value to write (0 or 1). |