The MQTT implamantation is great. But can you please add secure MQTT connections like User and password for the broker?
Have you tried to set it up? It is definitely there already. See my screenshot
Ok, Sorry I have only See the Screenshots.
Than all is verry fine!
Good Job Shelly.
You can set username and password for authentication, but the MQTT connection is not secure. We do not yet support SSL for MQTT – this is trickier to implement properly on these constrained devices than it looks.
We’re baking our next release with a minor update on MQTT: all devices now support
announcecommands on topic
shellies/command. The first will trigger an immediate push of the current state, the second can be used for discovery: devices reply with a json payload on
shellies/announce. I am not sure if and how this can be integrated with Pimatic. Beta builds are available for testing if you are interested in the features.
That Sounds awesome! I am not at home to test it. Is the MQTT update also for the Shelly 2 or only for Shelly 1?
Meanwhile I was able to test the update on MQTT. Unfortunately the point MQTT is very hidden under Internet&Security -> Advanced-Developer Settings…
But if you found it and entered your MQTT server there it works very well and the MQTT protocol also simplifies the integration into Pimatic
But I have two little things to note:
- as @Simonbove already wrote it would be great if you can create your own MQTT-Topics.
- it would be great if the Shelly Device ID could be seen in the app or the HTML page. I changed the network-name of the devices (where the ID is in it) to a better assignable one and had to search for it now with a MQTT sniffer. That’s very awkward.
But my Shelly2 work very well with the MQTT protocol and it even displays the current state and the momentate used power information via MQTT. Very good.
You can bind your Shelly 2 in MQTT like this:
shellies/shellyswitch-<deviceid>/roller/0 reports the current state: open, close while in motion, stop when not moving and power while im motion. shellies/shellyswitch-<deviceid>/roller/0/command accepts open, close and stop
I am now eagerly waiting for my ordert Shelly H&T and Shelly1.
For me Shelly’s products are a clear recommendation until now, it is constantly being developed, the wishes of the community are taken into the developing. And the support fits too, a faulty device was replaced after it was sent in.
I should probably mention the link to our API docs (HTTP and MQTT):
Do use the Feedback link if you find stuff missing. It’s also possible to use the Dev Tools of your browser to look at requests done by the local web interface of each device.
as @Simonbove already wrote it would be great if you can create your own MQTT-Topics.
Not going to happen. However, we try to design the MQTT protocol to be as plain as possible, so that integrations with all sorts of home automation systems are easily doable.
it would be great if the Shelly Device ID could be seen in the app or the HTML page.
We’ll work on that. In the mean time for local discovery you can try using mDNS. On Linux, with avahi installed the output of
avahi-browse --allshould show the shellies in your LAN.
If you have configured the device for MQTT, subscribe to
shellies/commandor just restart the device.
Slightly offtopic, position control and autocalibration for roller mode on Shelly2 is code-complete, release coming up in a week or two if all is well.
Today I added my first Shelly 1 switch. That are the options that work for me.
You need to install “jq” first. Additionally you have to adjust username, password and IP to your Shelly accordingly.
Is anybody running this with espeasy flashed?
I have the shelly1 flashed with espeasy and struggle to setup the correct rules / devices.
I want to use it with mqtt, like my other sonoff devices.
I think this could be the most stable solution (not dependent on shelly firmware)…
I see no reason to replace the original firmware. It has MQTT installed and is constantly being improved.
So the Shelly2 has a new roller blind control with a percent closing rate.