Real-world battery life experience FW13 AMD

Power consumption of the hw decoder is borked at this point unfortunately so video playback does murder battery life.

I do hope this gets fixed soon.

9 Likes

Fedora 39 (Workstation, Linux Kernel 6.6.6-200.fc39.x86_64)
Framework Laptop 13 AMD Ryzen 7040 Series (Batch 11, Firmware 03.03)
Expansion Slot Configuration: 2xUSB-C, 1xUSB-A, 1xHDMI

Overall Iā€™d rate the battery life as not particularly excellent on Linux (~4-6hrs if in light use), not that that is unexpected. That said, given the modern processor, I find that for light tasks I can keep the laptop on Power Saver with pretty much no noticeable performance hit. My past experience on older Intel this mode would have made the system sluggish.

Drawing ~8W on Power Saver mode, light browsing in Firefox.

At this rate, the battery is drained at about ~15% per hour. Maybe ~5%/hr on standby.

3 Likes

I have managed to improve the battery life expectancy by using a little script.

When on battery, I set KDE to execute a script containing the following line :

echo power | tee /sys/devices/system/cpu/cpu*/cpufreq/energy_performance_preference

With AMD P-States, no matter what you set the governor to be (powersave or performance) it doesnā€™t change much the amount of power used by the CPU cores. The powersave setting just seems to less aggressively boost. Though the energy performance preference setting, in conjunction with the governor, defines the behaviour of the CPU. The EPP profiles that can be used are default (whatever that is), performance (that was what it was set to for me), balance_performance, balance_power and power.
The profile power is the one that gives me the most aggressive energy saving with most cores being parked/at 400MHz most of the time. Depending on the balance of battery life and performance youā€™re aiming for you can go for other profiles and see what the results are for you.

My battery life expectancy with power as the profile and a charge of 95% with nothing but effectively web browsing going on is above 10 hours. With YouTube video playback I gained about an extra expected hour of playback.

With mostly web browsing and light gaming (BTD6) as tasks for today, I have managed to go through my day in a single charge (though I did use my device only for a bit more than 4 hours) and I still have over 40% battery left.

I am looking into what can be done with the GPU as this seems to still drain a bit of power during YouTube playback. Though, energy consumption while watching YouTube still decreased to 8.5-9W compared to 10-12W. Also, idle is looking pretty good at around 5W.

7 Likes

So, Iā€™m having some issues related to powerdevil. It doesnā€™t seem to escalate to root/doesnā€™t have the permissions to apply the EPP profileā€¦ Though, the script itself does work when ran as sudo. That does not impact in anyway the results I had. Itā€™s just a little trouble with the automation.

1 Like

Figured it out. If you want to use my solution and avoid having a bash script looping infinitely and looking at your battery status, you can set udev rules to run the script when your laptop is getting connected to AC power and when it is not.
The udev rules are as simple as this :

SUBSYSTEM=="power_supply", ATTR{online}=="0", RUN+="/path/to/your/script bat"
SUBSYSTEM=="power_supply", ATTR{online}=="1", RUN+="/path/to/your/script ac"

src : stackexchange

Of course, simply replace the RUN part with the path to your own power management script(s). The delay for the rules applying is very small though it does work for the automation.

3 Likes

Iā€™m also using 2x16 Kingston and a Lexar NM710 2TB. Idling at 5W and going up to 10W just typing here on Firefox on NixOS.

Do you think it might be the Lexars? Iā€™m not sure they draw more power if they arenā€™t being accessed, but yeah this is pretty awful.

I would be honestly very surprised if that turned out to be the case.

I chose this SSD after a careful selection/comparison where I valued the efficiency to performance ratio the most.

Just cause it has a low Wh/GBw doesnā€™t mean it has particularly good idle power but in this case it very likely isnā€™t the issue.

You may want to check if apst is working right (item 4 here)

Thanks for that.

Yeah, seems to be enabled.

rei@udon ~ [1]> sudo nvme get-feature /dev/nvme0 -f 0x0c -H
get-feature:0x0c (Autonomous Power State Transition), Current value:0x00000001
	Autonomous Power State Transition Enable (APSTE): Enabled

Iā€™ll try pulling one of my DIMMs to see how much that reduces consumption. If itā€™s significant, maybe the RAMā€™s just not a good fit for this machine.

Edit: Yeah, if anything, using half the RAM seems to increase power draw by 0.2-0.3 watts at idle. Maybe itā€™s caching more, though I donā€™t think Iā€™m running particularly many background services either.

Good, then itā€™s unlikely to be the ssd.

In my testing that made barely enough difference to be measurable but nowhere near enough to be worth cutting memory bandwidth in half.

2 Likes

So that probably rules out both of the non-Framework components, which is good to know.

Then with the other hardware being the same as the 7040U machines running Windows at 2.5W, there has to be something going on in software.

Not that thatā€™s particularly new information, but it looks like some people are getting slightly better power performance even on Linux?

1 Like

2.5W?! Damn, lowest I got with the screen on was like 2.7.

You got PPD or TLP running right?

I am personally pretty content with the power consumption on Linux (appart from the borked hardware decoding consumption)

2 Likes

PPD, yeah.

Iā€™m getting 4.5-5 at best with the screen set to absolute lowest and running nothing at all.

Edit: Found the link. 2.5W idle is from an i7 Framework from a couple years ago. Both Windows and Fedora.

Soā€¦ yeah, I feel like this machine could do a bit better.

3 Likes

Yeah 2.5 is also something my old t480s could do with min brighness under linux. But I am ok with 2.7 min idle especially since min brighness on the framework is a bit brighter than on the t480s.

Could always be better but mine does pretty ok as long as there is no video playback involved.

Got it down to 3.2 idle with a few things:

  • TLP helps alongside PDD
  • powertop --auto-tune
  • Docker, even with no containers, causes interrupts, so that was pretty big
  • Switch from xmonad on X to Hyprland on Wayland (Waylandā€™s power draw seems to be basically the same as text mode when idle)
  • Remove SD card reader card, which draws power even when itā€™s vacant

Video on Firefox seems to be a lost cause at the moment. Forcing vaapi causes intermittent juddering and is still not all that great of an improvement.

1 Like

Same here, ended up returning the single 32GB Crucial stick and keeping the 2x16 I had before

But those 0.3W XD

1 Like

You could also do this in KDE power management settings. Are you just giving a general solution for those not on KDE orā€¦? Why udev?

3.5W with 46 tabs (6 active over 3 windows) on Firefox using gfx.webrender.all in about:config! Not bad!

2 Likes

Power Devilā€™s permissions do not allow it to write to the sysfs. So the scripts do not work. udev rules run as root and they can also trigger on power state change.

PPD would be a better solution. I personally wrote a power manager in C++, because I felt like it (itā€™s very basic and has basically no functionality but it was a nice little project).