Add a link to the transformation add-ons page (#2351)

Signed-off-by: Jimmy Tanagra <jcode@tanagra.id.au>
pull/2356/head
jimtng 2024-08-20 03:17:53 +10:00 committed by GitHub
parent b6546de886
commit 45628b8920
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 9 additions and 5 deletions

View File

@ -14,11 +14,15 @@ They are often useful, to **interpret received Item values**, like sensor readin
- Processing of a raw Item value, e.g., Parsing a number from a JSON string, like `{ "temperature": 23.2 }`
- Conversion of sensor readings, e.g., temperature in degree Celsius can be converted to degree Fahrenheit
## Installation
Transformations are performed by Transformation Services which are available as [transformation add-ons](/addons/#transform).
The relevant add-on needs to be installed via the Main UI or addons.cfg before use.
## Usage
Transformations are applicable in Item and Sitemap element labels and inside DSL rules.
The relevant transformation service needs to be installed via the Main UI or addons.cfg before use.
Be aware, that some Transformation services rely on transformation files, while others work by directly providing the transformation logic.
Some Transformation services rely on transformation files, while others work by directly providing the transformation logic.
Transformation files need to be placed in the directory `$OPENHAB_CONF/transform`.
1. Item and Sitemap Labels
@ -37,7 +41,7 @@ Transformation files need to be placed in the directory `$OPENHAB_CONF/transform
Usage of Transformations in the [label parameter of Sitemap elements]({{base}}/ui/sitemaps.html#element-type-text) works the same way.
1. Rules
2. Rules
Transformations can also be [used in rules]({{base}}/configuration/rules-dsl.html#transformations) to transform/translate/convert data.
The following shows three examples:
@ -48,12 +52,12 @@ Transformation files need to be placed in the directory `$OPENHAB_CONF/transform
var fahrenheit = transform("JS", "convert-C-to-F.js", temperature)
```
1. Bindings
3. Bindings
Transformations can sometimes be used in binding add-ons. For example, transforming an openHAB ON command into "action=powerup" for sending to a device.
If, and how, this use may be available is described in individual binding documentation.
1. Profiles
4. Profiles
Transformations can be associated with channels, working on data being passed between bindings and Items. See [profile documentation]({{base}}/configuration/items.html#profiles) for more detail.