jneilliii / OctoPrint-TasmotaMQTT

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

OpenHab trigger the plugin?!

xsasx opened this issue · comments

commented

Hi,

so installed the plugin and it works great with my mqtt server (which is integrated in my OpenHab installation)

I can power on and off the printer via OpenHab App and or via the Octoprint gui.

But : If I power it on by OpenHab its just on and dont fire the commands to octoprint that i have configured in the Plugin.

If I power it on via the Octoprint Gui it works as expected.

The problem is i must connect first to octoprint gui and than klick on the on button - but what i want is just power it on via OpenHab App (with the Use of the configured commands like autoconnect and restart klipper and such things)

Is that possible in any way ?

I'll have to go back and revisit the logic here. I'm sore it's possible but would require a rewrite of code I'm guessing.

commented

would be glad to have this feature ! would be very helpfull in workflow !!! also i will be your test candidate if you come back with any news!

commented

This issue has been automatically marked as stale because it has not had activity in 14 days. It will be closed if no further activity occurs in 7 days.

So I've done a quick hack that is not the ideal way to handle this, but if you install the plugin from the url below it should work in your case. The caveat is that when it receives the MQTT status update message that triggers a change in state it will run the internal on/off commands which publishes an additional ON/OFF to the MQTT topic for the relay. To truly make this work better I need to extract the additional steps (connect/disconnect and system commands) into a separate function and call those on subscription updates. I will want to experiment with those changes prior to releasing an official version.

https://github.com/jneilliii/OctoPrint-TasmotaMQTT/archive/0.3.2.zip

commented

Thank you I will try and give you feedback !

commented

@jneilliii

so now i had time to test - I did not know what you have done but you must have done anything right- cause it seems to work :D !!!!! THanks !!!!!!!!!!!!!