matejdro / PebbleDialer-Android

Android part of the PebbleDialer app.
GNU General Public License v3.0
29 stars 16 forks source link

Oreo. The app stops when the screen is locked #37

Open ZeroBit opened 6 years ago

ZeroBit commented 6 years ago

Hi! I have Huawei Mate 10 Android 8.0. After the screen is off for several minutes PebbleDialer cannot send anything to Pebble watch.

The app is added to all list to keep it in memory. (1) Setting->Battery->Launch->Dialer for Pebble managed manually: Auto-launch is ON, Secondary launch is ON, Run in background is ON. (2) Settings -> APPS & Notifications -> Ignore battery optimization -> Dialer for Pebble -> Allow. (3) Recent apps -> Dialer for Pebble -> Locked

It cannot send anything to Pebble watch being in the background. I have made a Tasker Profile for Event "Call Incoming" to run the task "Launch the app (Dialer for Pebble)" and it always works. But with this I have some inconveniences: (2) When the call is coming (after Tasker launches Dialer for Pebble behind the locked screen and Dialer for Pebble becomes the foreground app behind locked screen) the Dialer app with the photo and number if person who is calling is minimized to the green status bar and I can see only a notification message (such and such is calling) on the locked screen. I cannot pick up the call. (2) After the call if I unlock the screen I always see the main window of the app Dialer for Pebble.

I also notices the moment when the system has already deactivated Dialer for Pebble. After the screen is off for several minutes if I go on Pebble watch to the list of app, find Dialer and press the middle button instead of seeing "Call History" and "All contacts" it will enter to the app to the split of a second and will return to the list of apps and will remain on "Dialer". It means that system has already killed "Dialer for Pebble" app. And if I call this time - nothing will be seen to the watch. But if I push the middle button on the Dialer app on the Pebble watch DURING the incoming call - it will appear on the Pebble watch as it must be.

Your app is a must have app for all Pebble users. Please, fix it.

matejdro commented 6 years ago

I assume you are the same person that posted about this on Google+?

Do you have notifcation access enabled for Dialer?

matejdro commented 6 years ago

Can you try enabling "high performance mode"? According to this thread, it might help: https://stackoverflow.com/questions/47145722/how-to-deal-with-huaweis-and-xiaomis-battery-optimizations?rq=1

ZeroBit commented 6 years ago

Yes, I am the same person :-) And I like your app very, very much! And Yes, the notifcation access is enabled for Dialer ANd Yes, The battery saving is completely off. screenshot_20180103-120812_320p screenshot_20180103-120552_320p

I so appreciate that you are answering to user's problem. Thank you!

P.S. I have sent video to matejdro+Support@gmail.com with the description of the problem.

matejdro commented 6 years ago

What happens if you enable Notification Access to Tasker and then disable "Run in Foreground" option in Tasker's settings? Does it still work or does it break like Dialer?

ZeroBit commented 6 years ago

It seems it still works... Probably because of Icon on the statusbar. The only task in Tasker is running PebbleDialer. If I switch off "Run on Foreground" in Tasker and put all 2 apps in background (while PebbleDialer is set to start PebbleDialer on "Incoming Call" event) it works OK. PebbleDialer started by Tasker as it should despite switched off "Run on Foreground"

matejdro commented 6 years ago

Run in foreground is supposed to turn off the icon. Are you sure you did it correctly?

ZeroBit commented 6 years ago

No, it doesn't turn off the icon screenshot_20180103-133042_320p

P.S. I have sent another video to your Email

matejdro commented 6 years ago

Can you disable both foreground and show icon, exit tasker and re-test?

ZeroBit commented 6 years ago

Yes, I did it. And I have sent 2nd video to you EMail matejdro+Support@gmail.com with conditions you just asked about. With "Run in Foreground" = OFF and "Show Notification icon" = OFF it works correctly. Tasker still runs Dialer for Pebble till now.

matejdro commented 6 years ago

Can you give me logs for one instance where call does not go through?

Thanks for the info by the way, you are great help (I don't have Huawei device so I cannot do this myself).

ZeroBit commented 6 years ago

I send the mail to your email. Also I just made it second time and here are the second log when call does not go through. This time the call was going to the phone but not to the Watch for 15 seconds. Then suddenly it started to go the the watch. Here is the log log (1).txt

ZeroBit commented 6 years ago

I notice this behavior. If during the call (without picking the call) I unlock the lockscreen of the phone the Pebble for Dialer app will pass call to the watch. It always so.