# ClockSlave32

## `ClockSlave32` (FB)

FUNCTION\_BLOCK ClockSlave32 EXTENDS Uhr\_Base IMPLEMENTS IUhr

### Kurzbeschreibung

> Slave - Funktionsbaustein für ein Uhrensystem mit 32 Wochenuhren, 30 Feiertagen, 10 Ferienperioden und 5 Sonderschaltzeiten.

### Darstellung

<figure><img src="/files/Lw2NcrhmmFfzC1pNXC0W" alt=""><figcaption></figcaption></figure>

### Funktionsbeschreibung

#### Allgemeines

Dieser Funktionsbaustein dient als Slave - Funktionsbaustein für ein Uhrensystem mit 32 Wochenuhren, 30 Feiertagen, 10 Ferienperioden und 5 Sonderschaltzeiten.\
Er erlaubt die individuelle Aktivierung / Deaktivierung der 32 Wochenuhrkanäle, des Feiertagekanals, des Ferienkanals sowie des Sonderschaltzeitenkanals (FALSE = Deaktivierung, TRUE = Aktivierung).\
Die Verbindung zwischen dem Master - Funktionsbaustein und den Slave - Funktionsbausteinen wird dabei über den Ausgang *itfToClockSlave32* bzw. die Eingänge *itfFromClockMaster32* hergestellt.\
Die Eingänge *sTitle* bzw. *sLine1* erlauben die Festlegung der Bezeichnung des Titels bzw. der Zeile 1 in der Visualisierung.

#### Zustand des Slave - Kanals *xActive*

Der Ausgang *xActive* (FALSE = nicht aktiv, TRUE = aktiv) wird durch die aktuellen Zustände der **zugeordneten** Wochenuhrkanäle (**xClockCH\_01** bis **xClockCH\_32** = TRUE) des **zugeordneten** Feiertagekanals (**xPublicHoliday** = TRUE), des **zugeordneten** Ferienkanals (**xHoliday** = TRUE) bzw. des **zugeordneten** Sonderschaltzeitenkanals (**xSwitchTimeS** = TRUE) wie folgt festgelegt (Hinweis: Kanäle, die nicht zugeordnet sind, nehmen automatisch den Zustand FALSE an):

| Wochenuhrkanäle | Feiertagekanal | Ferienkanal | Sonderschaltzeitenkanal | Zentrale Aktivierung (Master) | Zentrale Deaktivierung (Master) | *xActive* | Hinweise                          |
| --------------- | -------------- | ----------- | ----------------------- | ----------------------------- | ------------------------------- | --------- | --------------------------------- |
| FALSE           | FALSE          | FALSE       | FALSE                   | FALSE                         | FALSE                           | FALSE     | Normalbetrieb - Aus               |
| TRUE            | FALSE          | FALSE       | FALSE                   | FALSE                         | FALSE                           | TRUE      | Normalbetrieb - Ein               |
| X               | TRUE           | FALSE       | FALSE                   | FALSE                         | FALSE                           | FALSE     | Feiertagebetrieb - Ein            |
| X               | FALSE          | TRUE        | FALSE                   | FALSE                         | FALSE                           | FALSE     | Ferienbetrieb - Ein               |
| X               | X              | X           | TRUE                    | FALSE                         | FALSE                           | TRUE      | Sonderschaltzeitenbetrieb - Ein   |
| X               | X              | X           | X                       | TRUE                          | FALSE                           | TRUE      | Zentrale Aktivierung ( Master )   |
| X               | X              | X           | X                       | X                             | TRUE                            | FALSE     | Zentrale Deaktivierung ( Master ) |

Legende: X = beliebig

#### Zentrale Aufhebung aller Zuordnungen **xResetAssignment**

Dieser Sollwert / Parameter dient zur zentralen Aufhebung aller im Slave - Funktionsbaustein erfolgten Zuordnungen.

### Visualisierung

#### Darstellung

<figure><img src="/files/hF2FKfIFYbD4i1lNabYF" alt=""><figcaption></figcaption></figure>

#### Schnittstellen Visu-Element

