nosybore / Tasker-MQTT-Publish-Plugin

Android Studio project based on bodiroga/mqtter
35 stars 15 forks source link

stops publishing mqtt messages after a while #13

Open janvda opened 7 years ago

janvda commented 7 years ago

I have created a tasker task on my android phone consisting of following actions

  1. Get Location (to retrrieve the GPS coordinates)
  2. variable set to store the GPS location in a variable
  3. variable split to split the GPS location in latittude / longitude coordinates
  4. MQTT publish to publish to MQTT broker in the cloud
  5. HTTP Post to post same message
  6. MQTT publish to publish same message to local MQTT broker.

This task is scheduled every 12 minutes and is also launched manually for testing.

Initially the message gets properly received by the 2 MQTT brokers and also HTTP POST destination, but after some successful sends (about 5 times) the MQTT brokers no longer get those message allthough the HTTP POST destination is still properly receiving those messages.

Once this happens, I have to reboot my android phone to get it successfully publishing the MQTT messages again until it stops working again.

FYI : the MQTT settings are:

A work around for this problem would be much appreciated. kr Jan.

Wildshunter commented 7 years ago

yes, thanks, I have exactly the same issue.... please fix, thanks a lot. It works exactly 3times, after that I have to open the settings menue again go back, this fix my problem for the next 3times...

oversc0re commented 7 years ago

Same here. On different phones, after many reinstalls. Is there any hope for this to get resolved?

joel-garnick commented 7 years ago

I'm having the same problem on two devices. Is there any progress on identifying and fixing the issue? Can I provide any logs or more detailed info to help resolve?

koos147 commented 7 years ago

No need to reboot. Open the plugin from Tasker and save again. Then it works again for a few times. I think android close the app.

Also tried https://play.google.com/store/apps/details?id=in.dc297.mqttclpro it works a little bit longer. But in the end the same problem.

elbowz commented 7 years ago

Same issue here...anyone have solved or fixed?

keredoc commented 6 years ago

I am also suffering from the same issues, anyone have a workaround?

koos147 commented 6 years ago

I have https://play.google.com/store/apps/details?id=in.dc297.mqttclpro

It has a connect task. Then i wait a few seconds and publish. It works almost always.

TheUserDead commented 5 years ago

So, same here. Works just once. Added for work in background (not smart background) no results. Abandonware? Hope no.

tadly commented 5 years ago

I use it in conjunction with Macrodroid to publish my phones and tablets battery-level whenever it changes.

After disabling androids Battery Optimization for both, Macrodroid and this plugin it's working without a hitch.

So everyone still experiencing issues might wanna try this

silversquasher commented 4 years ago

Same issue here... Works just a few hours, After disabling androids Battery Optimization no difference. I have to re-configure the plug-in to make it works again for a few hours... The application updates seems to be abandoned since 2015 ?

tadly commented 4 years ago

@silversquasher are you using tasker or something else? Either way, also disable Battery Optimization for Tasker as I mentioned previously. If that doesn't help, maybe give MacroDroid a shot...

I'm using this plugin to report my phones battery-status to homeassistant and it hasn't failed me once going back all the way to May.

silversquasher commented 4 years ago

I'm using this plug-in with Automate application where I disabled Battery Optimization too but no difference.

tadly commented 4 years ago

Try macrodroid with Battery Optimization disabled and if that doesn't work also, it's most likely a issue with the android version you're using.

I'm on a pixel + stock rom