Binary package “powerstat” in ubuntu bionic

laptop power measuring tool

 Powerstat measures the power consumption of a mobile PC that has
 a battery power source. The output is like vmstat but also shows
 power consumption statistics. At the end of a run, powerstat
 will calculate the average, standard deviation and min/max of
 the gathered data.