HS3 MQTT Plugin
Moderator: Willem4ever
-
- Starting Member
- Posts: 2
- Joined: Wed Mar 02, 2016 11:57 pm
Re: HS3 MQTT Plugin
Many thanks, that worked well
Re: HS3 MQTT Plugin
I am trying to use the plugin but am having the same problem that Brian reported some months ago.
I am using Raspbian Jessie on an RPi 2, with HS3 Pro Edition 3.0.0.206 (Linux).
Firstly the plugin does not show up in the updater as stated in this thread. Assuming that that is just a meta-data problem with the updater posting, I downloaded the last posted zip file from this thread for Windows/Linux, containing the .exe and .dll files, and restarted HS3 (after also updating mosquitto to 1.4.
.
Although the plugin is recognised and initialised ok, there is also the following error in the log, and no plugin config pages appear (see error message #2 when you try to do that).
Initializing plug-in(2): MQTT Instance::Object reference not set to an instance of an objectSTACK: at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke (System.Runtime.Remoting.Proxies.RealProxy rp, IMessage msg, System.Exception& exc, System.Object[]& out_args) [0x00000] in :0
and
Getting web page from plugin page MQTTConfig:Object reference not set to an instance of an object
So perhaps the fix for this problem referred to earlier didn't work, or has returned ? Either way, if anyone has a way around this, I would be very grateful.
I am using Raspbian Jessie on an RPi 2, with HS3 Pro Edition 3.0.0.206 (Linux).
Firstly the plugin does not show up in the updater as stated in this thread. Assuming that that is just a meta-data problem with the updater posting, I downloaded the last posted zip file from this thread for Windows/Linux, containing the .exe and .dll files, and restarted HS3 (after also updating mosquitto to 1.4.

Although the plugin is recognised and initialised ok, there is also the following error in the log, and no plugin config pages appear (see error message #2 when you try to do that).
Initializing plug-in(2): MQTT Instance::Object reference not set to an instance of an objectSTACK: at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke (System.Runtime.Remoting.Proxies.RealProxy rp, IMessage msg, System.Exception& exc, System.Object[]& out_args) [0x00000] in :0
and
Getting web page from plugin page MQTTConfig:Object reference not set to an instance of an object
So perhaps the fix for this problem referred to earlier didn't work, or has returned ? Either way, if anyone has a way around this, I would be very grateful.
Re: HS3 MQTT Plugin
Hi,
did you install the Windows/Linux version or the Raspberry Pi version? The plugins for Windows/Linux is not compatible with RPi, you need the plugin build for the RPi, see the first page of this topic to retrieve the RPi plugin.
Quick check: The Rpi version contains the 2 DLL's (the plugin and the mqtt library), the windows/linux version contain 1 exe (plugin) and 1 dll (Mqtt library).
Regards,
Geert-Jan
did you install the Windows/Linux version or the Raspberry Pi version? The plugins for Windows/Linux is not compatible with RPi, you need the plugin build for the RPi, see the first page of this topic to retrieve the RPi plugin.
Quick check: The Rpi version contains the 2 DLL's (the plugin and the mqtt library), the windows/linux version contain 1 exe (plugin) and 1 dll (Mqtt library).
Regards,
Geert-Jan
Re: HS3 MQTT Plugin
Well, since I'm not using the Zee version of HomeSeer, I thought that there is no difference between Linux on a Raspberry Pi and any other hardware platform also running Debian.
But I have now deleted the .exe and .dll files from the HomeSeer folder, and replaced them with the two .dlls from the rpi version of the installer here. But now HS3 is not recognizing the plugin at all - nothing in the startup log, no listed interface, nothing.
All of the other plugins that are working well have a .exe program associated with them, just like the non-rpi distribution did, which was why that looked like the right track. But using the rpi version seems like a step backwards if it's not recognized at all.
But I have now deleted the .exe and .dll files from the HomeSeer folder, and replaced them with the two .dlls from the rpi version of the installer here. But now HS3 is not recognizing the plugin at all - nothing in the startup log, no listed interface, nothing.
All of the other plugins that are working well have a .exe program associated with them, just like the non-rpi distribution did, which was why that looked like the right track. But using the rpi version seems like a step backwards if it's not recognized at all.
Re: HS3 MQTT Plugin
Hi,
It seems that something has been changed in Homeseer. I will bring my RPi back to life and install the most recent version of the Homeseer RPi software. Come back to you soon.
Regards,
Geert-Jan
It seems that something has been changed in Homeseer. I will bring my RPi back to life and install the most recent version of the Homeseer RPi software. Come back to you soon.
Regards,
Geert-Jan
Re: HS3 MQTT Plugin
Thanks guys for this great plugin! This weekend able to send WeeWX data from my Davis weather station, and 1wire thru OWServer thru MQTT to receive on my HS3 box.
One question I did have; is there a way to specify credentials for the MQTT server within the plugin? I'm not seeing a way to do it, and not sure I want to run long term with allow anonymous.
Thanks!
One question I did have; is there a way to specify credentials for the MQTT server within the plugin? I'm not seeing a way to do it, and not sure I want to run long term with allow anonymous.
Thanks!
Re: HS3 MQTT Plugin
Hi,
authorization/authentication is not yet supported by the MQTT plugin. I add this request to the feature list.
Regards,
Geert-Jan
authorization/authentication is not yet supported by the MQTT plugin. I add this request to the feature list.
Regards,
Geert-Jan
Re: HS3 MQTT Plugin
@geert-jan Thank you! This plugin has definitely made a huge impact on my HS3 installation, My Home energy monitor (TED1000) had gone EOL and discontinued support within HS. With an example python script someone wrote, I got this now logging energy data direct to MQT. Also looking to replace my ADIO-100 with an Arduino Yun. Using the Adafruit MQTT example, I have it monitoring the inputs and sending their status across. Super easy... thank you again for this awesome plugin!!!!
Re: HS3 MQTT Plugin
ALl,
an update (v1.1.0.0) of the MQTT plugin is available via the Homeseer updater.
New features:
Be able to define your own client id when connecting to the MQTT broker
QOS: Be able to set the quality of service when publishing MQTT messages
QOS: Be able to set the quality of service when subscribing to MQTT messages
Retain: Be able to define if the MQTT broker should retain messages sent to it
Logging: logging level can be configured, plugin logging is written to the Homeseer log
Note: the features can be configured via the MQTT Configuration page
Bug fixes:
Fixed bug that publish page showed the check marks, but no device updates where published
Next step is to validate (and release) the MQTT plugin for Linux and the RPi version.
Regards,
Geert-Jan
an update (v1.1.0.0) of the MQTT plugin is available via the Homeseer updater.
New features:
Be able to define your own client id when connecting to the MQTT broker
QOS: Be able to set the quality of service when publishing MQTT messages
QOS: Be able to set the quality of service when subscribing to MQTT messages
Retain: Be able to define if the MQTT broker should retain messages sent to it
Logging: logging level can be configured, plugin logging is written to the Homeseer log
Note: the features can be configured via the MQTT Configuration page
Bug fixes:
Fixed bug that publish page showed the check marks, but no device updates where published
Next step is to validate (and release) the MQTT plugin for Linux and the RPi version.
Regards,
Geert-Jan
Re: HS3 MQTT Plugin
I experienced two bugs with the old version
- Fixed bug that publish page showed the check marks, but no device updates where published
- Devices without both the floor and room set are not visible in the list
I will check if the first one is fixed, for the second one i changed my setup
- Fixed bug that publish page showed the check marks, but no device updates where published
- Devices without both the floor and room set are not visible in the list
I will check if the first one is fixed, for the second one i changed my setup

Running HS3PRO on PC with Z-Wave / OpenTherm / Plugwise / RFXcom / MQTT / XAP400 / Logitech Media Server and Squeezelite on PI`s
Re: HS3 MQTT Plugin
@geert-jan Are you updating both device strings and values on subscriptions? Reason I ask if if I try to override the string values using the device settings; i.e. formatting numbers or changing values to human readable, it gets overwritten every time. Is there a possibility of adding a setting for subscriptions to update device value, string, or both for each device? Thank you for all your hard work, it's a great plugin.
Re: HS3 MQTT Plugin
Question: when I enable info logging my log is filled with these messages:
You see the same deviceRef a lot (3913). This is a Sonos device. I dont use MQTT yet to send device updates to my MQTT broker. I havent selected any device to update through MWTT, but I still get these messages. Is this correct behaviour? I would expect to see only the devices I selected to update.
Remark:
I see a lot of these errors:
thanks!
Code: Select all
mei-02 23:10:10 MQTT Info: Publish. address=S08 dvRef=3913 (double) value=711409
mei-02 23:10:10 MQTT Info: Publish. address=S08 dvRef=3913 (string) value=05:36:49
mei-02 23:10:09 MQTT Info: Publish. address=S08 dvRef=3913 (double) value=711408
mei-02 23:10:09 MQTT Info: Publish. address=S08 dvRef=3913 (string) value=05:36:48
mei-02 23:10:08 MQTT Info: Publish. address=S08 dvRef=3913 (double) value=711407
mei-02 23:10:08 MQTT Info: Publish. address=S08 dvRef=3913 (string) value=05:36:47
mei-02 23:05:12 MQTT Info: stop
mei-02 23:05:12 MQTT Error: Exception occured when publishing due to device value update. Exception=System.NullReferenceException: De objectverwijzing is niet op een exemplaar van een object ingesteld. bij HSPI_MQTT.HS3MQTT.publish(String address, Int32 dvRef, Double value)
mei-02 23:05:12 MQTT Info: Publish. address=S08 dvRef=3913 (double) value=711115
mei-02 23:05:12 MQTT Error: Exception occured when publishing due to device string update. Exception=System.NullReferenceException: De objectverwijzing is niet op een exemplaar van een object ingesteld. bij HSPI_MQTT.HS3MQTT.publish(String address, Int32 dvRef, String value)
mei-02 23:05:12 MQTT Info: Publish. address=S08 dvRef=3913 (string) value=05:31:55
Remark:
I see a lot of these errors:
Code: Select all
Error: Exception occured when publishing due to device string update. Exception=System.NullReferenceException: De objectverwijzing is niet op een exemplaar van een object ingesteld. bij HSPI_MQTT.HS3MQTT.publish(String address, Int32 dvRef, String value)
mei-02 23:05:12 MQTT Info: Publish. address=S08 dvRef=3913 (string) value=05:31:55
groeten,
Harry
Harry
Re: HS3 MQTT Plugin
Can you double check to publish settings? I have seen that some version of the MQTT plugin enable publisch check boxes by default as soon as you add a device to HomeSeer and so they publish data 

Running HS3PRO on PC with Z-Wave / OpenTherm / Plugwise / RFXcom / MQTT / XAP400 / Logitech Media Server and Squeezelite on PI`s
Re: HS3 MQTT Plugin
Device publishing is not enabled. None of the devices are. This is a sonos device from the sonos plugin. I deleted your plugin and reinstalled it. Same behaviour.
groeten,
Harry
Harry
Re: HS3 MQTT Plugin
That's really weird as the ones I have set to publish from Homeseer are the only ones I'm seeing when I watch the messages go by.
On a side note, finally got ssl running on the MQTT broker this weekend. Plugin doesn't support it yet I don't think, but can at least start securing other things internally.
Anyone try out the new QOS settings?
On a side note, finally got ssl running on the MQTT broker this weekend. Plugin doesn't support it yet I don't think, but can at least start securing other things internally.
Anyone try out the new QOS settings?