Phosh (developed by Purism for Librem 5) is the most popular UI in PinePhone community poll Jan 2022

BTW - if anyone wants to give it a shot, running UBports on Librem 5 is generally pretty easy; however, there’s one major issue that needs to be resolved before it becomes usable - their compositor needs to be fixed to support GPUs where graphic buffers shared without explicit modifiers aren’t linear (which is the case with etnaviv), otherwise all you get on screen is scrambled mess.

gnome-power-statistics, although you’ll need a small patch to produce good looking graphs:

diff --git a/src/gpm-statistics.c b/src/gpm-statistics.c
index 59b56be..e5179ed 100644
--- a/src/gpm-statistics.c
+++ b/src/gpm-statistics.c
@@ -756,7 +756,7 @@ gpm_stats_update_info_page_history (UpDevice *device)
        }
 
        widget = GTK_WIDGET (gtk_builder_get_object (builder, "label_history_nodata"));
-       array = up_device_get_history_sync (device, history_type, history_time, 150, NULL, NULL);
+       array = up_device_get_history_sync (device, history_type, history_time, 1500, NULL, NULL);
        if (array == NULL) {
                /* show no data label and hide graph */
                gtk_widget_hide (graph_history);
3 Likes

Yeah, I didn’t mean to come off too harsh on UBPorts as they do good work with limited resources, just pointing out that older Android phones repurposed to run Ubuntu Touch appears to be the bigger priority than focusing on the actual Linux based phones like Pinephone and Librem 5. I still find it amazing how well UT runs on a Nexus 5, a phone a decade old getting new life.

I haven’t timed it lately, but even if what the graph is showing for the Librem 5 is accurate, I lose about 8% of the charge an hour when the phone sits idle not charging. Point being, it feels like I always have it plugged in like its a laptop. I am not expecting Android/iOS battery efficiency anytime soon, but 8% an hour idle power loss, is a lot and if I am using it unplugged, that battery drains like a Ferrari going through gas.

1 Like

Currently, Evergreen should be able to reach about 12-16 hours of idle uptime depending on kill switch state, signal coverage and connected WiFi network, so 8% an hour sounds about right. If “charging takes forever”, make sure you’re using a proper PD adapter that provides enough current at 5V (like the one shipped with the phone, which does 3A). Non-PD sources are currently limited to 500mA unless manually overridden, which will make it charge very slowly or even slowly discharge when in use.

I do not have enough Gnome dev environment to compile this from source :frowning:

There is no suspend yet, but Purism is working on it:

1 Like

Sure you do!

You have a Librem 5 with PureOS, which is Debian-based a.k.a. awesome. You can do whatever you want. :slight_smile:

# Get the source code
apt-get source gnome-power-manager
cd gnome-power-manager-3.32.0/
# Install build dependencies
sudo apt-get build-dep .
# Make the changes you want using your favorive text editor
vi src/gpm-statistics.c 
# Build deb files
dpkg-buildpackage -us -uc -b
cd ..
# Install deb files
sudo dpkg --install gnome-power-manager*.deb
# Enjoy running your modified gnome-power-statistics program!
gnome-power-statistics

The above is basically the same procedure as in Tweaking difficulty level of Chess to make it easier, via minor source code change

5 Likes

The flip side of that is … if a customer thinks this might be the problem then monitor the charging current.

cat /sys/class/power_supply/max170xx_battery/current_now

1 Like

I expect that running Posh on Librem 5 with external monitor is not a priority yet.

But I would like to have some button, gesture option when application list popup by bottom tab, which allows to select some options for each application. There should be option to select put it back on Librem 5 with full screen geometry. Move it fully to attached monitor but do not expand ii and the put it onto monitor and ask application for window maximize.

This would be great for typical connection to TV set and moving slideshow or vlc on the monitor.

When used as a full desktop, I would like to have option to switch on and off some panel with application list and some other stuff to be stick on top or bottom side of the screen.

Are there some experience to combine posh with some such bar and application launcher?

Anyway, Phosh is nice and with suggested virtual mouse it is really interesting as convergence device when you need to present something. With full USB-C laptop dock and USB keyboard and mouse it great setup as well… Not for my FPGA and education video works but for regular text files sources etc it is just standard GNU/Linux, which is great.

2 Likes

…or check the negotiated PD state:

cat /sys/class/power_supply/tps6598x-source-psy-0-003f/uevent
3 Likes

If a keyboard is available, you can use shortcuts: Super+Shift+Arrows (moving between outputs), Super+Arrows (maximizing, restoring and tiling)

2 Likes
apt-get source gnome-power-manager
Reading package lists... Done
E: You must put some 'deb-src' URIs in your sources.list

As I said, I do not have enough Gnome dev environment to compile this from source. What are the URIs and to where I must put them. I’m not a Debian expert, normaly I use FreeBSD.

Great. On the other hand Librem 5 can be nice to present something where you have only USB-C to HDMI adapter. So I would appreciate some local menu on the application miniature in Posh list in the long term. There could be even forced kill and some other possibilities. But I agree that this is not critical now.

Shortcuts can be probably “pressed” even on virtual keyboard but it is not fully comfortable ad there is lot of the space on the application miniature. On the other hand, there should not be directly buttons for the actions because they can be tapped by mistake. Only one active and relatively small area in some corner and the local menu.

I’m sorry I forgot this part. The file in question is /etc/apt/sources.list and it usually contains the following three lines by default:

deb https://repo.pureos.net/pureos byzantium main
deb https://repo.pureos.net/pureos byzantium-updates main
deb https://repo.pureos.net/pureos byzantium-security main

What you need to do is to add a line that is identical to the first line except that it starts with deb-src instead of just deb. So the new line that you add should look like this:

deb-src https://repo.pureos.net/pureos byzantium main

You can put it where you want in the file, I usually put it after the first line since those two are both related to “byzantium main”.

After changing the file, run this:

sudo apt update

That is needed to make sure the changes in the file are used.

After that, try the apt-get source gnome-power-manager command again, then it should work.

1 Like

No, it doesn’t

apt-get source gnome-power-manager
...
Fetched 392 kB in 1s (345 kB/s)           
sh: 1: dpkg-source: not found
E: Unpack command 'dpkg-source --no-check -x gnome-power-manager_3.32.0-2.dsc' failed.
N: Check if the 'dpkg-dev' package is installed.

I’m installing now dpkg-dev which brings a lot of dev env:

The following NEW packages will be installed:
  binutils binutils-aarch64-linux-gnu binutils-common build-essential dpkg-dev fakeroot
  g++ g++-10 gcc gcc-10 libalgorithm-diff-perl libalgorithm-diff-xs-perl
  libalgorithm-merge-perl libasan6 libatomic1 libbinutils libc-dev-bin libc-devtools
  libc6-dev libcc1-0 libcrypt-dev libctf-nobfd0 libctf0 libfakeroot libgcc-10-dev
  libitm1 liblsan0 libnsl-dev libstdc++-10-dev libtirpc-dev libtsan0 libubsan1
  linux-libc-dev manpages manpages-dev
0 upgraded, 35 newly installed, 0 to remove and 0 not upgraded.
Need to get 47.8 MB of archives.
After this operation, 184 MB of additional disk space will be used.

As I said …

1 Like

The rest worked as described. Thank you.

1 Like

yeah, it appears when using Phosh on Pinephone, there is suspend and it is more battery efficient, but with a dealbreaking caveat, to get it out of suspend I have to restart the phone or plug it in to wake up. Its not just Phosh, this seems to be normal for the many OS’s one can flash on Pinephone. So Librem 5 is still way more viable as a daily driver right now over Pinephone just for this even with the constant heavy battery drain, but hopefully that can be worked out for both devices.

1 Like

Pressing the power button wakes the PP up from suspend just fine. And when using system-level timers (or the rtcwake command), it wakes up from suspend too.

2 Likes

I’ve compiled the app gnome-power-manager and it starts fine. Ofc the graphic does not fit on the screen and the app has no scrollbars:

For GNOME apps, you can run this command for each one, which will automatically scale it to the screen every time you open the app.
gsettings set sm.puri.phoc.application:/sm/puri/phoc/application/packagename/ scale-to-fit true ; replace “packagename” with actual name.

The result may not be particularly readable.

Run the same command with false to turn it off.

4 Likes