Ocpp: use correct profile current when switching phases (#17003)
This commit is contained in:
parent
98663c2caf
commit
60b68c2d4b
1 changed files with 11 additions and 1 deletions
|
|
@ -364,7 +364,17 @@ func (c *OCPP) MaxCurrentMillis(current float64) error {
|
|||
func (c *OCPP) phases1p3p(phases int) error {
|
||||
c.phases = phases
|
||||
|
||||
return c.setCurrent(c.current)
|
||||
enabled, err := c.Enabled()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
var current float64
|
||||
if enabled {
|
||||
current = c.current
|
||||
}
|
||||
|
||||
return c.setCurrent(current)
|
||||
}
|
||||
|
||||
var _ api.Identifier = (*OCPP)(nil)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue