Hallo Zusammen,
ich habe mir einige Shellys 2.5 gekauft und in mein FHEM eingebunden.
Nun würde ich gerne das ganze über TabletUI steuern und visualisieren. Ich weiß hier gibt es schon eine ganze menge Threads und Beiträge zu, aber leider hat mir nichts davon weitergeholfen. (Ich befürchte mein Problem ist etwas zu banal...)
Ich möchte gerne die Position meiner Rollladen visualisiert haben, leider funktioniert das nicht und ich sehe in TabletUi nix.
Hierzu verwende ich folgenden Code in Tablet UI.
Zitat<div data-type="symbol"
data-device="Rollo_Esszimmer"
data-get="position"
data-icons='["oa-fts_window_2w","oa-fts_shutter_10","oa-fts_shutter_20","oa-fts_shutter_30","oa-fts_shutter_40",
"oa-fts_shutter_50","oa-fts_shutter_60","oa-fts_shutter_70","oa-fts_shutter_80",
"oa-fts_shutter_90","oa-fts_shutter_100"]'
data-get-on=["0","10","20","30","40","50","60","70","80","90","100"] data-on-color="#2A2A2A">
</div>
Hier noch die Readings aus FHEM.
Readings
cloud disabled
energy_0 0
firmware v1.9.4
last_dir up
level stopped
network connected to 192.168.178.85
overpower0
pct 100
position open
power 0
power_0 208.17
relay on
state stopped
stop_reason normal
Ich hoffe jemand kann mir sagen wo der Fehler liegt.
VG
Simon
Zitatdata-get="position"
versuche mal
data-get="pct"
Konntest Du das Problem schon lösen simon89?
Ich habe vor ein paar Tagen einen Homematic-Rollladen-Aktor gegen einen Shelly 2.5 ausgetauscht und hatte bisher in TabletUI so ziemlich genau die gleiche Konfiguration drin. Nämlich die:
<div data-type="symbol" class=" narrow" data-device="ho_rollo1" data-get="pct"
data-icons='["oa-fts_shutter_100","oa-fts_shutter_90","oa-fts_shutter_80","oa-fts_shutter_70","oa-fts_shutter_60","oa-fts_shutter_50","oa-fts_shutter_40","oa$
data-get-on='["0","10","20","30","40","50","60","70","80","90","100"]' data-on-color="#2A2A2A"
data-on-background-color="#d8fcf0">
</div>
Das Ergebnis sieht seltsam aus:
<div data-type="select" data-device="ho_rollo1" data-items="["100","90","80","70","60","50","40","30","20","10","0"]" data-alias="["Auf","90%","80%","70%","60%","50%","40%","30%","20%","10%","Zu"]" data-get="pct" data-set="" class="cell select-small select"><div class="select_wrapper"><select><option value="open:noArg">Auf</option><option value="shellies/shellyswitch25-E8DB84AAE8FE/roller/0/command">90%</option><option value="open
">80%</option><option value="">70%</option><option value="close:noArg">60%</option><option value="shellies/shellyswitch25-E8DB84AAE8FE/roller/0/command">50%</option><option value="close
">40%</option><option value="">30%</option><option value="stop:noArg">20%</option><option value="shellies/shellyswitch25-E8DB84AAE8FE/roller/0/command">10%</option><option value="stop
">Zu</option><option value=""></option><option value="pct:slider,0,1,100">pct:slider,0,1,100</option><option value="shellies/shellyswitch25-E8DB84AAE8FE/roller/0/command/pos">shellies/shellyswitch25-E8DB84AAE8FE/roller/0/command/pos</option><option value="$EVTPART1
">$EVTPART1
</option><option value=""></option><option value="x_recalibration:noArg">x_recalibration:noArg</option><option value="shellies/shellyswitch25-E8DB84AAE8FE/roller/0/command">shellies/shellyswitch25-E8DB84AAE8FE/roller/0/command</option><option value="rc
">rc
</option><option value=""></option><option value="x_update:noArg">x_update:noArg</option><option value="shellies/shellyswitch25-E8DB84AAE8FE/command">shellies/shellyswitch25-E8DB84AAE8FE/command</option><option value="update_fw
">update_fw
</option><option value=""></option><option value="x_mqttcom">x_mqttcom</option><option value="shellies/shellyswitch25-E8DB84AAE8FE/command">shellies/shellyswitch25-E8DB84AAE8FE/command</option><option value="$EVTPART1">$EVTPART1</option></select></div></div>
Da kommen vom Shelly also noch irgendwelche Werte dazu.
Wenn ich was auswähle sehe ich werde im fhem-Log noch in der Ereignisanzeige was ankommen.
In der gleichen Datei sind noch die weiteren Homematic-Rollo-Aktoren drin und die funktionieren nach wie vor korrekt.
Hat jemand ein Shelly-Rollo in TabletUI untergebracht?
Ich kann gerne ein neues Thema starten, aber das hier behandelt ja genau das gleiche Problem.
Danke schon mal!
ZitatDa kommen vom Shelly also noch irgendwelche Werte dazu.
Wie sollte das denn passieren?
Meine Shelly-Aktoren sind haargenau so eingebunden, wie die von HomeMatic. Und das seit langer Zeit, keinerlei Problem:
<td style="width:120">
<div data-template="roll.html"
data-parameter='{"par01":"SZ.Roll.1","par02":"B links","par03":"#44AAFF"}'
></div>
</td>
und roll.html
<!DOCTYPE html SYSTEM "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title></title>
</head>
<body>
<table>
<tr>
<td rowspan="2">
<div data-type="slider" data-device="par01" data-set="pct" data-get="pct"
data-min="0" data-max="100" data-color="par03" data-height="150"
class="large tap value"> </div></td>
<td>
<div data-type="switch" data-device="par01" data-set="pct" data-get="pct"
data-get-on="100" data-get-off="!100" data-set-on="100" data-set-off=""
data-color="par03" data-on-color="#FFFFFF"
data-on-background-color="par03" data-icon="oa-fts_shutter_10"></div>
</td>
</tr>
<tr>
<td>
<div data-type="switch" data-device="par01" data-set="pct" data-get="pct"
data-get-on="0" data-get-off="!0" data-set-on="0"
data-set-off="" data-color="par03" data-on-color="#FFFFFF"
data-on-background-color="par03" data-icon="oa-fts_shutter_100"></div>
</td>
</tr>
<tr>
<td colspan="2">
<div class="cell large">par02</div>
</td>
</tr>
</table>
</body>
</html>
LG
pah
Zitat von: Prof. Dr. Peter Henning am 20 August 2021, 17:31:02
Wie sollte das denn passieren?
Frag mich was Leichteres, das kann ich mir auch nicht erklären.
Danke für den Code! Ich werde den mal ausprobieren.
Das Problem scheint das Reading "setList" zu sein.
Ich habe den Shelly per
set ho_rollo attrTemplate shelly2_roller
konfiguriert.
Das Ergebnis enthält dann das Reading setList mit folgendem Inhalt:
open:noArg shellies/shellyswitch25-E8DB84AAE8FE/roller/0/command open
close:noArg shellies/shellyswitch25-E8DB84AAE8FE/roller/0/command close
stop:noArg shellies/shellyswitch25-E8DB84AAE8FE/roller/0/command stop
pct:slider,0,1,100 shellies/shellyswitch25-E8DB84AAE8FE/roller/0/command/pos $EVTPART1
x_recalibration:noArg shellies/shellyswitch25-E8DB84AAE8FE/roller/0/command rc
x_update:noArg shellies/shellyswitch25-E8DB84AAE8FE/command update_fw
x_mqttcom shellies/shellyswitch25-E8DB84AAE8FE/command $EVTPART1
Alles was nach pct kommt wird wohl im Select als Option aufgeführt (siehe Screenshot).
Wenn data-set auch auf pct setze, dann werden nur max. 4 Einträge angezeigt.
Sollte ich vielleicht ein anderes Template benutzen?
@Prof. Dr. Peter Henning:
Der Code von Dir liefert bei mir auch einen funktionierenden Slider, aber ich würde trotzdem gerne einen Select weiterhin verwenden.
Hast Du ein Template für Deine Shelly-Schalter verwendet?