Metainformationen zur Seite
ShellySwitch
UserGuide: https://shelly.cloud/wp-content/uploads/2018/10/Shelly2_User_Guide_EN_v03_print.pdf
Shelly2 allows control and monitoring over MQTT for both relay and roller modes. Device mode, along with other parameters need to be configured using the mobile application or web interface. Due to popular demand, since v1.4.3 we also report the state of external switch inputs on shellies/shelly2-<deviceid>/input/N
.
MQTT in Relay mode
In relay mode, the following topics can be used to read and set output channels 0
and 1
:
shellies/shellyswitch-<deviceid>/relay/<i>
to report status:on
,off
oroverpower
shellies/shellyswitch-<deviceid>/relay/<i>/command
acceptson
andoff
and applies accordingly
The device measures the total consumption on both channels, which can be seen on:
shellies/shellyswitch-<deviceid>/relay/power
reports instantaneous power consumption rate in Wattsshellies/shellyswitch-<deviceid>/relay/energy
reports amount of energy consumed in[10 * Wh]
MQTT in Roller mode
When configured to operate in roller mode, MQTT topics used by Shelly2 are:
shellies/shellyswitch-<deviceid>/roller/0
reports the current state:open
,close
while in motion,stop
when not moving.shellies/shellyswitch-<deviceid>/roller/0/command
acceptsrc
(performs roller calibration),open
,close
andstop
.
New in v1.4.0: roller mode position control. For this to work, the device must first be successfully calibrated, so that the time it takes for closing and opening are known.
shellies/shellyswitch-<deviceid>/roller/0/pos
reports the current position in percentshellies/shellyswitch-<deviceid>/roller/0/command/pos
accepts a number between 0 and 100, which is target position in percent.