MQTT Client

Questions and comments specific to a particular plugin should go here.

Re: MQTT Client

Postby ToxMox » Mon Aug 14, 2017 2:52 pm

krambriw wrote:I suspect I made a bug

I was not able to reproduce the error but I think I found what could cause the problem. I have modified the plugin (new version 1.2.1)
It no longer hangs EG anymore. I couldn't get my cert for beebotte to work in brief testing. You mentioned moving the paho folder to the lib27/site-packages folder. On EG 4.x it should be the lib26/site-packages folder right? Or do I need to create a lib27 folder?
ToxMox
 
Posts: 14
Joined: Fri Aug 04, 2017 7:39 pm

Re: MQTT Client

Postby krambriw » Mon Aug 14, 2017 3:00 pm

On EG 4.x it should be the lib26/site-packages folder right?


Correct (and you obviously have to change the port to the one used by beebotte as well)

How many certificates are you using? If one, add it as the CA-cert. Does it require username and password as well?
My latest plugins
http://plugins.krambriw.net/index.html

Two men in front of a huge excavator...
- that beast steels work from 100 men with shovels
- well, a 1000 men could do the same using teaspoons
krambriw
Plugin Developer
 
Posts: 2569
Joined: Sat Jun 30, 2007 2:51 pm
Location: Stockholm, Sweden

Re: MQTT Client

Postby krambriw » Mon Aug 14, 2017 4:15 pm

it works fine with beebotte, as example below using the token. You could instead use the secret key. It's described pretty well here:
https://beebotte.com/docs/mqtt
When I publish something to EG/EG it is shown in the EG log

It seems not possible to upload files to the forum anylonger so here is a link instead

http://krambriw.net/BB.png
My latest plugins
http://plugins.krambriw.net/index.html

Two men in front of a huge excavator...
- that beast steels work from 100 men with shovels
- well, a 1000 men could do the same using teaspoons
krambriw
Plugin Developer
 
Posts: 2569
Joined: Sat Jun 30, 2007 2:51 pm
Location: Stockholm, Sweden

Re: MQTT Client

Postby ToxMox » Mon Aug 14, 2017 4:17 pm

krambriw wrote:
On EG 4.x it should be the lib26/site-packages folder right?


Correct (and you obviously have to change the port to the one used by beebotte as well)

How many certificates are you using? If one, add it as the CA-cert. Does it require username and password as well?
Yup changed the port to 8883. And yes added as a CA cert. It requires a username but not a password. I'm passing my secret key as a username. Here is the info on their end if you are curious: https://beebotte.com/docs/mqtt
In the EG log I just get
Code: Select all
MQTT Client: Trying to reconnect with..<my topic> mqtt.beebotte.com
over and over again.

I have successfully connected using the cert with node-red btw. Not sure if that helps at all but thought I'd mention it.
ToxMox
 
Posts: 14
Joined: Fri Aug 04, 2017 7:39 pm

Re: MQTT Client

Postby ToxMox » Mon Aug 14, 2017 4:21 pm

I see you posted while I was writing my post above. I'm going to try EG 5.x again as maybe this is an EG 4.x issue?
ToxMox
 
Posts: 14
Joined: Fri Aug 04, 2017 7:39 pm

Re: MQTT Client

Postby ToxMox » Mon Aug 14, 2017 4:35 pm

Ok works fine with EG 0.5.0-rc4. Thanks for fixing this!
ToxMox
 
Posts: 14
Joined: Fri Aug 04, 2017 7:39 pm

Re: MQTT Client

Postby Saxtus » Mon Aug 28, 2017 7:20 pm

Hello,

When starting a new MQTT subscription, how can I change the client ID?

I see that it's got a random one assigned, but if I copy/paste the EG action, so I can modify only the subscription topic, the client ID gets preserved, and that is causing conflict to the broker.

Thank you for the great plugin!
User avatar
Saxtus
 
Posts: 42
Joined: Wed Jan 02, 2013 3:37 am
Location: Athens, Greece

Re: MQTT Client

