oscev

package
v0.7.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 21, 2024 License: MIT Imports: 9 Imported by: 2

Documentation

Index

Constants

View Source
const (
	// Update of the list of remote entities supporting the Use Case
	//
	// Use `RemoteEntities` to get the current data
	UseCaseSupportUpdate api.EventType = "cem-oscev-UseCaseSupportUpdate"

	// EV current limits
	//
	// Use `CurrentLimits` to get the current data
	DataUpdateCurrentLimits api.EventType = "cem-oscev-DataUpdateCurrentLimits"

	// EV load control recommendation limit data updated
	//
	// Use `LoadControlLimits` to get the current data
	//
	// Use Case OSCEV, Scenario 1
	DataUpdateLimit api.EventType = "cem-oscev-DataUpdateLimit"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type OSCEV

type OSCEV struct {
	*usecase.UseCaseBase
}

func NewOSCEV

func NewOSCEV(localEntity spineapi.EntityLocalInterface, eventCB api.EntityEventCallback) *OSCEV

func (*OSCEV) AddFeatures

func (e *OSCEV) AddFeatures()

func (*OSCEV) CurrentLimits

func (e *OSCEV) CurrentLimits(entity spineapi.EntityRemoteInterface) ([]float64, []float64, []float64, error)

return the min, max, default limits for each phase of the connected EV

possible errors:

  • ErrDataNotAvailable if no such measurement is (yet) available
  • and others

func (*OSCEV) HandleEvent

func (e *OSCEV) HandleEvent(payload spineapi.EventPayload)

handle SPINE events

func (*OSCEV) LoadControlLimits

func (e *OSCEV) LoadControlLimits(entity spineapi.EntityRemoteInterface) (
	limits []ucapi.LoadLimitsPhase, resultErr error)

return the current loadcontrol recommendation limits

parameters:

  • entity: the entity of the EV

return values:

  • limits: per phase data

possible errors:

  • ErrDataNotAvailable if no such limit is (yet) available
  • and others

func (*OSCEV) WriteLoadControlLimits

func (e *OSCEV) WriteLoadControlLimits(
	entity spineapi.EntityRemoteInterface,
	limits []ucapi.LoadLimitsPhase,
	resultCB func(result model.ResultDataType),
) (*model.MsgCounterType, error)

send new LoadControlLimits to the remote EV

parameters:

  • entity: the entity of the e.g. EVSE
  • limits: a set of limits containing phase specific limit data
  • resultCB: callback function for handling the result response

recommendations: Sets a recommended charge power in A for each phase. This is mainly used if the EV and EVSE communicate via ISO15118 to support charging excess solar power. The EV either needs to support the Optimization of Self Consumption usecase or the EVSE needs to be able map the recommendations into oligation limits which then works for all EVs communication either via IEC61851 or ISO15118.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL