SimpleWriteValueInt
SimpleWriteValueInt (FB)
SimpleWriteValueInt (FB)FUNCTION_BLOCK SimpleWriteValueInt
Use of type conversion operators (e.g. REAL_TO_INT) directly on the input 'InputValue'
In this constellation compiler error messages of type C0032 are generated, a download is not possible. Remedy: Use an intermediate variable of the explicit type INT directly at the output of the type conversion operator. Connect the intermediate variable to the input 'InputValue'.
CODESYS
InOut:
Input
xEn
BOOL
TRUE
Enable / disable of communication ( TRUE = enabled )
Input
byUnitId
BYTE
0
Address of the device
Input
InputValue
__SYSTEM.AnyType
Input variable ( FC06, FC16 ) ( USINT, UINT, UDINT, ULINT, SINT, INT, DINT, LINT )
Input
xUpdateSetp
BOOL
FALSE
Update of setpoints ( on each rising edge )
Input
xResError
BOOL
FALSE
Reinitialization of the outputs 'eErrorCodeCom' and/or 'eErrorCodeDev' to the no-error state (on every rising edge)
Inout
ModbusClient
ModbusClientBase
Client of the device
Output
eFunctionCodeFb
WriteFunctionCodesInt
Feedback - Modbus function code for the Modbus telegram
Output
wRegisterAddrFb
WORD
Feedback - start address of the register for the Modbus telegram
Output
eTypeInputValue
SIMPLE_WRITE_VALUE_TYPE_CODE
SIMPLE_WRITE_VALUE_TYPE_CODE.STATE_INVALID
Sign state of the value at the input 'InputValue'
Output
xAlarm
BOOL
Collective fault ( TRUE = fault )
Output
xAlarmCom
BOOL
Collective fault - communication ( TRUE = fault )
Output
eErrorCodeCom
ModbusErrorCode
Error code - communication ( 0 = no error )
Output
eErrorCodeDev
SIMPLE_WRITE_VALUE_ERROR_CODE
Error code - device (0 = no error)
Output
xBusy
BOOL
Communication indicator ( TRUE = communication )
Input Const
xSwapValue
BOOL
TRUE
Enable/disable swapping the positions of the bytes of a register (16 bit) (only relevant for 32/64 bit)
Input Const
xBigEndian
BOOL
TRUE
Position of the most significant 8 bits within a datum (only relevant for 32/64 bit)
Input Const
eFunctionCode
WriteFunctionCodesInt
WriteFunctionCodesInt.FC06_WriteSingleRegister
FALSE = least significant 8 bits are sent last // TRUE = most significant 8 bits are sent first Modbus function code for the Modbus telegram
Input Const
wRegisterAddr
WORD
Start address of the register for the Modbus telegram
Input Const
tTimeUpdateSetp
TIME
TIME#0ms
Update interval for the processes affected by the input ‘xUpdateSetp’
Last updated

