Today my new Satechi USB-C Charger arrived https://www.amazon.de/dp/B09QRWDK7F

New Charger The charger is much lighter than the one that came with my Asus Zenbook (ux6404vv) The charger has completed its first charging processes without any problems. Now I asked myself the question "charges the laptop at the maximum possible speed?" The keywords are Power Delivery and USB-C

Of course, there are USB cables on the market that have a power indicator in the form of a display. But I didn't want to buy an extra cable for this and thought there must be a more elegant solution under Linux.

First try

My first Idea was to check it with the already well known upower-daemon. But a upower -d delivers no information about the current charging speed:

Device: /org/freedesktop/UPower/devices/battery_BAT0
  native-path:          BAT0
  vendor:               ASUSTeK
  model:                ASUS Battery
  power supply:         yes
  updated:              Mi 10 Apr 2024 21:21:27 CEST (27 seconds ago)
  has history:          yes
  has statistics:       yes
  battery
    present:             yes
    rechargeable:        yes
    state:               charging
    warning-level:       none
    energy:              18.418 Wh
    energy-empty:        0 Wh
    energy-full:         71.284 Wh
    energy-full-design:  76 Wh
    energy-rate:         44.293 W
    voltage:             15.661 V
    charge-cycles:       32
    time to full:        1.2 hours
    percentage:          25%
    capacity:            93.7947%
    technology:          lithium-ion
    icon-name:          'battery-low-charging-symbolic'
  History (rate):
    1712776887  44.293  charging
    1712776857  17.096  charging
    1712776845  0.000   discharging
    1712776845  11.073  discharging
    1712776816  11.423  discharging
...
Second try

After a while of searching i found a helpful command that brings me closer to my goal:

 echo $(echo "scale=3; $(cat /sys/class/power_supply/BAT0/power_now) / 1000000" | bc -l) Watt

This command outputs the current delivered Power e.g 50W. I will implment this in my Waybar Charging indicator Area. But thats another Blogpost ;-).

battop

A really good tool i have found while i was searching for this solution is battop. Have a look: RWill_2024-04-10%2021-57-42

Previous Post Next Post