Skip to content

Commit

Permalink
Fix energy calculation (#188)
Browse files Browse the repository at this point in the history
  • Loading branch information
andig authored Jun 8, 2020
1 parent 221985f commit dc6da44
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion charger/go-e.go
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ func (c *GoE) CurrentPower() (float64, error) {
func (c *GoE) ChargedEnergy() (float64, error) {
var status goeStatusResponse
_, err := c.GetJSON(c.apiURL(goeStatus), &status)
energy := float64(status.Dws) / 3.6e6
energy := float64(status.Dws) / 3.6e5 // Deka-Watt-Seconds to kWh (100.000 == 0,277kWh)
return energy, err
}

Expand Down

0 comments on commit dc6da44

Please sign in to comment.