Interface BridgeModbus
- All Superinterfaces:
OpenemsComponent
- All Known Subinterfaces:
BridgeModbusSerial
,BridgeModbusTcp
,SimulatorModbus
- All Known Implementing Classes:
AbstractModbusBridge
,BridgeModbusSerialImpl
,BridgeModbusTcpImpl
,DummyModbusBridge
,SimulatorModbusImpl
-
Nested Class Summary
-
Method Summary
Modifier and TypeMethodDescriptiondefault void
_setCycleDelay
(long value) Internal method to set the 'nextValue' onBridgeModbus.ChannelId.CYCLE_DELAY
Channel.default void
_setCycleTimeIsTooShort
(boolean value) Internal method to set the 'nextValue' onBridgeModbus.ChannelId.CYCLE_TIME_IS_TOO_SHORT
Channel.void
addProtocol
(String sourceId, ModbusProtocol protocol) Adds a Protocol with a source identifier to this Modbus Bridge.Gets the Cycle Delay in [ms], seeBridgeModbus.ChannelId.CYCLE_DELAY
.default LongReadChannel
Gets the Channel forBridgeModbus.ChannelId.CYCLE_DELAY
.Gets the Cycle-Time-is-too-short State.default StateChannel
Gets the Channel forBridgeModbus.ChannelId.CYCLE_TIME_IS_TOO_SHORT
.void
removeProtocol
(String sourceId) Removes a Protocol from this Modbus Bridge.void
retryModbusCommunication
(String sourceId) The Modbus Bridge marks defective Components, e.g.Methods inherited from interface io.openems.edge.common.component.OpenemsComponent
_channel, _getChannelAs, alias, channel, channel, channels, debugLog, getComponentContext, getState, getStateChannel, hasFaults, id, isEnabled, serviceFactoryPid, servicePid
-
Method Details
-
getCycleTimeIsTooShortChannel
Gets the Channel forBridgeModbus.ChannelId.CYCLE_TIME_IS_TOO_SHORT
.- Returns:
- the Channel
-
getCycleTimeIsTooShort
Gets the Cycle-Time-is-too-short State. SeeBridgeModbus.ChannelId.CYCLE_TIME_IS_TOO_SHORT
.- Returns:
- the Channel
Value
-
_setCycleTimeIsTooShort
default void _setCycleTimeIsTooShort(boolean value) Internal method to set the 'nextValue' onBridgeModbus.ChannelId.CYCLE_TIME_IS_TOO_SHORT
Channel.- Parameters:
value
- the next value
-
getCycleDelayChannel
Gets the Channel forBridgeModbus.ChannelId.CYCLE_DELAY
.- Returns:
- the Channel
-
getCycleDelay
Gets the Cycle Delay in [ms], seeBridgeModbus.ChannelId.CYCLE_DELAY
.- Returns:
- the Channel
Value
-
_setCycleDelay
default void _setCycleDelay(long value) Internal method to set the 'nextValue' onBridgeModbus.ChannelId.CYCLE_DELAY
Channel.- Parameters:
value
- the next value
-
addProtocol
Adds a Protocol with a source identifier to this Modbus Bridge.- Parameters:
sourceId
- the unique source identifierprotocol
- the Modbus Protocol
-
removeProtocol
Removes a Protocol from this Modbus Bridge.- Parameters:
sourceId
- the unique source identifier
-
retryModbusCommunication
The Modbus Bridge marks defective Components, e.g. if there are communication failures. If a component is marked as defective, reads and writes are paused for an increasing waiting time. This method resets the waiting time, causing the Modbus Bridge to retry if a Component is not anymore defective.Use this method if there is good reason that a Modbus Component should be available again 'now', e.g. because it was turned on manually.
- Parameters:
sourceId
- the unique source identifier
-