Back to FabImage Library website
You are here: Start » Function Reference » System » Modbus TCP » ModbusTCP_ForceMultipleCoils
Header: | STD.h |
---|---|
Namespace: | fil |
Module: | FoundationLite |
Function Code 15. Forces each coil in a sequence of coils to either ON or OFF in a remote device
Syntax
void fil::ModbusTCP_ForceMultipleCoils ( const fil::SocketId& inSocket, const ftl::Optional<int>& inTimeout, int inUnitID, int inStartingAddress, const ftl::Array<bool>& inStatuses )
Parameters
Name | Type | Range | Default | Description | |
---|---|---|---|---|---|
![]() |
inSocket | const SocketId& | Connected socket ID on port 502. | ||
![]() |
inTimeout | const Optional<int>& | 10 - ![]() |
NIL | Timeout in milliseconds, block if not specified. |
![]() |
inUnitID | int | 0 - 255 | 1 | Default is 1. |
![]() |
inStartingAddress | int | 0 - 65535 | The address of the first coil. | |
![]() |
inStatuses | const Array<bool>& |
Errors
List of possible exceptions:
Error type | Description |
---|---|
DomainError | Size of statuses array should be between 1 and 1968. |
See Also
- ModbusTCP_ReadCoils – Function Code 01. Reads contiguous status of coils in a remote device
- ModbusTCP_WriteCoil – Function Code 05. Writes a single output to either ON or OFF in a remote device