Skip to content

Commit

Permalink
Weidmüller: fix phases and current (#15127)
Browse files Browse the repository at this point in the history
  • Loading branch information
premultiply authored Jul 29, 2024
1 parent 1515a67 commit c4b5f87
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions charger/weidmüller.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ type Weidmüller struct {
const (
wmRegCarStatus = 301 // GD_ID_EVCC_CAR_STATE CHAR
wmRegEvccStatus = 302 // GD_ID_EVCC_EVSE_STATE UINT16
wmRegPhases = 317 // GD_ID_EVCC_PHASES UINT16
wmRegPhases = 318 // GD_ID_EVCC_PHASES_LLM UINT16
wmRegVoltages = 400 // GD_ID_CM_VOLTAGE_PHASE UINT32
wmRegCurrents = 406 // GD_ID_CM_CURRENT_PHASE UINT32
wmRegActivePower = 418 // GD_ID_CM_ACTIVE_POWER UINT32
Expand Down Expand Up @@ -167,7 +167,7 @@ func (wb *Weidmüller) MaxCurrent(current int64) error {
return fmt.Errorf("invalid current %d", current)
}

wb.curr = uint16(current * 10)
wb.curr = uint16(current)

return wb.setCurrent(wb.curr)
}
Expand Down

0 comments on commit c4b5f87

Please sign in to comment.