# DAIKIN\_EKMBDXB7V1\_IDU\_FC16\_2000\_2191

## `DAIKIN_EKMBDXB7V1_IDU_FC16_2000_2191` (FB)

FUNCTION\_BLOCK DAIKIN\_EKMBDXB7V1\_IDU\_FC16\_2000\_2191

### Short description

> Change of setpoints - 1 of maximum 64 Daikin - indoor units\
> \
> Typical application: Central control of Daikin - indoor units via the Daikin Modbus - interface EKMBDXB7V1\\

#### Guidelines - Software creation

The following function codes (FC) are supported: 3, 4, 6 and 16\
The following baud rates are supported: 9600 and 19200 bit/s\
For addressing, use the address values, not the register addresses (Address = Register - 1)\
Modbus addresses 1 - 15 can be set directly on the DIP switches in the interface.\
In FC03 a maximum of 32 registers may be requested in one query telegram (deviating from the Modbus standard)\
In FC04 a maximum of 32 registers may be requested in one query telegram (deviating from the Modbus standard)\
In FC16 a maximum of 30 registers may be written in one query telegram (deviating from the Modbus standard)\
The following transmission parameters were tested: 19200 Baud, 8-N-1\
The interface supports the following exception codes: 0x81, 0x82 and 0x83\
The number of control commands per indoor unit is limited to 7000 / year!!!\
Taking the tested transmission parameters into account, the time interval between the end of the response telegram and the next query telegram must be at least 22.5 ms\
\
All registers read with FC04 are always available up to date\
All registers read with FC03 are available up to date only once during each restart of the gateway\
\
\&#xNAN;**\*\*\*\*\*\*\*\*\*\*\*\*\*\***\
\&#xNAN;**\* Functions \***\
\&#xNAN;**\*\*\*\*\*\*\*\*\*\*\*\*\*\***\
\
This FB collects and transmits the relevant setpoints of all up to 64 indoor units (FC16: addresses 2000 - 2191)\
The setpoints are provided in the array ‘arstIndoorUnits\_Setpoints\_1\_IN’ separately for each indoor unit as a structure element.\
The setpoints of an indoor unit are only updated if the corresponding read/write permission is present (input ‘arxIndoorUnits\_ReadWriteState’).\
\
Procedure for changing a setpoint (FC06 or FC16) (see DAIKIN documentation!!!)\
\\

1. Detection of changes to the current setpoints (compare array with index ‘\_IN’ with array with index ‘\_OLD’)\\

When setpoints change, the following additional steps are required:\
2\) Read current actual values (FC04: addresses 2000 - 2383) (store in array with index ‘\_CURRENT’)\
3\) Write current actual values as setpoints (FC16: addresses 2000 - 2191) (copy array with index ‘\_CURRENT’ into array with index ‘\_OUT’)\
4\) Write current setpoints (FC16: addresses 2000 - 2191) (copy array with index ‘\_IN’ into array with index ‘\_OUT’), (copy array with index ‘\_IN’ into array with index ‘\_OUT’)\
\\

InOut:

| Scope       | Name                                   | Type                                                              | Initial     | Comment                                                                                                                                                                                                                                                            |
| ----------- | -------------------------------------- | ----------------------------------------------------------------- | ----------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| Input       | `xEn`                                  | `BOOL`                                                            | TRUE        | Enable / disable of communication ( TRUE = enabled )                                                                                                                                                                                                               |
| Input       | `byUnitId`                             | `BYTE`                                                            | 0           | Device (interface) address (1 .. 15)                                                                                                                                                                                                                               |
| Input       | `xUpdateSetp`                          | `BOOL`                                                            | FALSE       | <p>Update of setpoints ( on each rising edge<br>)</p>                                                                                                                                                                                                              |
| Input       | `xCheckChanges`                        | `BOOL`                                                            | FALSE       | <p>Detection of changes in the array<br>‘arstIndoorUnits\_Setpoint\_Values\_1\_IN’ (on every<br>rising edge)</p>                                                                                                                                                   |
| Input       | `xResError`                            | `BOOL`                                                            | FALSE       | <p>Reinitialization of the output ‘eErrorCodeCom’ (on each<br>rising edge)</p>                                                                                                                                                                                     |
| Input       | `arxIndoorUnits_ReadWriteState`        | <p>ARRAY \[1..4, 0..15] OF<br>BOOL</p>                            |             | <p>Array with the read/write authorizations of the indoor units of all groups (1-00 … 4-15)<br>1st dimension: group, 2nd dimension: indoor unit number<br>Array element = FALSE: no read/write authorization<br>Array element = TRUE: read/write authorization</p> |
| Input       | `arstIndoorUnits_Setpoint_Values_1_IN` | <p>ARRAY \[1..4, 0..15] OF<br>EKMBDXB7V1\_SETPOINT\_VALUES\_1</p> |             | <p>Array with the relevant setpoints of the indoor units of all groups (1-00 … 4-15)<br>1st dimension: group, 2nd dimension: indoor unit number<br>Array element = structure with the setpoints</p>                                                                |
| Input       | `xResFilterSign`                       | `BOOL`                                                            | FALSE       | <p>Input for resetting the filter maintenance indicator on all<br>indoor units (TRUE = reset)</p>                                                                                                                                                                  |
| Inout       | `ModbusClient`                         | `ModbusClientBase`                                                |             | Client of the device                                                                                                                                                                                                                                               |
| Output      | `xAlarm`                               | `BOOL`                                                            | FALSE       | Collective fault ( TRUE = fault )                                                                                                                                                                                                                                  |
| Output      | `xAlarmCom`                            | `BOOL`                                                            | FALSE       | Collective fault - communication ( TRUE = fault )                                                                                                                                                                                                                  |
| Output      | `eErrorCodeCom`                        | ModbusErrorCode                                                   |             | Error code - communication ( 0 = no error )                                                                                                                                                                                                                        |
| Output      | `xBusy`                                | `BOOL`                                                            |             | Communication indicator ( TRUE = communication )                                                                                                                                                                                                                   |
| Input Const | `xEnFanControl`                        | `BOOL`                                                            | TRUE        | <p>General enable/disable of fan control for<br>all 64 indoor units (TRUE = enable)</p>                                                                                                                                                                            |
| Input Const | `tTimeCheckChanges`                    | `TIME`                                                            | TIME#1s0ms  | <p>Update interval for the processes affected by the input<br>‘xCheckChanges’</p>                                                                                                                                                                                  |
| Input Const | `tTimeUpdateSetp`                      | `TIME`                                                            | TIME#45s0ms | <p>Update interval for the processes affected by the input<br>‘xUpdateSetp’</p>                                                                                                                                                                                    |
