1 <?xml version="1.0" encoding="UTF-8"?>
2 <config-description:config-descriptions
3 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4 xmlns:config-description="https://openhab.org/schemas/config-description/v1.0.0"
5 xsi:schemaLocation="https://openhab.org/schemas/config-description/v1.0.0 https://openhab.org/schemas/config-description-1.0.0.xsd">
7 <config-description uri="thing-type:mqtt:rollershutter_channel">
8 <parameter-group name="transformations">
9 <label>Transform Values</label>
10 <description>These configuration parameters allow you to alter a value before it is published to MQTT or before a
11 received value is assigned to an item.</description>
12 <advanced>true</advanced>
15 <parameter name="stateTopic" type="text">
16 <label>MQTT State Topic</label>
17 <description>An MQTT topic that this thing will subscribe to, to receive the state. This can be left empty, the
18 channel will be state-less command-only channel.</description>
20 <parameter name="commandTopic" type="text">
21 <label>MQTT Command Topic</label>
22 <description>An MQTT topic that this thing will send a command to. If not set, this will be a read-only
23 rollershutter.</description>
25 <parameter name="transformationPattern" type="text" groupName="transformations">
26 <label>Incoming Value Transformations</label>
27 <description><![CDATA[
28 Applies transformations to an incoming MQTT topic value.
29 A transformation example for a received JSON would be "JSONPATH:$.device.status.temperature" for
30 a json {device: {status: { temperature: 23.2 }}}.
32 You can chain transformations by separating them with the intersection character ∩.
34 <advanced>true</advanced>
36 <parameter name="transformationPatternOut" type="text" groupName="transformations">
37 <label>Outgoing Value Transformation</label>
38 <description><![CDATA[
39 Applies a transformation before publishing a MQTT topic value.
41 Transformations are specialised in extracting a value, but some transformations like
42 the MAP one could be useful.
44 <advanced>true</advanced>
46 <parameter name="formatBeforePublish" type="text" groupName="transformations">
47 <label>Outgoing Value Format</label>
48 <description><![CDATA[
49 Format a value before it is published to the MQTT broker.
50 The default is to just pass the channel/item state.
52 If you want to apply a prefix, say "MYCOLOR,", you would use "MYCOLOR,%s".
53 If you want to adjust the precision of a number to for example 4 digits, you would use "%.4f".
55 <advanced>true</advanced>
58 <parameter name="qos" type="integer" min="0" max="2" required="false">
60 <description>MQTT QoS of this channel (0, 1, 2). Default is QoS of the broker connection.</description>
62 <option value="0">At most once (best effort delivery "fire and forget")</option>
63 <option value="1">At least once (guaranteed that a message will be delivered at least once)</option>
64 <option value="2">Exactly once (guarantees that each message is received only once by the counterpart)</option>
66 <advanced>true</advanced>
68 <parameter name="retained" type="boolean">
69 <label>Retained</label>
70 <description>The value will be published to the command topic as retained message. A retained value stays on the
71 broker and can even be seen by MQTT clients that are subscribing at a later point in time.</description>
72 <default>false</default>
73 <advanced>true</advanced>
75 <parameter name="postCommand" type="boolean">
76 <label>Is Command</label>
77 <description>If the received MQTT value should not only update the state of linked items, but command them, enable
78 this option.</description>
79 <default>false</default>
80 <advanced>true</advanced>
82 <parameter name="on" type="text">
83 <label>Up Command Value</label>
84 <description>A string (like "OPEN") that is sent when commanding the rollershutter to open. If not provided, 0 (or
85 100, if inverted) will be sent instead.</description>
86 <advanced>true</advanced>
88 <parameter name="off" type="text">
89 <label>Down Command Value</label>
90 <description>A string (like "CLOSE") that is sent when commanding the rollershutter to close. If not provided, 100
91 (or 0, if inverted) will be sent instead.</description>
92 <advanced>true</advanced>
94 <parameter name="stop" type="text">
95 <label>Stop Command</label>
96 <description>A string (like "STOP") that is sent when commanding the rollershutter to stop.</description>
97 <advanced>true</advanced>
99 <parameter name="onState" type="text">
100 <label>Up State Value</label>
101 <description>A string (like "OPENED") that is recognised as UP state. You can use this parameter for a second
102 keyword, next to UP. Defaults to the Up Command Value.</description>
103 <advanced>true</advanced>
105 <parameter name="offState" type="text">
106 <label>Down State Value</label>
107 <description>A string (like "CLOSED") that is recognised as DOWN state. You can use this parameter for a second
108 keyword, next to DOWN. Defaults to the Down Command Value.</description>
109 <advanced>true</advanced>
111 <parameter name="invert" type="boolean">
112 <label>Invert</label>
113 <description>Enable if your device uses 100 as UP and 0 as DOWN, instead of the normal openHAB convention of 0 as UP
114 and 100 as DOWN.</description>
115 <default>false</default>
116 <advanced>true</advanced>
118 <parameter name="transformExtentsToString" type="boolean">
119 <label>Transform Commands at Extents to String</label>
120 <description>If a command is 0 or 100, send that as UP or DOWN commands instead. Useful if your device doesn't
121 support going to a specific position - only opening or closing, but you have front ends (say HomeKit) or rules that
122 will only send percentage commands instead of UP/DOWN.
124 <default>false</default>
125 <advanced>true</advanced>
127 </config-description>
128 </config-description:config-descriptions>