Programming
CX8030 / CX8031
51
Version: 1.6
VAR_INPUT
VAR_INPUT
sNetID : T_AmsNetId := ''; (* '' = local netid *)
iPLCPort : UINT := AMSPORT_R0_PLC_RTS1; (* PLC Runtime System for writing persis-
tent data *)
iUPSPort : UINT := 16#4A8; (* Port for reading Power State of UPS, dafault 16#4A8 *)
tTimeout : TIME := DEFAULT_ADS_TIMEOUT; (* ADS Timeout *)
eUpsMode : E_S_UPS_Mode := eSUPS_WrPersistData_Shutdown; (* UPS mode (w/wo writing persis-
tent data, w/wo shutdown) *)
ePersistentMode : E_PersistentMode := SPDM_2PASS; (* mode for writing persistent data *)
tRecoverTime : TIME := T#10s; (* ON time to recover from short power fail-
ure in mode eSUPS_WrPersistData_NoShutdown/eSUPS_CheckPowerStatus *)
END_VAR
E_S_UPS_Mode
sNetID
: AmsNetID of the controller.
iPLCPort
: Port number of the PLC runtime system (AMSPORT_R0_PLC_RTS1 = 801,
AMSPORT_R0_PLC_RTS2 = 811, AMSPORT_R0_PLC_RTS3 = 821, AMSPORT_R0_PLC_RTS4 = 831).
iUPSPort
: Port number via which the UPS status is read (standard value is 16#4A8).
tTimeout
: Timeout for the execution of the QuickShutdown.
eUpsMode
: The eUpsMode defines whether persistent data are to be written and whether a
QuickShutdown is to be performed.
Standard value is eSUPS_WrPersistData_Shutdown, i.e. with writing of the
persistent data and then QuickShutdown. See E_S_UPS_Mode.
ePersistentMode
: Mode for the writing of the persistent data. Standard value is SPDM_2PASS.
SPDM_2PASS, all persistent data are saved at once, which can lead to the cycle
time being exceeded.
SPDM_VAR_BOOST, here, each persistent variable is written separately; if there is
a large amount of persistent data this can accordingly take many cycles. This is not recommended as some
data may be lost if the time of the seconds UPS is not sufficient.
tRecoverTime
: Time after which the UPS reverts to the PowerOK status in the case of UPS modes
without shutdown.
The tRecoverTime must be somewhat longer than the maximum holding time of the
UPS, since the UPS switches off even when the voltage returns.
VAR_OUTPUT
VAR_OUTPUT
bPowerFailDetect : BOOL; (* TRUE while powerfailure is detected *)
eState : E_S_UPS_State; (* current ups state *)
END_VAR
E_S_UPS_State
bPowerFailDetect
: True during the power failure; False if the supply voltage is present.
eState
: Internal state of the function block, for values see E_S_UPS_State.
VAR_GLOBAL
VAR_GLOBAL
eGlobalSUpsState : E_S_UPS_State; (* current ups state *)
END_VAR
E_S_UPS_State
eGlobalUpsState
: Internal state of the function block as a global copy of the VAR_OUTPUT
eState
; for
values see E_S_UPS_State.
Содержание CX8010
Страница 1: ...Manual CX8030 CX8031 CX8030 PROFIBUS Master CX8031 PROFIBUS Slave 1 6 2018 02 09 Version Date...
Страница 2: ......
Страница 74: ...PROFIBUS CX8030 CX8031 74 Version 1 6...