Postby krambriw » Tue Aug 29, 2017 5:55 am

Hello Saxtus, thank You,

Currently there is no input field for client id as you have seen. A work around for your use case is not to copy and paste directly, instead paste to a text editor in between and make the change, then copy and paste the html into the EG tree

1) For each action, copy the action from the EG tree
2) Paste into a text editor, change the client id in the html text
3) Copy the html text and paste into EG tree

Alternatively you could directly edit the whole EG tree file when you have copy & pasted all your actions
My latest plugins
http://plugins.krambriw.net/index.html

Two men in front of a huge excavator...
- that beast steels work from 100 men with shovels
- well, a 1000 men could do the same using teaspoons
krambriw
Plugin Developer
 
Posts: 2569
Joined: Sat Jun 30, 2007 2:51 pm
Location: Stockholm, Sweden

Re: MQTT Client

Postby Snowbird » Wed Sep 06, 2017 8:03 am

Hi krambriw,

I just want to let you know that the mqtt dialog boxes are too big to fit on small resolution screen (1280x800), I know it's not today's standard but they still exist for some people ! :)

Here's a screen shot of how it looks like, look at the black bar at the very bottom, it's my Windows 10 tasks bar, and as you can see I'm not able to see all the fields (others are located below the black bar) :

Image

I have checked the code, and was able to rearrange things to fit everything inside but in case of a plugin upgrade I have to redo it all over again, do you think you can rearrange the fields so the dialog box takes less place in height (less than 700px for example ) ? If you want, I can do the modification on my end and I will send it to you so you can include it in the source code, this way in case of an upgrade this part won't change. Let me know.

Thank you.
Snowbird
Experienced User
 
Posts: 115
Joined: Fri Jul 03, 2009 10:04 am

Re: MQTT Client

Postby krambriw » Fri Sep 08, 2017 4:27 am

Hello Snowbird,
Yes, agree, this can be (or is) a problem. I would like to accept your suggestion, are your modifications based on the latest version (1.2.1)?

Best regards, Walter
My latest plugins
http://plugins.krambriw.net/index.html

Two men in front of a huge excavator...
- that beast steels work from 100 men with shovels
- well, a 1000 men could do the same using teaspoons
krambriw
Plugin Developer
 
Posts: 2569
Joined: Sat Jun 30, 2007 2:51 pm
Location: Stockholm, Sweden

Re: MQTT Client

Postby Snowbird » Fri Sep 08, 2017 6:24 am

Hi,

Yes I'm using your latest version 1.2.1 and I made the modification on it. I have just modified this file :
%ProgramData%\EventGhost\plugins\MQTT Client\__init__.py

I did my best to make it look pretty but it's not easy when you don't have much room :) Feel free to readjusted a little bit if needed.

Thank you again for this great plugin !!
Attachments
__init__.py
Plugin MQTT v1.2.1
dialog box reduced in height to fit on small screen resolution (800px height)
(64.28 KiB) Downloaded 11 times
Snowbird
Experienced User
 
Posts: 115
Joined: Fri Jul 03, 2009 10:04 am

Re: MQTT Client

Postby krambriw » Sat Sep 09, 2017 2:15 pm

Hello, so now I have re-arranged the gui parts accordingly, should be fine and fit most screens
Version 1.2.2
My latest plugins
http://plugins.krambriw.net/index.html

Two men in front of a huge excavator...
- that beast steels work from 100 men with shovels
- well, a 1000 men could do the same using teaspoons
krambriw
Plugin Developer
 
Posts: 2569
Joined: Sat Jun 30, 2007 2:51 pm
Location: Stockholm, Sweden

Re: MQTT Client

Postby Snowbird » Sat Sep 09, 2017 3:22 pm

Thank you Walter ! it looks amazing now, much better than what I did ! and most of all it fits my screen perfectly now ;)
you're the man !
Snowbird
Experienced User
 
Posts: 115
Joined: Fri Jul 03, 2009 10:04 am

Previous

Return to Plugin Support

Who is online

Users browsing this forum: No registered users and 4 guests

cron