Page 16 of 26

Re: Python Plugin: Shelly MQTT

Posted: Tuesday 10 August 2021 18:10
by hendryman
The basic setup is this: /etc/mosquitto/mosquitto.conf is the default file, and that file then calls /etc/mosquitto/conf.d/mosquitto.conf for user customizations. However, even the default file does not get called my Mosquitto, contrary to what the wiki and other resources write. Either my installation is somehow broken, or the config file handling got changed by the Mosquitto 2.x update...

Basically, the best way to hack this is if someone could tell me how to modify the mosquitto init.d file so the "-c FILEPATH" option is invoked every time the demon starts.

Re: Python Plugin: Shelly MQTT

Posted: Saturday 25 September 2021 11:28
by extremeaudio
Does anyone have the solution for the MQTT 2.0 issue?

Re: Python Plugin: Shelly MQTT

Posted: Saturday 25 September 2021 11:33
by waltervl
extremeaudio wrote: Saturday 25 September 2021 11:28 Does anyone have the solution for the MQTT 2.0 issue?
What MQTT 2.0 issue?

Re: Python Plugin: Shelly MQTT

Posted: Saturday 25 September 2021 18:55
by samourai47
hello
Do you know if addon for temperature with ds18b20 devices is recognised in domoticz with this plugins and mqtt?
Thank's for your help

Re: Python Plugin: Shelly MQTT

Posted: Sunday 26 September 2021 13:03
by Gerwin
by samourai47 » Saturday 25 September 2021 18:55

hello
Do you know if addon for temperature with ds18b20 devices is recognised in domoticz with this plugins and mqtt?
Thank's for your help

Yes it is reconized and work's verry well

Gerwin

Re: Python Plugin: Shelly MQTT

Posted: Sunday 26 September 2021 18:10
by samourai47
Gerwin wrote: Sunday 26 September 2021 13:03 by samourai47 » Saturday 25 September 2021 18:55

Yes it is reconized and work's verry well

Gerwin
Great news... Thank's. I just command the deivice today and i completely newbies with mosquitto

So if i have undestood the configuration is...
Install mosquitto on RPI
Configure domoticz with the serveur
Install the shelly plugin
Create a dummy device for Temperature

And after?..... How send the value of the ds18b20 to the dummy device....

Re: Python Plugin: Shelly MQTT

Posted: Sunday 26 September 2021 20:47
by Neutrino
The plugin creates the devices, you don't need dummy.

Re: Python Plugin: Shelly MQTT

Posted: Wednesday 06 October 2021 17:17
by extremeaudio
viewtopic.php?f=28&t=35706

Is this of concern or no?
waltervl wrote: Saturday 25 September 2021 11:33
extremeaudio wrote: Saturday 25 September 2021 11:28 Does anyone have the solution for the MQTT 2.0 issue?
What MQTT 2.0 issue?

Re: Python Plugin: Shelly MQTT

Posted: Thursday 07 October 2021 15:47
by waltervl
extremeaudio wrote: Wednesday 06 October 2021 17:17 viewtopic.php?f=28&t=35706

Is this of concern or no?
waltervl wrote: Saturday 25 September 2021 11:33
extremeaudio wrote: Saturday 25 September 2021 11:28 Does anyone have the solution for the MQTT 2.0 issue?
What MQTT 2.0 issue?
The solution is in that topic so if you still have questions about that continue there.

Re: Python Plugin: Shelly MQTT

Posted: Sunday 10 October 2021 19:34
by extremeaudio
waltervl wrote: Thursday 07 October 2021 15:47 The solution is in that topic so if you still have questions about that continue there.
Thank you for your offer to help. I am totally unable to get this to work. I am using raspbian buster.

I followed the tutorial here - https://www.youtube.com/watch?v=w7QhsFqBr30&t=3s

to install mqtt.

When I issue

Code: Select all

sudo apt-get install mosquitto mosquitto-clients
I get

Code: Select all

Process: 1369 ExecStart=/usr/sbin/mosquitto -c /etc/mosquitto/mosquitto.conf (code=exited, status=3)
 Main PID: 1369 (code=exited, status=3)
dpkg: error processing package mosquitto (--configure):
 installed mosquitto package post-installation script subprocess returned error exit status 1
Processing triggers for systemd (241-7~deb10u6+rpi1) ...
Processing triggers for man-db (2.8.5-2) ...
Processing triggers for libc-bin (2.28-10+rpi1) ...
Errors were encountered while processing:
 mosquitto
N: Ignoring file 'mosquitto-buster.list.2' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension
N: Ignoring file 'mosquitto-buster.list.3' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension
N: Ignoring file 'mosquitto-buster.list.1' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension
E: Sub-process /usr/bin/dpkg returned an error code (1)

Re: Python Plugin: Shelly MQTT

Posted: Monday 11 October 2021 13:05
by osirisguitar
Thanks for making this plugin!

Devices weren't created when I did "allow new hardware for 5 minutes", I had to switch that on permanently. Is that a fluke or a bug in the plugin?

Re: Python Plugin: Shelly MQTT

