Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add TQ Energy Manager EM420 #4083

Merged
merged 16 commits into from
Aug 10, 2022
Prev Previous commit
Next Next commit
Format & Tidy
  • Loading branch information
Djcd committed Aug 9, 2022
commit add6ca8c8ce05a4bd9ba1e32498951910f3879e6
5 changes: 3 additions & 2 deletions charger/eebus.go
Original file line number Diff line number Diff line change
Expand Up @@ -248,8 +248,9 @@ func (c *EEBus) Enabled() (bool, error) {

// Enable implements the api.Charger interface
// enable
// true: allow to EV to draw power
// false: do not allow the EV to draw power
//
// true: allow to EV to draw power
// false: do not allow the EV to draw power
func (c *EEBus) Enable(enable bool) error {
data, err := c.cc.GetData()
if err != nil {
Expand Down
3 changes: 2 additions & 1 deletion cmd/configure/helper.go
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,8 @@ func (c *CmdConfigure) paramChoiceValues(params []templates.Param, name string)

// processConfig processes an EVCC configuration item
// Returns:
// a map with param name and values
//
// a map with param name and values
func (c *CmdConfigure) processConfig(templateItem *templates.Template, deviceCategory DeviceCategory) map[string]interface{} {
fmt.Println()
fmt.Println(c.localizedString("Config_Title", nil))
Expand Down
3 changes: 2 additions & 1 deletion server/http.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,9 @@ type route struct {
HandlerFunc http.HandlerFunc
}

//lint:ignore U1000 if needed
// routeLogger traces matched routes including their executing time
//
//lint:ignore U1000 if needed
func routeLogger(inner http.Handler) http.HandlerFunc {
return func(w http.ResponseWriter, r *http.Request) {
start := time.Now()
Expand Down
4 changes: 2 additions & 2 deletions vehicle/helper.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"strings"
)

// ensureVehicleWithFeature extracts VIN from list of VINs returned from `list`` function
// ensureVehicleWithFeature extracts VIN from list of VINs returned from `list function
func ensureVehicle(vin string, list func() ([]string, error)) (string, error) {
vin, _, err := ensureVehicleWithFeature(vin, list, func(v string) (string, string) {
return v, ""
Expand All @@ -14,7 +14,7 @@ func ensureVehicle(vin string, list func() ([]string, error)) (string, error) {
return vin, err
}

// ensureVehicleWithFeature extracts VIN and feature from list of vehicles of type V returned from `list`` function
// ensureVehicleWithFeature extracts VIN and feature from list of vehicles of type V returned from `list function
func ensureVehicleWithFeature[Vehicle, Feature any](
vin string,
list func() ([]Vehicle, error),
Expand Down