| Name                  | Datentyp      | Typ          | Initialwert | Funktion                                                                                                                                                                                                                                      |
| --------------------- | ------------- | ------------ | ----------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **FB\_ClockSlave32**  | ClockSlave32  | VAR\_IN\_OUT |             | Hier FB ClockSlave32 eintragen Bsp. PRG.ClockSlave32                                                                                                                                                                                          |
| **FB\_ClockMaster32** | ClockMaster32 | VAR\_IN\_OUT |             | Hier zugehörigen(!) FB ClockMaster32 eintragen Bsp. PRG.ClockMaster32                                                                                                                                                                         |
| **BMS\_Active**       | BOOL          | VAR\_INPUT   |             | BMS (Building Management System) GLT (Gebäudeleittechnik). Wenn BMS\_Active = TRUE wird die Eingabe / Editierung der Uhren deaktiviert da diese dann nur über das BMS eingestellt werden können. Uhrzeiten können dann nur angeschaut werden. |

\
Hinweis: VAR\_IN\_OUT Schnittstellen müssen belegt werden, VAR\_INPUT sind optional.

### CODESYS

InOut:

| Scope       | Name                   | Type           | Initial | Inherited from |
| ----------- | ---------------------- | -------------- | ------- | -------------- |
| Input       | `itfFromClockMaster32` | `IUhrProtocol` |         | Uhr\_Base      |
| Input       | `sTitle`               | `STRING`       |         |                |
| Input       | `sLine1`               | `STRING`       |         |                |
| Input       | `sLine2`               | `STRING`       |         |                |
| Input Const | `ClockSlvPara`         | stSlvClockData |         |                |
| Input Const | `xSwitchTimeS`         | `BOOL`         |         |                |
| Input Const | `xPublicHoliday`       | `BOOL`         |         |                |
| Input Const | `xHoliday`             | `BOOL`         |         |                |
| Input Const | `xClockCH_32`          | `BOOL`         |         |                |
| Input Const | `xClockCH_31`          | `BOOL`         |         |                |
| Input Const | `xClockCH_30`          | `BOOL`         |         |                |
| Input Const | `xClockCH_29`          | `BOOL`         |         |                |
| Input Const | `xClockCH_28`          | `BOOL`         |         |                |
| Input Const | `xClockCH_27`          | `BOOL`         |         |                |
| Input Const | `xClockCH_26`          | `BOOL`         |         |                |
| Input Const | `xClockCH_25`          | `BOOL`         |         |                |
| Input Const | `xClockCH_24`          | `BOOL`         |         |                |
| Input Const | `xClockCH_23`          | `BOOL`         |         |                |
| Input Const | `xClockCH_22`          | `BOOL`         |         |                |
| Input Const | `xClockCH_21`          | `BOOL`         |         |                |
| Input Const | `xClockCH_20`          | `BOOL`         |         |                |
| Input Const | `xClockCH_19`          | `BOOL`         |         |                |
| Input Const | `xClockCH_18`          | `BOOL`         |         |                |
| Input Const | `xClockCH_17`          | `BOOL`         |         |                |
| Input Const | `xClockCH_16`          | `BOOL`         |         |                |
| Input Const | `xClockCH_15`          | `BOOL`         |         |                |
| Input Const | `xClockCH_14`          | `BOOL`         |         |                |
| Input Const | `xClockCH_13`          | `BOOL`         |         |                |
| Input Const | `xClockCH_12`          | `BOOL`         |         |                |
| Input Const | `xClockCH_11`          | `BOOL`         |         |                |
| Input Const | `xClockCH_10`          | `BOOL`         |         |                |
| Input Const | `xClockCH_09`          | `BOOL`         |         |                |
| Input Const | `xClockCH_08`          | `BOOL`         |         |                |
| Input Const | `xClockCH_07`          | `BOOL`         |         |                |
| Input Const | `xClockCH_06`          | `BOOL`         |         |                |
| Input Const | `xClockCH_05`          | `BOOL`         |         |                |
| Input Const | `xClockCH_04`          | `BOOL`         |         |                |
| Input Const | `xClockCH_03`          | `BOOL`         |         |                |
| Input Const | `xClockCH_02`          | `BOOL`         |         |                |
| Input Const | `xClockCH_01`          | `BOOL`         |         |                |
| Input Const | `xResetAssignment`     | `BOOL`         | FALSE   |                |
| Output      | `xClockActive`         | `BOOL`         |         |                |
| Output      | `todTodayTON`          | `TOD`          |         |                |
| Output      | `todTodayTOF`          | `TOD`          |         |                |


---

# 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-library/functionblocks/clock/clockslave32.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.
