Plasma Mobile goes back to lockscreen when the phone isn't charging
#1
Greetings !

I have the KDE edition pinephone, and after an update, I've seen that when it wasn't plugged, it wouldn't stay unlocked more than a few seconds. Nothing special seems to be happening, just the session getting locked again. I kept making updates, but nothing's changed (well, lots changed, but not this specific issue).
I checked out what happened with journalctl, when unlocking the phone while unplugged:

Code:
-- Journal begins at Sun 2021-06-06 02:39:45 CEST. --
Jun 11 19:23:01 plasma-mobile mtp-probe[7231]: checking bus 1, device 15: "/sys/devices/platform/soc/1c1a000.usb/usb1/1-1/1-1.3"
Jun 11 19:23:01 plasma-mobile mtp-probe[7231]: bus: 1, device: 15 was not an MTP device
Jun 11 19:23:02 plasma-mobile upowerd[4309]: treating change event as add on /sys/devices/platform/soc/1c1a000.usb/usb1/1-1/1-1.3
Jun 11 19:23:02 plasma-mobile systemd-logind[3705]: Watching system buttons on /dev/input/event7 (SEM USB Keyboard Consumer Control)
Jun 11 19:23:02 plasma-mobile systemd-logind[3705]: Watching system buttons on /dev/input/event6 (SEM USB Keyboard)
Jun 11 19:23:02 plasma-mobile systemd-logind[3705]: Watching system buttons on /dev/input/event8 (SEM USB Keyboard System Control)
Jun 11 19:23:02 plasma-mobile mtp-probe[7261]: checking bus 1, device 15: "/sys/devices/platform/soc/1c1a000.usb/usb1/1-1/1-1.3"
Jun 11 19:23:02 plasma-mobile mtp-probe[7261]: bus: 1, device: 15 was not an MTP device
Jun 11 19:23:04 plasma-mobile xdg-desktop-portal-kde[4529]: xdp-kde-background: GetAppState called: no parameters
Jun 11 19:23:34 plasma-mobile xdg-desktop-portal-kde[4529]: xdp-kde-background: GetAppState called: no parameters
Jun 11 19:23:50 plasma-mobile dbus-daemon[3694]: [system] Activating service name='org.kde.powerdevil.backlighthelper' requested by ':1.39' (uid=1000 pid=4342 comm="/usr/lib/org_kde_powerdevil ") (using servicehelper)
Jun 11 19:23:51 plasma-mobile dbus-daemon[3694]: [system] Successfully activated service 'org.kde.powerdevil.backlighthelper'
Jun 11 19:23:54 plasma-mobile dbus-daemon[3694]: [system] Activating via systemd: service name='org.freedesktop.ModemManager1' unit='dbus-org.freedesktop.ModemManager1.service' requested by ':1.137' (uid=1000 pid=7269 comm="/usr/lib/kscreenlocker_greet --immediateLock --gra")
Jun 11 19:23:54 plasma-mobile dbus-daemon[3694]: [system] Activation via systemd failed for unit 'dbus-org.freedesktop.ModemManager1.service': Unit dbus-org.freedesktop.ModemManager1.service not found.
Jun 11 19:23:54 plasma-mobile dbus-daemon[3694]: [system] Activating via systemd: service name='org.freedesktop.ModemManager1' unit='dbus-org.freedesktop.ModemManager1.service' requested by ':1.137' (uid=1000 pid=7269 comm="/usr/lib/kscreenlocker_greet --immediateLock --gra")
Jun 11 19:23:54 plasma-mobile dbus-daemon[3694]: [system] Activation via systemd failed for unit 'dbus-org.freedesktop.ModemManager1.service': Unit dbus-org.freedesktop.ModemManager1.service not found.


Nothing really stands out to me... I see something related with kscreenlocker, but I don't know what happens there.

Would anyone know where I should look next ?
  Reply
#2
Have you tried to search the forum Smile
There are several threads&topics about this problem and how to fix that Wink
  Reply
#3
My. You're right. Though it didn't help, unfortunately.

I just spent a couple of hours researching, and here's what I managed to glean. While there are other topics on this issue, when it comes to solution, they all redirect to a single topic, in which two possible solutions are being suggested.

The first solution involves changing the `.config/powermanagementprofilesrc` file.

The other one is someone suggesting to flash the device to update to Plasma Mobile Gear 21.05. Truthfully, while I don't know how to check the current PlaMo Gear version, I've been reading the changelogs, and I'm pretty sure it already reached our phones. Some people do say that the configuration file needs to be updated anyway: I tried updating it, I tried removing it... no luck.

Sources:
- https://forum.pine64.org/showthread.php?...8#pid93468 (editing the config file)
- https://forum.pine64.org/showthread.php?...1#pid94721 (plasma mobile gear update)

Topics which seem to be talking about the same issue:
- https://forum.pine64.org/showthread.php?tid=14014
- https://forum.pine64.org/showthread.php?tid=14043
- https://forum.pine64.org/showthread.php?tid=13702
  Reply
#4
Relevant source:
https://invent.kde.org/plasma-mobile/pla.../issues/11

Not the same issue, but it does speak about the same faulty configuration file, and give some hints about values that might be useful.

Someone else here says the issue will be fixed with Plasma Mobile Gear 21.05. I also had the screen brightness issue, and it indeed got fixed a few weeks ago. Could it be that people are mistaking the screen locking issue for the screen brightness one ?

Anyhow, I'll keep following that lead, and try to come out with my own version of `powermanagementprofilesrc`.
If anyone comes around here, I would very much like to see other versions of your ~/.config/powermanagementprofilesrc file, as I would like to see if they're different from this one (https://forum.pine64.org/showthread.php?...8#pid93468).

EDIT:
This might also be relevant:
https://github.com/KDE/plasma-mobile-con...profilesrc
It's 8 years old, but the last commit editing this file did say `never sleep by default`. After testing it, it seems to completely disable the lockscreen: it appears after booting, but never again afterwards. It wouldn't be so problmatic, but the homescreen also stops reacting to touch events afterwards, and only the top drawer remain accessible.
So this is definitely progress, and a promising lead for later... but not a solution quite yet.

I also found this version, which is also pretty damn old. Stashed for later:
https://github.com/MatMoul/plasma-config...profilesrc

The following link shows how to edit powermanagementprofilesrc from command line. Useful, since the PlaMo UI for doing so isn't complete (and perhaps not functional):
https://forum.kde.org/viewtopic.php?f=17&t=108974
  Reply
#5
Okay guys. I've solved the issue. Following the hints of the links above, I modified the original version of my powermanagementprofilesrc configuration file by modifying some idleTime.

I think the relevant category is "DPMSControl". It's possible that whatever writes to the configuration file render the values as seconds, but this configuration file seems to expect milliseconds, if I'm not mistaken.

Here's the result:

Code:
[AC]
icon=battery-charging

[AC][DPMSControl]
idleTime=600000
lockBeforeTurnOff=1

[AC][DimDisplay]
idleTime=300000

[AC][HandleButtonEvents]
lidAction=1
powerButtonAction=128
powerDownAction=16

[Battery]
icon=battery-060

[Battery][BrightnessControl]
value=0.5

[Battery][DPMSControl]
idleTime=600000
lockBeforeTurnOff=1

[Battery][DimDisplay]
idleTime=300000

[Battery][HandleButtonEvents]
lidAction=1
powerButtonAction=128
powerDownAction=16

[Battery][SuspendSession]
idleTime=300000
suspendThenHibernate=true
suspendType=32

[LowBattery]
icon=battery-low

[LowBattery][BrightnessControl]
value=30

[LowBattery][DPMSControl]
idleTime=300000
lockBeforeTurnOff=1

[LowBattery][DimDisplay]
idleTime=30000

[LowBattery][HandleButtonEvents]
lidAction=1
powerButtonAction=128
powerDownAction=16

[LowBattery][SuspendSession]
idleTime=300000
suspendType=1

And with that, you should be good to go. For now, everything seems fine with my pinephone, but I have yet to test it out and see what other things it changed... perhaps the screenlock won't appear as often as it should. But at least, now, we know how to patch up this issue.
  Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  GTK Rust mobile Linux client for Signal Be. 14 9,378 11-11-2021, 05:35 PM
Last Post: sativista
  Phosh: Idles to Lockscreen Without Powering Off Display Merc 1 350 11-01-2021, 09:00 AM
Last Post: e1337
Exclamation PinePhone keyboard usability: no phone ring with headphones e1337 13 1,122 10-29-2021, 08:06 AM
Last Post: e1337
  Choosing Wi-Fi or Mobile Data sergio.pantalone 1 286 10-14-2021, 12:28 PM
Last Post: kqlnut
  Jami on the Pine phone ? bcnaz 5 714 10-09-2021, 03:16 PM
Last Post: TRS-80
  Questions and experiences using Fedora Mobile (as a PinePhone newbie) zkajdan 1 395 10-03-2021, 11:31 AM
Last Post: zkajdan
  Phone Shell Nextcloud message notifications: turn them off? lsitongia 0 229 09-28-2021, 11:04 AM
Last Post: lsitongia
  Pine phone Battery life vs operating system bcnaz 19 10,318 08-27-2021, 09:35 PM
Last Post: bcnaz
  How to block phone numbers? natasha 7 3,701 07-19-2021, 09:04 AM
Last Post: swiley
  Brand new phone, screen flickers than locks Marekx3 3 1,066 06-11-2021, 11:40 AM
Last Post: plaristote

Forum Jump:


Users browsing this thread: 1 Guest(s)