[modules/battery_all] Remove defunct estimate calculation code
A decent fallback implementation would require some kind of differential measurement to be able to calculate a rate of change. For now, that is simply more complicated than warranted. Thanks to @stoeps13 for pointing that out!
This commit is contained in:
parent
621e442efc
commit
86c8dd5219
1 changed files with 0 additions and 11 deletions
|
@ -45,17 +45,6 @@ class Module(bumblebee.engine.Module):
|
|||
return None
|
||||
elif estimate == power.common.TIME_REMAINING_UNKNOWN:
|
||||
return ""
|
||||
else:
|
||||
for path in self._batteries:
|
||||
try:
|
||||
with open("{}/power_now".format(path)) as o:
|
||||
power_now += int(o.read())
|
||||
except IOError:
|
||||
return "n/a"
|
||||
except Exception:
|
||||
errors += 1
|
||||
|
||||
estimate = float( self.energy_now / power_now)
|
||||
except Exception:
|
||||
return ""
|
||||
return bumblebee.util.durationfmt(estimate*60, shorten=True, suffix=True) # estimate is in minutes
|
||||
|
|
Loading…
Reference in a new issue