Class BatteryInverterSinexcelImpl
java.lang.Object
io.openems.edge.common.component.AbstractOpenemsComponent
io.openems.edge.bridge.modbus.api.AbstractOpenemsModbusComponent
io.openems.edge.batteryinverter.sinexcel.BatteryInverterSinexcelImpl
- All Implemented Interfaces:
ManagedSymmetricBatteryInverter
,OffGridBatteryInverter
,SymmetricBatteryInverter
,BatteryInverterSinexcel
,ModbusComponent
,OpenemsComponent
,ModbusSlave
,StartStoppable
,TimedataProvider
public class BatteryInverterSinexcelImpl
extends AbstractOpenemsModbusComponent
implements BatteryInverterSinexcel, OffGridBatteryInverter, ManagedSymmetricBatteryInverter, SymmetricBatteryInverter, ModbusComponent, OpenemsComponent, TimedataProvider, StartStoppable
-
Nested Class Summary
Nested classes/interfaces inherited from class io.openems.edge.bridge.modbus.api.AbstractOpenemsModbusComponent
AbstractOpenemsModbusComponent.BitConverter, AbstractOpenemsModbusComponent.ChannelMapper<ELEMENT extends ModbusElement>
Nested classes/interfaces inherited from interface io.openems.edge.batteryinverter.sinexcel.BatteryInverterSinexcel
BatteryInverterSinexcel.ChannelId
Nested classes/interfaces inherited from interface io.openems.edge.batteryinverter.api.ManagedSymmetricBatteryInverter
ManagedSymmetricBatteryInverter.ChannelId
Nested classes/interfaces inherited from interface io.openems.edge.bridge.modbus.api.ModbusComponent
ModbusComponent.ChannelId
Nested classes/interfaces inherited from interface io.openems.edge.batteryinverter.api.OffGridBatteryInverter
OffGridBatteryInverter.ChannelId, OffGridBatteryInverter.TargetGridMode
Nested classes/interfaces inherited from interface io.openems.edge.common.component.OpenemsComponent
OpenemsComponent.ChannelId
Nested classes/interfaces inherited from interface io.openems.edge.common.startstop.StartStoppable
StartStoppable.ChannelId
Nested classes/interfaces inherited from interface io.openems.edge.batteryinverter.api.SymmetricBatteryInverter
SymmetricBatteryInverter.ChannelId
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected Config
static final int
static final int
static final EnableDisable
static final PowerRisingMode
static final int
static final int
protected final AtomicReference<OffGridBatteryInverter.TargetGridMode>
Fields inherited from interface io.openems.edge.batteryinverter.api.SymmetricBatteryInverter
POWER_DOC_TEXT
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected void
Handles @Deactivate of implementations.debugLog()
Gets some output that is suitable for a continuous Debug log.protected ModbusProtocol
Defines the Modbus protocol.getModbusSlaveTable
(AccessMode accessMode) Gets the Modbus-Slave-Table for this OpenEMS-Component.int
Gets the smallest positive power that can be set (in W, VA or var).Gets the inverter start-stop target.Gets static Constraints for this Battery-Inverter.Gets theTimedata
service.void
Run the Battery-Inverter.protected void
setModbus
(BridgeModbus modbus) Set the Modbus bridge.void
setStartStop
(StartStop value) Starts or stops the device or service represented by this OpenEMS Component.void
setTargetGridMode
(OffGridBatteryInverter.TargetGridMode targetGridMode) Tells the Battery-Inverter to go to ON_GRID or OFF_GRID mode.Methods inherited from class io.openems.edge.bridge.modbus.api.AbstractOpenemsModbusComponent
activate, activate, activate, getBridgeModbus, getModbusProtocol, getUnitId, m, m, m, m, m, m, modified, modified, retryModbusCommunication, unsetModbus
Methods inherited from class io.openems.edge.common.component.AbstractOpenemsComponent
_channel, addChannel, addChannels, addChannels, alias, channels, getComponentContext, id, isEnabled, logDebug, logError, logInfo, logWarn, removeChannel
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.openems.edge.batteryinverter.sinexcel.BatteryInverterSinexcel
getClearFailureChannel, getSetOffGridMode, getSetOffGridModeChannel, getSetOnGridMode, getSetOnGridModeChannel, getStartInverterChannel, getStopInverterChannel, setClearFailure, setOffGridMode, setOnGridMode, setStartInverter, setStopInverter
Methods inherited from interface io.openems.edge.batteryinverter.api.ManagedSymmetricBatteryInverter
isManaged, isOffGridPossible
Methods inherited from interface io.openems.edge.bridge.modbus.api.ModbusComponent
_setModbusCommunicationFailed, getModbusCommunicationFailed, getModbusCommunicationFailedChannel, retryModbusCommunication
Methods inherited from interface io.openems.edge.batteryinverter.api.OffGridBatteryInverter
_setInverterState, _setOffGridFrequency, _setOffGridFrequency, getInverterState, getInverterStateChannel, getOffGridFrequency, getOffGridFrequencyChannel, getSetOffGridFrequencyChannel, setTargetOffGridFrequency
Methods inherited from interface io.openems.edge.common.component.OpenemsComponent
_channel, _getChannelAs, alias, channel, channel, channels, getComponentContext, getState, getStateChannel, hasFaults, id, isEnabled, serviceFactoryPid, servicePid
Methods inherited from interface io.openems.edge.common.startstop.StartStoppable
_setStartStop, getStartStop, getStartStopChannel, isStarted, isStopped, start, stop
Methods inherited from interface io.openems.edge.batteryinverter.api.SymmetricBatteryInverter
_setActiveChargeEnergy, _setActiveChargeEnergy, _setActiveDischargeEnergy, _setActiveDischargeEnergy, _setActivePower, _setActivePower, _setGridMode, _setMaxApparentPower, _setMaxApparentPower, _setReactivePower, _setReactivePower, getActiveChargeEnergy, getActiveChargeEnergyChannel, getActiveDischargeEnergy, getActiveDischargeEnergyChannel, getActivePower, getActivePowerChannel, getGridMode, getGridModeChannel, getMaxApparentPower, getMaxApparentPowerChannel, getReactivePower, getReactivePowerChannel
-
Field Details
-
MAX_APPARENT_POWER
public static final int MAX_APPARENT_POWER- See Also:
-
DEFAULT_UNIT_ID
public static final int DEFAULT_UNIT_ID- See Also:
-
DEFAULT_EMS_TIMEOUT
public static final int DEFAULT_EMS_TIMEOUT- See Also:
-
DEFAULT_BMS_TIMEOUT
public static final int DEFAULT_BMS_TIMEOUT- See Also:
-
DEFAULT_GRID_EXISTENCE_DETECTION_ON
-
DEFAULT_POWER_RISING_MODE
-
config
-
targetGridMode
-
-
Constructor Details
-
BatteryInverterSinexcelImpl
-
-
Method Details
-
setModbus
Description copied from class:AbstractOpenemsModbusComponent
Set the Modbus bridge. Should be called by @Reference- Overrides:
setModbus
in classAbstractOpenemsModbusComponent
- Parameters:
modbus
- the BridgeModbus Reference
-
deactivate
protected void deactivate()Description copied from class:AbstractOpenemsComponent
Handles @Deactivate of implementations. Prints log output.- Overrides:
deactivate
in classAbstractOpenemsModbusComponent
-
run
public void run(Battery battery, int setActivePower, int setReactivePower) throws OpenemsError.OpenemsNamedException Description copied from interface:ManagedSymmetricBatteryInverter
Run the Battery-Inverter.- bring the Battery-Inverter in the desired state
- apply information from
Battery
as required - set the target Active and Reactive Power.
This is called on ManagedSymmetricEss::applyPower()
- Specified by:
run
in interfaceManagedSymmetricBatteryInverter
- Parameters:
battery
- theBattery
setActivePower
- the active power setpointsetReactivePower
- the reactive power setpoint- Throws:
OpenemsError.OpenemsNamedException
- on error
-
debugLog
Description copied from interface:OpenemsComponent
Gets some output that is suitable for a continuous Debug log. Returns 'null' by default which causes no output.- Specified by:
debugLog
in interfaceOpenemsComponent
- Returns:
- the debug log output
-
setStartStop
Description copied from interface:StartStoppable
Starts or stops the device or service represented by this OpenEMS Component.- Specified by:
setStartStop
in interfaceStartStoppable
- Parameters:
value
- targetStartStop
state
-
getStartStopTarget
Gets the inverter start-stop target.- Returns:
StartStop
-
setTargetGridMode
Description copied from interface:OffGridBatteryInverter
Tells the Battery-Inverter to go to ON_GRID or OFF_GRID mode. Be sure to call this method before you callStartStoppable.start()
.- Specified by:
setTargetGridMode
in interfaceOffGridBatteryInverter
- Parameters:
targetGridMode
- theOffGridBatteryInverter.TargetGridMode
-
getStaticConstraints
Description copied from interface:ManagedSymmetricBatteryInverter
Gets static Constraints for this Battery-Inverter. Override this method to provide specific Constraints for this Battery-Inverter on every Cycle.- Specified by:
getStaticConstraints
in interfaceManagedSymmetricBatteryInverter
- Returns:
- the Constraints
- Throws:
OpenemsException
- on error
-
getPowerPrecision
public int getPowerPrecision()Description copied from interface:ManagedSymmetricBatteryInverter
Gets the smallest positive power that can be set (in W, VA or var). Example:- FENECON Commercial 40 allows setting of power in 100 W steps. It should return 100.
- KACO blueplanet gridsave 50 allows setting of power in 0.1 % of 52 VA. It should return 52 (= 52000 * 0.001)
- Specified by:
getPowerPrecision
in interfaceManagedSymmetricBatteryInverter
- Returns:
- the power precision
-
getModbusSlaveTable
Description copied from interface:ModbusSlave
Gets the Modbus-Slave-Table for this OpenEMS-Component.- Specified by:
getModbusSlaveTable
in interfaceModbusSlave
- Parameters:
accessMode
- filters the Modbus-Records that should be shown- Returns:
- the Modbus-Slave-Table
-
defineModbusProtocol
Description copied from class:AbstractOpenemsModbusComponent
Defines the Modbus protocol.- Specified by:
defineModbusProtocol
in classAbstractOpenemsModbusComponent
- Returns:
- the ModbusProtocol
- Throws:
OpenemsException
- on error
-
getTimedata
Description copied from interface:TimedataProvider
Gets theTimedata
service.- Specified by:
getTimedata
in interfaceTimedataProvider
- Returns:
- the service or null if it is not (yet) available.
-