Skip to content

Commit

Permalink
add rega api docs
Browse files Browse the repository at this point in the history
  • Loading branch information
firsttris committed Nov 28, 2023
1 parent f8aebae commit 2878fca
Show file tree
Hide file tree
Showing 2 changed files with 54 additions and 43 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ This project is built with a robust set of technologies to ensure high performan

The WebApp uses the same JSON-RPC interface as the CCU3.

To optimize performance we've tailored Rega Scripts with Github Copilot to fetch data in the exact structure required by our Webapp.
To optimize performance we've tailored [Rega Scripts with Github Copilot](/apps/ccu-addon-mui/src/rega) to fetch data in the exact structure required by our Webapp.

In addition, we are utilizing [React-Query](https://react-query.tanstack.com/), adhering to their best practices to ensure our data requests are as efficient as possible.

Expand Down
95 changes: 53 additions & 42 deletions apps/ccu-addon-mui/src/rega/rega.md
Original file line number Diff line number Diff line change
@@ -1,42 +1,53 @@
1. **Datapoints-Methoden in Rega**

- `ID()`: Die ID des Objekts.
- `Name()`: Der Name des Objekts.
- `TypeName()`: Der Typ des Objekts.
- `Value()`: Der Wert des Datenpunkts.
- `Timestamp()`: Der Zeitstempel des letzten Wertupdates.
- `Operations()`: Die verfügbaren Operationen für den Datenpunkt.
- `Unit()`: Die Einheit des Datenpunktwerts.
- `ValueType()`: Der Typ des Datenpunktwerts.
- `ValueList()`: Die Liste der möglichen Werte für den Datenpunkt.

2. **Channel-Attribute in Rega**

- `ID()`: Die ID des Objekts.
- `Name()`: Der Name des Objekts.
- `TypeName()`: Der Typ des Objekts.
- `Address()`: Die Adresse des Objekts.
- `Interface()`: Das Interface des Objekts.
- `HssType()`: Der Hss-Typ des Objekts.
- `DPs()`: Die Datenpunkte des Objekts.

3. **Room-Methoden in Rega**

- `ID()`: Gibt die ID des Objekts zurück.
- `Name()`: Gibt den Namen des Objekts zurück.
- `TypeName()`: Gibt den Typ des Objekts zurück.
- `EnumUsedIDs()`: Gibt eine Liste der IDs der untergeordneten Objekte zurück.
- `Add(ID)`: Fügt ein untergeordnetes Objekt hinzu.
- `Remove(ID)`: Entfernt ein untergeordnetes Objekt.
- `State()`: Gibt den Zustand des Objekts zurück.
- `IsTypeOf(TypeName)`: Überprüft, ob das Objekt vom angegebenen Typ ist.

4. **Device-Methoden in Rega**

- `ID()`: Gibt die ID des Objekts zurück.
- `Name()`: Gibt den Namen des Objekts zurück.
- `TypeName()`: Gibt den Typ des Objekts zurück.
- `Address()`: Gibt die Adresse des Objekts zurück.
- `Interface()`: Gibt das Interface des Objekts zurück.
- `HssType()`: Gibt den Hss-Typ des Objekts zurück.
- `DPs()`: Gibt die Datenpunkte des Objekts zurück.
# Homematic Rega - Unofficial API Reverse Engineered by GitHub Copilot

Rega is a proprietary, object-oriented scripting language developed specifically for the HomeMatic CCU. This document provides an unofficial API documentation, detailing the methods and attributes associated with datapoints, channels, rooms, and devices in Rega.

## Glossary

- **Datapoint**: A datapoint represents a specific piece of data or functionality of a device, such as a temperature reading or a switch state.
- **Channel**: A channel groups related datapoints together. For example, a device might have separate channels for different functionalities.
- **Room**: A room is a logical grouping of devices, typically representing a physical room in a building.
- **Device**: A device represents a physical device in the HomeMatic system, such as a sensor or an actuator.

## Datapoint Methods in Rega

- `ID()`: Returns the ID of the object.
- `Name()`: Returns the name of the object.
- `TypeName()`: Returns the type of the object.
- `Value()`: Returns the value of the datapoint.
- `Timestamp()`: Returns the timestamp of the last value update.
- `Operations()`: Returns the available operations for the datapoint.
- `Unit()`: Returns the unit of the datapoint value.
- `ValueType()`: Returns the type of the datapoint value.
- `ValueList()`: Returns the list of possible values for the datapoint.

## Channel Attributes in Rega

- `ID()`: Returns the ID of the object.
- `Name()`: Returns the name of the object.
- `TypeName()`: Returns the type of the object.
- `Address()`: Returns the address of the object.
- `Interface()`: Returns the interface of the object.
- `HssType()`: Returns the Hss type of the object.
- `DPs()`: Returns the datapoints of the object.

## Room Methods in Rega

- `ID()`: Returns the ID of the object.
- `Name()`: Returns the name of the object.
- `TypeName()`: Returns the type of the object.
- `EnumUsedIDs()`: Returns a list of IDs of the subordinate objects.
- `Add(ID)`: Adds a subordinate object.
- `Remove(ID)`: Removes a subordinate object.
- `State()`: Returns the state of the object.
- `IsTypeOf(TypeName)`: Checks if the object is of the specified type.

## Device Methods in Rega

- `ID()`: Returns the ID of the object.
- `Name()`: Returns the name of the object.
- `TypeName()`: Returns the type of the object.
- `Address()`: Returns the address of the object.
- `Interface()`: Returns the interface of the object.
- `HssType()`: Returns the Hss type of the object.
- `DPs()`: Returns the datapoints of the object.

0 comments on commit 2878fca

Please sign in to comment.