Posted: Monday 11 October 2021 17:17
by extremeaudio
Can someone provide a step by step guide on configuring this plugin from scratch on a raspberry pi please ?

Re: Python Plugin: Shelly MQTT

Posted: Wednesday 10 November 2021 11:37
by svde
lwolf wrote: Saturday 10 November 2018 20:42 If anyone interested, I've made a Python plugin for Shelly MQTT integration into Domoticz. Currently I have only got a Shelly1 device to test, but more will come soon.
I would like to thank the zigbee2mqtt project for it's nice MQTT library that i reused.
https://github.com/enesbcs/Shelly_MQTT
Thank you for making this plugin.

I've recently updated the linux distribution on my system to a version which includes python 3.10.0. The Shelly MQTT plugin crashes with this python version. I looked on the github page, where it used to be possible to submit an issue, but this is no longer the case.

Re: Python Plugin: Shelly MQTT

Posted: Monday 15 November 2021 9:29
by verygood142
has anyone found the solution for shelly 1 plus from 2Gen?

Re: Python Plugin: Shelly MQTT

Posted: Friday 19 November 2021 12:46
by EdwinK
When I issue

Code: Select all

sudo apt-get install mosquitto mosquitto-clients
I get

Code: Select all

N: Ignoring file 'mosquitto-buster.list.2' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension
N: Ignoring file 'mosquitto-buster.list.3' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension
N: Ignoring file 'mosquitto-buster.list.1' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension
E: Sub-process /usr/bin/dpkg returned an error code (1)
There should only be one such file in the directory, and the filename should end with list. So not with a number. You should try with renaming one of them and remove the others

Re: Python Plugin: Shelly MQTT

Posted: Saturday 27 November 2021 10:03
by GSchets
I bought four Shelly Plug-S plugs and connected them to my Domoticz on Raspberry-pi via MQTT.
I want to keep an eye on the connected power with these plugs, but to my disappointment I get no power but temperature in Domoticz.
I already have a number of Shelly-1's, Shelly dimmer and an i3 and they all work perfectly.
I suspect that the Shelly plugin does not provide this.
Can someone help me?

Gerard

Re: Python Plugin: Shelly MQTT

Posted: Tuesday 30 November 2021 1:08
by Thelion
Hi,

Got my Shelly Pro4PM a couple of days ago and tried to add it to Domoticz with this (https://github.com/enesbcs/Shelly_MQTT) plugin, which works fine with all kinds of Shelly devices.

The events and status of the Pro4PM are visible in MQTT, but with a completely different topic and event structure, so it isn't recognized by the plugin and not added to Domoticz.

I even tried firmware 0.9.0-beta2 to check if it works with that, but it doesn't 🙁

Tried changing the MQTT prefix in the device, which lists it at the correct topic, but the structure of the payload is apparently also completely different, but it still doesn't show up, which indicates more than just a different topic.

The maker of the plugin doesn't list any means of contacting him, so that's not the way to solve this.

Anybody has/found a way to solve this?

Apart from pushing the whole bidirectional communication through NodeRED and trying to get it to work?

Re: Python Plugin: Shelly MQTT

Posted: Tuesday 30 November 2021 7:27
by waltervl
If Shelley supports Home assistant MQTT Autodiscover you could try that with latest Domoticz beta. https://www.domoticz.com/wiki/MQTT#Auto ... .28Beta.29

Re: Python Plugin: Shelly MQTT

Posted: Tuesday 07 December 2021 20:45
by CronoS
What could be a nice native way to use Shelly devices with Domoticz? Basically the plugin by itself works OK, I don't have any issues with it. But I have a allot of shelly devices in my house lately, so I am also very depended on this plugin. In my opinion maybe to depended, if something breaks in the plugin or in a combination with Domoticz, then I could potentially have an issue for my whole house automation. So maybe there is a alternative to integrate it with Domoticz, better find out now maybe ;)
Also the Shelly Plus is available and the new valve is coming, which I like but I don't know if the plugin will ever support those. So for me, ongoing development on the plugin is important because because of this. I am not quite sure if there is still development on this plugin?

Re: Python Plugin: Shelly MQTT

Posted: Wednesday 08 December 2021 9:15
by hoeby
CronoS wrote: Tuesday 07 December 2021 20:45 So for me, ongoing development on the plugin is important because of this.
For me this is the reason to not use plugins, because then you will be dependent on the developers of this plugin.
For this reason, i use nodered and make flows. When i started with it, i thoughed is this the best way. Now i think, yes it is.
When you have the flows and information. Then it will be getting easier and easier to extend the flow.
By doing this, you will not be dependent on the plugin, you have controll in your own hands.

I don't have much shelly devices, but more zigbee devices.
In the past i used zigbee2mqtt, but also this i stopped and transfered to sonoff tasmota zigbee.
For zigbee i will be dependent from the firmware for the zigbee coordinator. But i will try to keep this to a minimum.

This is a small flow i use for the shelly 2.5. To give you an idea
shelly.png
shelly.png (59.67 KiB) Viewed 2187 times