# H1\_4DI2DOR\_3P

## `H1_4DI2DOR_3P` (FB)

FUNCTION\_BLOCK H1\_4DI2DOR\_3P EXTENDS SlaveModuleDipSwitchOverwrite IMPLEMENTS ISlaveModule

InOut:

| Scope       | Name                                     | Type             | Initial      | Comment                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             | Inherited from                |
| ----------- | ---------------------------------------- | ---------------- | ------------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------- |
| Input       | `itfModbusConnector`                     | IModbusConnector |              |                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     | BaseSlave                     |
| Output      | `xInitRunning`                           | `BOOL`           |              | <p><code>xInitRunning</code> ist <code>TRUE</code>, solange die Initialisierung<br>beim Ersten Start durchgeühr wird.</p>                                                                                                                                                                                                                                                                                                                                                                                                                           | BaseSlave                     |
| Output      | `xInitFinished`                          | `BOOL`           |              | <p><code>xInitFinished</code> ist <code>TRUE</code>, sobald beim Ersten Start<br>alle Parameter an das Modul gesendet sind.</p>                                                                                                                                                                                                                                                                                                                                                                                                                     | BaseSlave                     |
| Output      | `xAlarmCom`                              | `BOOL`           |              | <p><code>xAlarmCom</code> ist <code>TRUE</code>, wenn es einen<br>Kommunikationsfehler gibt.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                    | BaseSlave                     |
| Output      | `xBusy`                                  | `BOOL`           |              | <p><code>xBusy</code> ist <code>TRUE</code>, wenn ein Modbus Request ausgeführt<br>wird.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                        | BaseSlave                     |
| Output      | `usiConfiguredSlaveID`                   | `USINT`          |              | Zeigt die aktuell eingestellte Slave-ID an                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          | BaseSlave                     |
| Output      | `eError`                                 | ERROR            |              | Kein Fehler = `ERROR.No_Error`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      | BaseSlave                     |
| Output      | `stDebugOutput`                          | DebugOutput      |              |                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     | BaseSlave                     |
| Input       | `xEnable`                                | `BOOL`           | TRUE         | <p>Deaktiviert das Modul und setzt alle Ausgänge auf den<br>Standard Initialisierungswert zurück</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                | BaseSlaveModule               |
| Input       | `xReinitModule`                          | `BOOL`           |              | <p>Reinitialisiert das Modul und sendet alle Parameter an das<br>Modul</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                          | BaseSlaveModule               |
| Input       | `xResetModule`                           | `BOOL`           |              | <p>Setzt das Modul zurück, löscht den EEPROM Speichert, führt<br>einen Lampentest durch und startet das Modul neu (Achtung:<br>Danach ist Autobauding wieder aktiviert)</p>                                                                                                                                                                                                                                                                                                                                                                         | BaseSlaveModule               |
| Output      | `wFirmware`                              | `WORD`           |              | Zeigt die aktuelle Firmware des Modules an                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          | BaseSlaveModule               |
| Output      | `xAuto`                                  | `BOOL`           |              | <p><code>FALSE</code> = Mindestens ein Eingang und/oder ein Ausgang sind<br>im Zustand <code>eManBin <> eManBin.Auto</code>. <code>TRUE</code> = Alle<br>Eingänge und Ausgänge haben den Zustand eManBin =<br>eManBin.Auto (Hinweis: Falls das Übersteuern mittels Dip-<br>Schalter (Hardware) deaktiviert ist und der Ausgang im<br>Zustand <code>eManBin <> eManBin.Auto</code>, bleibt xAuto weiterhin<br><code>TRUE</code>. Auswertung erfolgt je Ausgang. )</p>                                                                                | BaseSlaveModule               |
| Output      | `xAutoSoftware`                          | `BOOL`           |              | <p><code>FALSE</code> = Mindestens ein Eingang und/oder Ausgang sind<br>mittels Parameter (Software) im Zustand <code>eManBin <>\<br/>eManBin.Auto</code>. <code>TRUE</code> = Alle Eingänge und Ausgänge sind<br>mittels Parameter (Software) im Zustand <code>eManBin =\<br/>eManBin.Auto</code>.</p>                                                                                                                                                                                                                                             | SlaveModuleSoftOverwrite      |
| Output      | `xAutoHardware`                          | `BOOL`           |              | <p><code>FALSE</code> = Mindestens ein Eingang und/oder Ausgang sind<br>mittels Dip-Schalter (Hardware) im Zustand <code>eManBin <>\<br/>eManBin.Auto</code>. <code>TRUE</code> = Alle Eingänge und Ausgänge sind<br>mittels Dip-Schalter (Hardware) im Zustand <code>eManBin =\<br/>eManBin.Auto</code>. (Hinweis: Falls das Übersteuern mittels Dip-<br>Schalter (Hardware) deaktiviert ist und der Ausgang im<br>Zustand <code>eManBin <> eManBin.Auto</code>, bleibt xAuto weiterhin<br><code>TRUE</code>. Auswertung erfolgt je Ausgang. )</p> | SlaveModuleDipSwitchOverwrite |
| Input Const | `eDI4_ManBin`                            | eManBin          | eManBin.Auto | Manuelle Übersteuerung des digitalen Eingangs                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |                               |
| Input Const | `xDI4Negation`                           | `BOOL`           | FALSE        | Negation                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |                               |
| Input Const | `xDI4_ACVoltageMode`                     | `BOOL`           |              | <p><code>TRUE</code> = Aktiviert eine Verzögerung des Eingangs mit dem<br>definierten Wert von <code>tACModeInputVoltageDelay</code>. <code>FALSE</code><br>= Keine Verzögerung</p>                                                                                                                                                                                                                                                                                                                                                                 |                               |
| Input Const | `eDI3_ManBin`                            | eManBin          | eManBin.Auto | Manuelle Übersteuerung des digitalen Eingangs                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |                               |
| Input Const | `xDI3Negation`                           | `BOOL`           | FALSE        | Negation                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |                               |
| Input Const | `xDI3_ACVoltageMode`                     | `BOOL`           |              | <p><code>TRUE</code> = Aktiviert eine Verzögerung des Eingangs mit dem<br>definierten Wert von <code>tACModeInputVoltageDelay</code>. <code>FALSE</code><br>= Keine Verzögerung</p>                                                                                                                                                                                                                                                                                                                                                                 |                               |
| Input Const | `eDI2_ManBin`                            | eManBin          | eManBin.Auto | Manuelle Übersteuerung des digi3talen Eingangs                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |                               |
| Input Const | `xDI2Negation`                           | `BOOL`           | FALSE        | Negation                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |                               |
| Input Const | `xDI2_ACVoltageMode`                     | `BOOL`           |              | <p><code>TRUE</code> = Aktiviert eine Verzögerung des Eingangs mit dem<br>definierten Wert von <code>tACModeInputVoltageDelay</code>. <code>FALSE</code><br>= Keine Verzögerung</p>                                                                                                                                                                                                                                                                                                                                                                 |                               |
| Input Const | `eDI1_ManBin`                            | eManBin          | eManBin.Auto | Manuelle Übersteuerung des digitalen Eingangs                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |                               |
| Input Const | `xDI1Negation`                           | `BOOL`           | FALSE        | Negation                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |                               |
| Input Const | `xDI1_ACVoltageMode`                     | `BOOL`           |              | <p><code>TRUE</code> = Aktiviert eine Verzögerung des Eingangs mit dem<br>definierten Wert von <code>tACModeInputVoltageDelay</code>. <code>FALSE</code><br>= Keine Verzögerung</p>                                                                                                                                                                                                                                                                                                                                                                 |                               |
| Input Const | `eCh2_ManNum`                            | eManNum          | eManNum.Auto |                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |                               |
| Input Const | `rCh2_ManualTargetPosition`              | `REAL`           |              |                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |                               |
| Input Const | `tCh2_DelayTimeFromForwardToBack`        | `TIME`           | TIME#2s0ms   | Verzögerungszeit VOR –> ZURÜCK für Channel 2                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |                               |
| Input Const | `tCh2_DelayTimeFromCloseToOpen`          | `TIME`           | TIME#2s0ms   | Verzögerungszeit ZU –> AUF für Channel 2                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |                               |
| Input Const | `tCh2_OpenRuntimeDurationOversteering`   | `TIME`           | TIME#0ms     | <p>Übersteuerung der Laufzeit DO4 (In Richtung AUF) für Channel<br>2</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |                               |
| Input Const | `tCh2_CloseRuntimeDurationUndersteering` | `TIME`           | TIME#0ms     | <p>Untersteuerung der Laufzeit DO3 (In Richtung ZU) für Channel<br>2</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |                               |
| Input Const | `tCh2_OpenRuntimeDuration`               | `TIME`           | TIME#1m0s0ms | Vorgabe Laufzeit DO4 (AUF) für Channel 2                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |                               |
| Input Const | `tCh2_CloseRuntimeDuration`              | `TIME`           | TIME#1m0s0ms | Vorgabe Laufzeit DO3 (ZU) für Channel 2                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |                               |
| Input Const | `xCh2_EnableControl`                     | `BOOL`           | TRUE         | <p>Channel 2 (DO3 und DO4) kann mittels Handübersteuerung und<br>Busansteuerung freigegeben werden</p>                                                                                                                                                                                                                                                                                                                                                                                                                                              |                               |
| Input Const | `xCh2_DO4_DeactivateDipSwitch`           | `BOOL`           |              | <p><code>TRUE</code> = Hardware Handübersteuerung des Digitalen Ausgangs<br>DO4 (AUF) des Channels 2 deaktiviert</p>                                                                                                                                                                                                                                                                                                                                                                                                                                |                               |
| Input Const | `xCh2_DO3_DeactivateDipSwitch`           | `BOOL`           |              | <p><code>TRUE</code> = Hardware Handübersteuerung des Digitalen Ausgangs<br>DO3 (ZU) des Channels 2 deaktiviert</p>                                                                                                                                                                                                                                                                                                                                                                                                                                 |                               |
| Input Const | `eCh1_ManNum`                            | eManNum          | eManNum.Auto |                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |                               |
| Input Const | `rCh1_ManualTargetPosition`              | `REAL`           |              |                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |                               |
| Input Const | `tCh1_DelayTimeFromForwardToBack`        | `TIME`           | TIME#2s0ms   | Verzögerungszeit VOR –> ZURÜCK für Channel 1                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |                               |
| Input Const | `tCh1_DelayTimeFromCloseToOpen`          | `TIME`           | TIME#2s0ms   | Verzögerungszeit ZU –> AUF für Channel 1                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |                               |
| Input Const | `tCh1_OpenRuntimeDurationOversteering`   | `TIME`           | TIME#0ms     | <p>Übersteuerung der Laufzeit DO4 (In Richtung AUF) für Channel<br>1</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |                               |
| Input Const | `tCh1_CloseRuntimeDurationUndersteering` | `TIME`           | TIME#0ms     | <p>Untersteuerung der Laufzeit DO3 (In Richtung ZU) für Channel<br>1</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |                               |
| Input Const | `tCh1_OpenRuntimeDuration`               | `TIME`           | TIME#1m0s0ms | Vorgabe Laufzeit DO2 (AUF) für Channel 1                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |                               |
| Input Const | `tCh1_CloseRuntimeDuration`              | `TIME`           | TIME#1m0s0ms | Vorgabe Laufzeit DO1 (ZU) für Channel 1                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |                               |
| Input Const | `xCh1_EnableControl`                     | `BOOL`           | TRUE         | <p>Channel 1 (DO1 und DO2) kann mittels Handübersteuerung und<br>Busansteuerung freigegeben werden</p>                                                                                                                                                                                                                                                                                                                                                                                                                                              |                               |
| Input Const | `xCh1_DO2_DeactivateDipSwitch`           | `BOOL`           |              | <p><code>TRUE</code> = Hardware Handübersteuerung des Digitalen Ausgangs<br>DO2 (AUF) des Channels 1 deaktiviert</p>                                                                                                                                                                                                                                                                                                                                                                                                                                |                               |
| Input Const | `xCh1_DO1_DeactivateDipSwitch`           | `BOOL`           |              | <p><code>TRUE</code> = Hardware Handübersteuerung des Digitalen Ausgangs<br>DO1 (ZU) des Channels 1 deaktiviert</p>                                                                                                                                                                                                                                                                                                                                                                                                                                 |                               |
| Input Const | `tACModeInputVoltageDelay`               | `TIME`           | TIME#100ms   | <p>Eine Änderung des Signals, das an einem DI anliegt, wird<br>erst nach Ablauf dieser Zeit erkannt. (Wird nur verwendet<br>wenn <code>xDI1\_ACVoltageMode</code> <code>TRUE</code> ist,<br><code>xDI2\_ACVoltageMode</code> <code>TRUE</code> ist, <code>xDI3\_ACVoltageMode</code><br><code>TRUE</code> ist oder <code>xDI4\_ACVoltageMode</code> <code>TRUE</code> )</p>                                                                                                                                                                         |                               |
| Input Const | `tReadFeedback`                          | `TIME`           | TIME#3s0ms   | <p>Abfragezeit für Rückmeldungen der digitalen Eingänge und der<br>Handübersteuerung. (Hinweis: Die Abfragezeit darf nicht<br>größer als die Zeit von <code>tBusTimeout</code> sein.)</p>                                                                                                                                                                                                                                                                                                                                                           |                               |
| Input Const | `tSendDelayAfterInit`                    | `TIME`           | TIME#10s0ms  | Verzögerung zum Versenden der Ausgänge                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              |                               |
| Input Const | `tReadInputs`                            | `TIME`           | TIME#1s0ms   | <p>Abfragezeit für digitale Eingänge (Hinweis: Die Abfragezeit<br>darf nicht größer als die Zeit von <code>tBusTimeout</code> sein.)</p>                                                                                                                                                                                                                                                                                                                                                                                                            |                               |
| Input Const | `tBusTimeout`                            | `TIME`           | TIME#20s0ms  | `T#0s` = Kein Bus-Timeout = Kein SafeState Modus                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |                               |
| Input Const | `usiSlaveID`                             | `USINT`          | 10           | Die Slave-Adresse für das Modul                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |                               |
| Input       | `xCh1_TriggerInitializeClose`            | `BOOL`           |              | Anforderung Initialfahrt auf 0% für Channel 1                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |                               |
| Input       | `xCh1_TriggerInitializeOpen`             | `BOOL`           |              | Anforderung Initialfahrt auf 100% für Channel 1                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |                               |
| Input       | `xCh2_TriggerInitializeClose`            | `BOOL`           |              | Anforderung Initialfahrt auf 0% für Channel 2                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |                               |
| Input       | `xCh2_TriggerInitializeOpen`             | `BOOL`           |              | Anforderung Initialfahrt auf 100% für Channel 2                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |                               |
| Input       | `rCh1_TargetPosition`                    | `REAL`           |              | Zielposition für Channel 1 in %                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |                               |
| Input       | `rCh2_TargetPosition`                    | `REAL`           |              | Zielposition für Channel 2 in %                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |                               |
| Output      | `xCh1_DO1_Fb`                            | `BOOL`           |              | <p>Rückmeldung des Digitalen Ausgang DO1 (ZU) für Channel 1.<br>Beachtet die Auswertung der Handübersteuerung. Tatsächlicher<br>Wert - LED Aktiv = <code>TRUE</code>, LED Inaktiv = <code>FALSE</code><br>(Abfrage erfolgt im Interval der Angebenen Zeit von<br><code>tReadFeedback</code>)</p>                                                                                                                                                                                                                                                    |                               |
| Output      | `xCh1_DO2_Fb`                            | `BOOL`           |              | <p>Rückmeldung des Digitalen Ausgang DO2 (AUF) für Channel 1.<br>Beachtet die Auswertung der Handübersteuerung. Tatsächlicher<br>Wert - LED Aktiv = <code>TRUE</code>, LED Inaktiv = <code>FALSE</code><br>(Abfrage erfolgt im Interval der Angebenen Zeit von<br><code>tReadFeedback</code>)</p>                                                                                                                                                                                                                                                   |                               |
| Output      | `xCh2_DO3_Fb`                            | `BOOL`           |              | <p>Rückmeldung des Digitalen Ausgang DO3 (ZU) für Channel 2.<br>Beachtet die Auswertung der Handübersteuerung. Tatsächlicher<br>Wert - LED Aktiv = <code>TRUE</code>, LED Inaktiv = <code>FALSE</code><br>(Abfrage erfolgt im Interval der Angebenen Zeit von<br><code>tReadFeedback</code>)</p>                                                                                                                                                                                                                                                    |                               |
| Output      | `xCh2_DO4_Fb`                            | `BOOL`           |              | <p>Rückmeldung des Digitalen Ausgang DO4 (AUF) für Channel 2.<br>Beachtet die Auswertung der Handübersteuerung. Tatsächlicher<br>Wert - LED Aktiv = <code>TRUE</code>, LED Inaktiv = <code>FALSE</code><br>(Abfrage erfolgt im Interval der Angebenen Zeit von<br><code>tReadFeedback</code>)</p>                                                                                                                                                                                                                                                   |                               |
| Output      | `rCh1_CurrentPosition`                   | `REAL`           |              | <p>Aktuelle Position in % für Channel 1 (Abfrage erfolgt im<br>Interval der Angebenen Zeit von <code>tReadFeedback</code>)</p>                                                                                                                                                                                                                                                                                                                                                                                                                      |                               |
| Output      | `rCh2_CurrentPosition`                   | `REAL`           |              | <p>Aktuelle Position in % für Channel 2 (Abfrage erfolgt im<br>Interval der Angebenen Zeit von <code>tReadFeedback</code>)</p>                                                                                                                                                                                                                                                                                                                                                                                                                      |                               |
| Output      | `eCh1_State`                             | ChannelState     |              | <p>Status für Channel 1 (Abfrage erfolgt im Interval der<br>Angebenen Zeit von <code>tReadFeedback</code>)</p>                                                                                                                                                                                                                                                                                                                                                                                                                                      |                               |
| Output      | `eCh2_State`                             | ChannelState     |              | <p>Status für Channel 2 (Abfrage erfolgt im Interval der<br>Angebenen Zeit von <code>tReadFeedback</code>)</p>                                                                                                                                                                                                                                                                                                                                                                                                                                      |                               |
| Output      | `tCh1_TimeRunSinceLastControl`           | `TIME`           |              | <p>Laufzeit seit letzter Ansteuerung von Channel 1 (Info: Bei<br>Handübersteuerung, läuft die Zeit weiter. Abfrage erfolgt im<br>Interval der Angebenen Zeit von <code>tReadFeedback</code>)</p>                                                                                                                                                                                                                                                                                                                                                    |                               |
| Output      | `tCh2_TimeRunSinceLastControl`           | `TIME`           |              | <p>Laufzeit seit letzter Ansteuerung von Channel 2 (Info: Bei<br>Handübersteuerung, läuft die Zeit weiter. Abfrage erfolgt im<br>Interval der Angebenen Zeit von <code>tReadFeedback</code>)</p>                                                                                                                                                                                                                                                                                                                                                    |                               |
| Output      | `eCh1ManualPosition`                     | eManPosition     |              | <p>Dip Schalter Position Channel 1 (Abfrage erfolgt im Interval<br>der Angebenen Zeit von <code>tReadFeedback</code>)</p>                                                                                                                                                                                                                                                                                                                                                                                                                           |                               |
| Output      | `eCh2ManualPosition`                     | eManPosition     |              | <p>Dip Schalter Position Channel 2 (Abfrage erfolgt im Interval<br>der Angebenen Zeit von <code>tReadFeedback</code>)</p>                                                                                                                                                                                                                                                                                                                                                                                                                           |                               |
| Output      | `xDI1`                                   | `BOOL`           |              | <p>Digitaler Eingang (Abfrage erfolgt im Interval der Angebenen<br>Zeit von <code>tReadInputs</code>)</p>                                                                                                                                                                                                                                                                                                                                                                                                                                           |                               |
| Output      | `xDI2`                                   | `BOOL`           |              | <p>Digitaler Eingang (Abfrage erfolgt im Interval der Angebenen<br>Zeit von <code>tReadInputs</code>)</p>                                                                                                                                                                                                                                                                                                                                                                                                                                           |                               |
| Output      | `xDI3`                                   | `BOOL`           |              | <p>Digitaler Eingang (Abfrage erfolgt im Interval der Angebenen<br>Zeit von <code>tReadInputs</code>)</p>                                                                                                                                                                                                                                                                                                                                                                                                                                           |                               |
| Output      | `xDI4`                                   | `BOOL`           |              | <p>Digitaler Eingang (Abfrage erfolgt im Interval der Angebenen<br>Zeit von <code>tReadInputs</code>)</p>                                                                                                                                                                                                                                                                                                                                                                                                                                           |                               |


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://support.powerio.com/hub/codesys-hvac/hvac-modbusio2-lib/funktionsbausteine/h1_4di2dor_3p.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
