Handle
Methods
Types
EnergyReading
EnergyStats and StatSummary
Method Reference
read_energy(duration: f64) -> Result<EnergyReading>
Integrate energy and charge over duration seconds.
read_stats(duration: f64) -> Result<EnergyStats>
Statistics over the window, rather than an integral.
Examples
Budget a duty cycle
Catch a current spike a mean would hide
Supported Hardware
Notes
- The box clamps the window to 0.1-120 seconds. A request outside that range is
silently adjusted, and
duration_sreports the window actually used. - The client widens its HTTP budget to
max(30, duration + 30)seconds. duration_son the reply is the window the instrument actually used, which can differ slightly from what you asked for. Divide by it, not by your request, when converting an integral to an average.energy_jis joules andcharge_cis coulombs.energy_whandcharge_ahgive the same readings in watt-hours and amp-hours.

