mirror of
https://gitlab.com/manzerbredes/esds.git
synced 2025-04-06 10:06:28 +02:00
Update energy plugin
This commit is contained in:
parent
11c5ffcdc7
commit
8691e98c7f
1 changed files with 4 additions and 0 deletions
|
@ -149,5 +149,9 @@ class PowerStatesComms(NodePlugin):
|
||||||
consumption+=self.power[interface]["consumption_idle"]+self.power[interface]["consumption_dynamic"]
|
consumption+=self.power[interface]["consumption_idle"]+self.power[interface]["consumption_dynamic"]
|
||||||
return consumption
|
return consumption
|
||||||
|
|
||||||
|
def get_idle(self,interface):
|
||||||
|
self.sync_idle()
|
||||||
|
return(self.power[interface]["consumption_idle"])
|
||||||
|
|
||||||
def report_energy(self):
|
def report_energy(self):
|
||||||
self.log("Communications consumed "+str(round(self.get_energy(),2))+"J")
|
self.log("Communications consumed "+str(round(self.get_energy(),2))+"J")
|
||||||
|
|
Loading…
Add table
Reference in a new issue