This repository has been archived by the owner on May 7, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 782
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
PercentageChannel: Return value between min and max. Homie: Remove ha…
…ndling completely. Readme: Add retain and isCommand and some more mqtt1 details. Rollershutter: Fix Signed-off-by: David Graeff <david.graeff@web.de>
- Loading branch information
David Graeff
committed
Jan 11, 2019
1 parent
7263489
commit 0c153b3
Showing
12 changed files
with
171 additions
and
171 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
87 changes: 87 additions & 0 deletions
87
...nding/org.eclipse.smarthome.binding.mqtt.generic/ESH-INF/config/dimmer-channel-config.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<config-description:config-descriptions | ||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xmlns:config-description="http://eclipse.org/smarthome/schemas/config-description/v1.0.0" | ||
xsi:schemaLocation="http://eclipse.org/smarthome/schemas/config-description/v1.0.0 http://eclipse.org/smarthome/schemas/config-description-1.0.0.xsd"> | ||
|
||
<config-description uri="thing-type:mqtt:dimmer_channel"> | ||
<parameter-group name="transformations"> | ||
<label>Transform values</label> | ||
<description>These configuration parameters allow you to alter a value before it is published to MQTT or before a received value is assigned to an item.</description> | ||
<advanced>true</advanced> | ||
</parameter-group> | ||
|
||
<parameter name="stateTopic" type="text"> | ||
<label>MQTT state topic</label> | ||
<description>An MQTT topic that this thing will subscribe to, to receive the state. This can be left empty, the channel will be state-less command-only channel.</description> | ||
</parameter> | ||
<parameter name="commandTopic" type="text"> | ||
<label>MQTT command topic</label> | ||
<description>An MQTT topic that this thing will send a command to. If not set, this will be a read-only switch.</description> | ||
</parameter> | ||
<parameter name="transformationPattern" type="text" groupName="transformations"> | ||
<label>Incoming value transformations</label> | ||
<description><![CDATA[ | ||
Applies transformations to an incoming MQTT topic value. | ||
A transformation example for a received JSON would be "JSONPATH:$.device.status.temperature" for | ||
a json {device: {status: { temperature: 23.2 }}}. | ||
You can chain transformations by separating them with the intersection character ∩. | ||
]]></description> | ||
<advanced>true</advanced> | ||
</parameter> | ||
<parameter name="transformationPatternOut" type="text" groupName="transformations"> | ||
<label>Outgoing value transformation</label> | ||
<description><![CDATA[ | ||
Applies a transformation before publishing a MQTT topic value. | ||
Transformations are specialised in extracting a value, but some transformations like | ||
the MAP one could be useful. | ||
]]></description> | ||
<advanced>true</advanced> | ||
</parameter> | ||
<parameter name="formatBeforePublish" type="text" groupName="transformations"> | ||
<label>Outgoing value format</label> | ||
<description><![CDATA[ | ||
Format a value before it is published to the MQTT broker. | ||
The default is to just pass the channel/item state. | ||
If you want to apply a prefix, say "MYCOLOR,", you would use "MYCOLOR,%s". | ||
If you want to adjust the precision of a number to for example 4 digits, you would use "%.4f". | ||
]]></description> | ||
<advanced>true</advanced> | ||
<default>%s</default> | ||
</parameter> | ||
<parameter name="retained" type="boolean"> | ||
<label>Retained</label> | ||
<description>The value will be published to the command topic as retained message. A retained value stays on the broker and can even be seen by MQTT clients that are subscribing at a later point in time.</description> | ||
<default>false</default> | ||
<advanced>true</advanced> | ||
</parameter> | ||
|
||
<parameter name="min" type="decimal"> | ||
<label>Absolute minimum</label> | ||
<description>This configuration represents the minimum of the allowed range. For a percentage channel that equals zero percent.</description> | ||
</parameter> | ||
<parameter name="max" type="decimal"> | ||
<label>Absolute maximum</label> | ||
<description>This configuration represents the maximum of the allowed range. For a percentage channel that equals one-hundred percent.</description> | ||
</parameter> | ||
<parameter name="step" type="decimal"> | ||
<label>Delta value</label> | ||
<description>A number/dimmer channel can receive Increase/Decrease commands and computes the target number by adding or subtracting this delta value.</description> | ||
<default>1.0</default> | ||
<advanced>true</advanced> | ||
</parameter> | ||
<parameter name="on" type="text"> | ||
<label>Custom On/Open value</label> | ||
<description>A number (like 1, 10) or a string (like "enabled") that is additionally recognised as on/open state. You can use this parameter for a second keyword, next to ON (OPEN respectively on a Contact).</description> | ||
<default>1</default> | ||
</parameter> | ||
<parameter name="off" type="text"> | ||
<label>Custom Off/Closed value</label> | ||
<description>A number (like 0, -10) or a string (like "disabled") that is additionally recognised as off/closed state. You can use this parameter for a second keyword, next to OFF (CLOSED respectively on a Contact).</description> | ||
<default>0</default> | ||
</parameter> | ||
</config-description> | ||
</config-description:config-descriptions> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.