Overview

Th Beckhoff software components allow a configuration with the provided UPS devices of the industrial PC.


Beckhoff UPS software installation

UPS software components - Reference

Installation of the UPS software components from Beckhoff driver archive CD.

Operating systems supported:

  • Windows NT 4.0
  • Windows 2000
  • Windows XP and Windows XP Embedded;
  • Windows Vista and Windows 7 (from UPS Software version >= 3.0.0.5);

PS hardware supported:

  • Integrated 24V Beckhoff P24Vxxxx UPS at the serial interface;
  • Integrated 24V Beckhoff UPS on the CP9030-ISA or CP9035-PCI card;
  • APC devices supplied with Beckhoff Industrial PCs that support the Smart protocol.

The following languages are supported:

  • German
  • English

The following files are copied into the ..\System32 directory during installation:

  • TcUpsDrv.dll
  • TcUpsShellExt.dll
  • TcMM.sys
  • TcMMHelper.dll
  • TcUpsDll.dll
  • TcUpsMsgRes.dll
  • TcUpsSrv.exe (* NT 4.0, Vista, Windows 7 only )
  • TcUpsShellExt.cpl (* NT 4.0, Vista, Windows 7 only )

The ..\Program Files\Beckhoff\UPS Software Components\xxxx directory receives the HTML documentation files (xxxx-Language identifier):

  • TcUpsShellExt.chm

The ..\Winnt\Temp directory receives:

  • hhupd.exe (* HTML Help-Update, NT 4.0 only )
  • vcredist.exe (* Visual Studio 6.0 redistribution libraries, NT 4.0 only )
  • Visual Studio 2008 Runtime libraries

Carry out the following steps in order to install the software:

1. Close all running applications. Halt the UPS service (Power Options -> UPS -> Select -> Manufacturer -> (none)). Uninstall the previous version of the software from the PC (if there is any).

2. Execute Beckhoff_UPSvX.X.X.X.exe which will install the UPS software components ( X = version numbers).

Select the desired language, and confirm with Next

3. The version of the software to be installed is displayed in the following dialog.

4. The list with software components is displayed in the following dialog.

The NT4 installation shows two additional components:

  • HTML Help Update
  • Visual Studio 6.0 redistribution libraries

Confirm with Next.

5. The PC will have to be restarted after installation.

The installation is complete.


BECKHOFF UPS Configuration dialog.

UPS software components - Reference

Beckhoff UPS configuration dialog

Following installation under Win2K/XP/XPe the UPS configuration dialog will be found as an additional tab under Control Panel -> Power Options.

Under NT4.0 UPS configuration dialog can be called via the shortcut under Control Panel -> BECKHOFF UPS Configuration.

Under Windows Vista or Windows 7 UPS configuration dialog can be called via the start menue shortcut under: Start->All Programs->BECKHOFF->UPS Software Components->UPS Configuration.

The UPS devices that are connected to the serial interface can in fact be fully configured via the standard dialog under Control Panel -> Power Options -> UPS. The setting facilities are adequate for an office PC, but it is not always possible to achieve an optimum configuration through this dialog for an Industrial PC with a UPS. An additional dialog is therefore made available under Control Panel -> Power Options: BECKHOFF UPS Configuration.
This dialog can be used, for instance, to make device-specific settings on the CP903x card, or to carry out a firmware update for the P24Vxxxx UPS. The supplementary dialog also allows the maximum "time on battery" to be set to < 2 minutes, and for the delay time for switching off the UPS to be configured.

The settings of the configuration can only be changed by a user with administration rights, these dialogs are locked for other users.

Language switch: From UPS software version >= 2.0.0.9 the language of the UPS dialogs can be changed. The language settings are permanent changed for all users if a user with administrator rights change them. All other users can change the language, but the setting is not stored permanently.

The language setting "User Default" has a special meaning. It is recommended to use this setting on an operating system with a Multilingual User Interface (MUI). The UPS dialog is shown automatically in the language, which is chosen under system control->regions and language settings.
If a language is not supported by the Beckhoff UPS dialog the US english dialog is shown.

Power fail counter: From UPS software version >= 3.0.0.6. The counter is reset at UPS service start and counts the detected power fails.

Select...

UPS information

Device configuration...

Alarm configuration...

Advanced...

About...

Help...


System behaviour

UPS software components - reference

System behaviour: Beckhoff miniport driver for the Windows UPS service

Definitions:

Short power failure: tBatt < tCA

Long power failure: tBatt >= tCA

Value | Description | Properties
tBatt Time during which the system is operated via the battery. Variable, depending on the duration of the power failure.

If tBatt >= tCA the UPS service irrevocably starts shutting down the system.

tCA Maximum time on battery voltage before critical alarm. Once this time has elapsed the UPS service irrevocably starts shutting down the system. Configurable in minutes via the Beckhoff UPS configuration dialog.
If tCA = 0 the UPS service immediately starts shutting down the system.
tSDtask A time window provided by the UPS service for a shutdown application (shutdown task). Not configurable, fixed and limited to a maximum of 30 seconds.
  • NT4: tSDtask = 0 if no shutdown application was configured and
    tSDtask = tSDapp if a shutdown application was configured.
  • All other operating systems: tSDtask always requires 30 seconds.
tSDapp Time actually required by the shutdown application (shutdown task). Variable, depends on the features of the application. Limited to a maximum of 30 seconds. After 30 seconds the shutdown continues irrevocably.

tSDapp should always be < maximum of tSDtask.

tTCstop This time is required for stopping the TwinCAT system. During this time the UPS service stops all TwinCAT servers. Variable, depends on the number of configured TwinCAT servers. Limited to a maximum of 45 seconds. Shutdown continues irrevocably after 45 seconds.

tTCstop = 0 if no TwinCAT is installed or was already stopped previously.

tUPSoff Delay time for switching off the UPS. The actual shutdown of the operating system starts once the UPS service has completed all internal shutdown tasks. Once this time has started the operating system takes over control and continues with the shutdown (window applications and services including the UPS services are closed and the system is shut down completely). Once this time has elapsed the UPS irrevocably switches off the outputs and the IPC in order to save battery capacity. Configurable via the Beckhoff UPS configuration dialog. The available values are hardware-specific.

tUPSoff should always be > tSDwin.

tSDsrv | Time required by the UPS service for shutting down internal tasks. | tSDsrv = tSDtask + tTCstop
tSDwin | Time required by the operating system for a shutdown. | Variable, depends on the number of running applications that have to be closed.
tDlg For systems without soft power-off functionality (e.g. NT4):
  • Time during which the dialog: "It is now safe to turn off your computer" is displayed.

For systems with soft power-off functionality (e.g. XP):

  • With Beckhoff P24Vxxxx UPS: tDlg = 0, the UPS switches off the outputs and the IPC immediately.
  • With APC-UPS: Time during the IPC continues to be supplied with UPS voltage (standby mode).
 Variable, depends on the operating system used, the number of running applications, the motherboard and the UPS hardware:
tDlg = tUPSoff - tSDwin

tDlg should always be > 0. This value can only be influenced through tUPSoff.

For systems without soft power-off functionality the dialog should be visible at least for a short time before the UPS switches off the IPC.

For systems with APC-UPS and soft power-off functionality the IPC should switch off first, followed by the UPS.

tBoot | Time required by the operating system during the boot process until the UPS service is started. | Variable, depends on the number of applications and services that have to be started.

Long power failure during operation (tBatt >= tCA)

The UPS service has been started and is active. During a long power failure the UPS service irrevocably starts shutting down the system.

Short power failures during operation (tBatt < tCA)

The UPS service has been started and is active. Short power failures are bridged by the UPS. A shutdown through the UPS service is not initiated.

Power failure during the boot process

The UPS service is not yet active at this time. The UPS automatically switches to battery operation, thus bridging the power failure. The PC is booted up in battery mode. During a prolonged power failure the UPS service takes over control after the start and starts shutting down the system.

Restoration of supply and repeated power failures during UPS shutdown

The following diagram shows a case in which the UPS service initiates a shutdown and the supply is restored during the shutdown.

Once the UPS service has initiated the shutdown this process cannot be stopped and must be completed. Repeated power failures during the shutdown are bridged by the UPS. In order to enable the IPC to restart the external power supply is interrupted briefly (a few seconds).


UPS model selection

UPS software components - Reference

Select dialog

This dialog can be used to select the UPS model.

The correct ISA/PCI address must be configured for the CP903x UPS:

Search: If you have one of the integrated 24V UPS devices on the CP903x card and want to configure it for UPS service you can use the Search button to find the correct address of the CP903x ISA or PCI card.

Several CP903x cards can be fitted in one PC, but the UPS is only physically linked to one of them. The Search button can be used to look for all the CP903x cards. The appropriate card must then be selected.


UPS Info Dialog

This dialog shows the detailed UPS information. Depending on the hardware model there is more or less information available.

UPS/Power Supply:

  • Manufacturer: Manufacturer name.
  • Model: Model name.
  • Firmware Rev.: Firmware revision.
  • Serial Number: Serial number.
  • Last Battery Change/Service: [dd.mm.yy] or [mm/dd/yy].
  • Battery Load Level: [%].
  • Estimated UPS Runtime: [min]
  • Internal Temperature: [°C]
  • Load Current: [A]
  • UPS Fan Status: Beckhoff P24Vxxxx with firmware version >= 45.1.I only.
  • UPS Fan Speed: Beckhoff P24Vxxxx with firmware version >= 45.1.I only. The nominal fan speed is ~3000 RPM or ~10000 RPM.
  • Battery Voltage: [V].
  • Nominal Battery Voltage: [V].
  • Input Line Voltage: [V].

Intelligent Battery (e.g.: CX2100-0914):

  • Serial Number: Serial number.
  • Hardware Ver.: [major.minor-build].
  • Rated Capacity: [mAh].
  • Manufacturing Date: [dd.mm.yyyy]


Device configuration dialog

Dialog with device-specific settings.

Setting or function | Value range | Default value | Description | UPS software version | UPS hardware/firmware
Battery Type (combo box) C9900-U330,
C9900-U332,
User-Defined 		C9900-U330 Configures the used Beckhoff battery pack type. v3.0.0.13 Beckhoff P24Vxxxx UPS with a firmware version of 24.1.I or higher.
Battery Type (edit field) | 0..99 | 1 | Available only if "User-Defined" battery type is selected. The setting is necessary, for instance, to be able to calculate the remaining charge available under battery operation. | Beckhoff P24Vxxxx UPS with a firmware version of 24.1.I or higher.
Nominal Battery Capacity | 0..99900 [mAh] | 3400 | Available only if "User-Defined" battery type is selected.The setting is necessary, for instance, to be able to calculate the remaining charge available under battery operation. | Beckhoff P24Vxxxx UPS with a firmware version of 24.1.I or higher.
Internal Battery Resistance | 0..999 [mOhm] | 120 | Available only if "User-Defined" battery type is selected.The setting is necessary, for instance, to be able to calculate the remaining charge available under battery operation. | Beckhoff P24Vxxxx UPS with a firmware version of 24.1.I or higher.
Battery replace service interval 0..480 [months] 60 (5 years)

and checkbox not enabled

The user is able to enter/configure the battery replace service interval (number of months) before first warning is logged to Windows eventlog.

Use the checkbox to activate or deactivate the functionality. The functionality is only available if the battery change date and system time (in the task bar) is also set/configured.

The UPS service compares the configured battery change date to the configured service interval at service start. If battery replace date + service interval >= current system date => Windows Eventlog warning message will be logged.

The warning message do not reflects the real battery condition and can be used as reminder to check the real battery condition or battery age.

v3.0.0.8 Beckhoff P24Vxxxx UPS.
Last service date: 01.01.11*

-

- Shows the actual set battery replace/service date (last service on 1 January 2011).
Next service date: 01.01.16*

-

- Shows the estimated next battery replace/service date (next service on 1 January 2016).
Reset service interval remainder...

-

- Updates the record of the most recent battery change and resets the service interval remainder messages. The date is stored in the UPS's EEPROM, and can be examined in the UPS information dialog. Only Beckhoff P24Vxxxx and a few APC devices.
update to: 25.05.12*

-

- Shows the suggested service interval update date shown in the "Reset service interval" command dialog (25 May 2012).
Update firmware... - - Starts a firmware update. Beckhoff P24Vxxxx with firmware version 21.1.I or higher and other Beckhoff UPS models.
Self test - - Executes a self-test and displays the result:
  • "OK" - Test successful, the battery is OK;
  • "BT" - Failed because the battery capacity was insufficient, or because a battery is not even present;
  • "NG" - Failed as a result of overload;
  • "NA" - Test function does not exist;
 Only Beckhoff P24Vxxxx and a few APC devices.
Factory Defaults - - Restores the factory (default) settings. The default battery type setting is: C9900-U330. Please check your real battery type configuration. v3.0.0.8
OK - - Saves all settings and closes the dialog. Don't forgett to apply the changes at the Beckhoff UPS Configuration dialog too.
Cancel - - Discards all editable changes.

*) Example value.


Alarm configuration dialog

Displays the dialog with the settings governing how this system will behave in the event of a power failure. The settings on this dialog largely correspond to the same settings on the standard Power Options -> UPS -> Configure... dialog.

Setting or function | Value range | Default value | Description | UPS software version
Enable all notifications Disabled or enabled Disabled

(checkbox not selected)

This option can be used to instruct the operating system to send messages to the user in case of Power failure. This option is not available under NT4. -
Seconds between the power failure and first notification | 0..120 [s] | 5 | The delay after which the first "power fail" message will be sent. | v2.0.0.15
Seconds between subsequent power fail notifications | 0..300 [s] | 20 | The time that elapses before additional messages are sent to the user. | v2.0.0.15
Critical alarm - - The alarm is triggered once the battery voltage has fallen to a certain level or once battery operation has exceeded a certain time limit. -
Max. time on battery before critical alarm 0..720 [min] 2 If you have selected this option, then the UPS service will issue a critical alarm after the set time, and will shut down the PC. The critical alarm may, however, be issued earlier if the battery capacity is exhausted. If the value is set to 0, the PC will be shut down immediately in the event of a power failure, and the OS shutdown can no longer be stopped. -
Unit for max. time on battery before critical alarm | Seconds, Minutes | Minutes | Seconds are available only under Windows Vista, W7, WES7 (32 and 64 bit). | v3.0.0.13
When the alarm occurs, run this program (task) Disabled or Enabled Disabled

(checkbox not selected)

This option allows an application to be executed after an alarm has occurred, but before the actual shutdown (shutdown task). If selected then all found task scheduler tasks are listed in the combo box below. The user have to select one of the tasks. The default task (if existing) with the name: "UPS System Shutdown Program" is selected automatically it the task is configured for the first time. -
Combobox (task list) | Available task scheduler tasks | "UPS System Shutdown Program" | You cannot specify a command file that causes a dialog box to appear, because dialog boxes that require user input can impede a graceful system shutdown. The command file must finish running in 30 seconds. A run time that is greater than 30 seconds threatens the capability of Windows to complete a graceful system shutdown. Windows Task Scheduler executes the shutdown task in context of configured user account. The user account under which the schedule service runs may require specific file access permissions, user permissions and drive mappings. If the configured user name and password parameters match the currently logged-in user, the task will run interactively (visible in the foreground). For the system account the user name can be written as "NT AUTHORITY\SYSTEM", a password is not required. The system account has full access to the local machine but has no permissions on any other machines (or mapped drives) across the Network. Further information can be found in the Windows Task Scheduler documentation. | v3.0.0.10
New... - "UPS System Shutdown Program" Creates new task scheduler task with default name: "UPS System Shutdown Program". This command is only available under XP operating system. The command is only available if the default task is not allready in the task list.

Please use the task scheduler dialog in the MMC (Microsoft Management Console) to create new shutdown tasks on Windows Vista or 7 systems.

v3.0.0.10
Edit... - "UPS System Shutdown Program" Displays options that you can configure for a selected task scheduler task that will run before a system shutdown action occurs. This command is only available under XP operating system.

Please use the task scheduler dialog in the MMC (Microsoft Management Console) to edit the task configuration on Windows Vista or 7 systems.

v3.0.0.10
Run... - "UPS System Shutdown Program" Starts the selected task scheduler task for test purposes. This command is only available under XP operating system.

Please use the task scheduler dialog in the MMC (Microsoft Management Console) to test and run the task on Windows Vista or 7 systems.

v3.0.0.10
Task Scheduler v1.0 (not recommended) Disabled or enabled Disabled

(checkbox not selected)

Enables forced usage of XP task scheduler v1.0 interface on Windows Vista or 7 operating system.

The Task Scheduler v1.0 interface on Windows Vista or 7 offers only limited functionality.

v3.0.0.10
Finally, turn off the UPS Disabled or enabled Enabled

(checkbox is selected)

If you have selected this option, the UPS will switch the outputs off after the PC has been shut down, in order to save the battery charge (Standard: Selected). -
Turn UPS off wait time [s] Depends on hardware (see table below) 180 The PC must have properly shut down within this time. An internal timer in the UPS measures the time from when the OS began to shut down. Once this time has elapsed, the UPS switches off its outputs in order to save battery charge. Make sure that you have not selected too short a time for this.

The available delay times differ from one device to another. The times are read out from the device, and are placed in the ComboBox. The UPS service must be configured and started up with the appropriate UPS model to make this possible.

 v1.0.0.48
Advanced... - - Dialog with advanced shutdown or end session settings for systems without Soft-Power-Off feature (S5) (e.g. NT4). For additional info see: Advanced settings dialog. This option is not available on systems supporting Soft-Power-Off feature (deactivated). v2.0.0.12
Factory Defaults - - Restores default settings. -
OK - - Saves all settings and closes the dialog. Don't forgett to apply the changes at the Beckhoff UPS Configuration dialog too. -
Cancel - - Discards all editable changes and closes the dialog. -

*) Under NT4 this option is only available if you have installed the Microsoft Windows Task Scheduler (under IE4 you select the Task Scheduler under Additional Explorer Enhancements, and under IE5 you select the Offline Browsing Pack.

The table provides a brief summary of the various delay times for a few UPS models.

UPS model | Beckhoff P24Vxxxx UPS | Beckhoff 24V UPS on the CP903x card | APC Back-UPS Pro 280 | APC Smart-UPS 420
Available delay times in [s] | 20, 30*, 45*, 60, 90, 180, 300, 600 *only with UPS firmware >=28.1.I | 0, 2, 5, 10, 15, 25, 40, 60, 90, 120, 150, 180, 210, 240, 270, 600 | 20, 180, 300, 600 | 60, 180, 300, 600

Important instructions!

The delay time configured in the dialog is checked again in the UPS driver shortly before shutting down the OS, and if the value is not supported the next higher value is automatically sent to the UPS.

Example:

Suppose you have replaced an old Back-UPS Pro 280 with a Smart UPS 420, and that a delay time of 20 s had previously been configured in the dialog. The new UPS will then automatically be switched off after a delay time of 60 s.

At the same time the UPS driver will write a warning into the windows event log (under Application).

As from UPS software version v1.0.0.48 the following warning will be displayed if an unsupported delay time is found when the alarm configuration dialog is opened:

The unsupported delay time is placed into the ComboBox as (not supported):


Advanced Settings

UPS software components- Reference

Advanced Settings dialog

The following settings are only available in systems without Soft-Power-Off support (S5 state) (e.g. NT4 systems). A PC system with Soft-Power-Off support can switch off the power supply after shutdown. The end of a session includes a shutdown or restart of the PC, i.e. all settings relating to the end of the session not only apply to the shutdown, but are retained when the PC is restarted.

Once a mains-operated NT4 system has been shut down, it cannot distinguish between deliberate and non-deliberate power failure. This means the UPS software and the hardware cannot distinguish between a genuine power failure and the operator operating the main switch (in order to switch off the system completely). The UPS merely detects a power failure and switches to battery operation. If the operator has switched off the main switch, the PC will remain on battery power, eventually draining the battery. In order to prevent this, the Beckhoff P24Vxxxx UPS features an option to deactivate UPS protection after a certain delay time. During the delay time, the PC is protected against possible power failure. The PC will remain on until the external power supply is switched off.

System behaviour in the event of a session being ended by the user: The associated settings determine the system behaviour if the end of a session was not initiated by the UPS service, but by the user or the application (the user may have selected shutdown or restart via the start button).

End of session from battery: The options determine the system behaviour if the PC was running on battery at the time (start of the end of a session).

End of session from mains voltage: The options determine the system behaviour if the PC was running on mains voltage at the time (when the end of a session was initiated).

UPS off and on again if mains voltage OK: If this option is selected, the UPS (and the PC) switches off after the delay time and immediately on again once the external power supply is available again (power ON after power fail). This is the default behaviour for all systems, including systems with Soft-Power-Off support. The delay time for switching off the UPS has to be configured via the Alarm configuration dialog. If this option is selected and the PC is battery-operated, the PCs must not be restarted! Otherwise the PC may be switched off during the start-up phase!

Delayed UPS protection switch-off (only for systems without Soft-Power-Off support (State S5)): If this option is selected, UPS protection is deactivated after a configurable delay time, in order to enable the PC and the UPS to be switched off (e.g. via the main switch). This option is only supported by Beckhoff P24Vxxxx UPS and UPS firmware version >= 33.1.I. In other models this option is deactivated.

Delay time for switching off UPS protection (s): With shorter times, the PC (and the UPS) can be switched off more quickly after a shutdown. However, during a restart the PC may not be fully protected against voltage failure. With longer times and shutdown, it takes longer for the PC (and the UPS) to switch off. On the other hand, during a restart the PC is protected during the complete start-up phase. During a restart, UPS protection is activated before the delay time has elapsed, once the UPS service has resumed communication with the UPS.


About Dialog

The dialog shows the version numbers of the UPS software components.


UPS software components - Reference

Help dialog

Call the help dialog:


Configuration of P24Vxxxx

UPS software components - Reference

Configuring the Beckhoff P24Vxxxx UPS

1. Open the BECKHOFF UPS configuration dialog, and then go to Select....

2. Select Beckhoff from the list of manufacturers, select the Beckhoff P24Vxxxx as the model, and choose the appropriate COM port.

Close the dialog with Finish, and then with Apply. This will cause the UPS service to adopt the settings and start the UPS service.

3. Then, on the BECKHOFF UPS configuration dialog, go to Configure alarm...

Activate the following options (not absolutely essential).

Enable all notifications: This option will cause the operating system to send messages to the users whenever the power fails (not available under NT 4.0).

Critical alarm: The alarm is triggered once the battery voltage has fallen to a certain level or once battery operation has exceeded a certain time limit.

When the alarm occurs, run this program (task): This option can be used to execute an application when an alarm is raised (only available under NT 4.0 if the Microsoft Task Scheduler is installed).

Activate the following options!:

Minutes on battery before critical alarm: This option can be used to specify the battery operation time in minutes until the Critical alarm is triggered. The shutdown of the operating system is only initiated once the alarm has been triggered. This option should be selected in order to protect the battery. Set the "time on battery" to, for example, 2 min. Values between 0 and 720 minutes are permitted. The system will be shut down once this time has elapsed after a power failure. This option corresponds to the same option that can be set in the standard UPS dialog, with the difference that the shorter times of 0 and 1 minute can also be set.

Finaly, turn off the UPS: If this option is selected, the UPS will switch off its own outputs after shutdown in order to save the batteries. This option also corresponds to the same option that can be set via the standard UPS dialog. Standard value: Selected!.

Turn UPS off wait time [s]: After this delay the system should have shut down, and the UPS switches its outputs off in order to save the battery.

The following settings are only valid for systems without soft -power off -support ( e.g. NT4) and UPS firmware version >= 33.1.I.

4. Select Advanced... on the dialog Configure alarm...:

Configure the options like displayed. It will be assumed, that the pc can do a restart within 360 seconds. The UPS protection is active during this time. If the pc needs more time, the value has to be increased.
Close the dialog with OK,

5. Close the Configure alarm dialog with OK, and then click Apply.


P24Vxxxx Firmware update

UPS software components - Reference

Firmware update for the Beckhoff P24Vxxxx UPS

The following steps must be executed in order to update the firmware of the P24Vxxxx UPS:

1. Configure the UPS in the usual way via the BECKHOFF UPS configuration dialog. The PC must not be operated from battery voltage during the update. The new firmware file cannot be loaded from a network drive. Please copy the file on to the local hard disk. Close all running applications. A firmware update can only be executed on this UPS with firmware version 21.1.I or higher!

2. Go to the BECKHOFF UPS configuration dialog, and select Device configuration...

3. Select Firmware update...

Please read the hints. It is still possible to halt the update with No, or to continue with Yes.

4. Now you will be asked for the new firmware file.

Please navigate to your firmware file folder and select the new firmware file in the "Open firmware file" dialog.

(Older UPS software versions are asking for a keyword. Enter the keyword and confirm with OK).

5. The update is first initialised. It is then necessary to disconnect the PC from the voltage supply for a short period (mains and battery!). Then start the PC again.

If you now confirm with OK, the PC will be automatically shut down.

6. After restarting, go again to the BECKHOFF UPS configuration dialog

Please follow the instructions and continue the firmware update.

(If you are using an older version of the UPS software then Select Device configuration... and then Firmware update... again. Enter the keyword and confirm with OK. Select the new firmware file in the Open file dialog)

7. The new firmware is then loaded. Please note that this can take a few minutes.

8. Successfully updating the firmware is indicated by the following message:

If you now confirm with OK, the PC will be automatically shut down. The power supply to the PC must again be briefly interrupted (mains and battery!).

The new firmware version can be checked on the UPS information dialog after restarting.


Configuration of the CP903x UPS

UPS software components - Reference

Configuration of the integrated 24V UPS at the CP903x card

1. Open the BECKHOFF UPS configuration dialog, and then go to Select....

2. Select Beckhoff from the list of manufacturers, and select the Beckhoff CP903x as the model.

Use the Search... button to look for the address of the CP903x card. If more than one address is found (you have more than one CP903x card in the PC) you must select the correct address from the list, and then close the dialogue with OK.

Close the dialog with Finish, and then with Apply. This will cause the UPS service to adopt the settings and start the UPS service.

3. Then, on the BECKHOFF UPS configuration dialog, go to Alarm configuration...

Activate the following options (not absolutely essential).

Enable all notifications: This option will cause the operating system to send messages to the users whenever the power fails (not available under NT 4.0).

Critical alarm: The alarm is triggered once the battery voltage has fallen to a certain level or once battery operation has exceeded a certain time limit.

When the alarm occurs, run this program: This option can be used to execute an application when an alarm is raised (only available under NT 4.0 if the Microsoft Task Scheduler is installed).

Activate the following options!:

Minutes on battery before critical alarm: This option can be used to specify the battery operation time in minutes until the Critical alarm is triggered. The shutdown of the operating system is only initiated once the alarm has been triggered. This option should be selected in order to protect the battery. Set the "time on battery" to, for example, 2 min. Values between 0 and 720 minutes are permitted. The system will be shut down once this time has elapsed after a power failure. This option corresponds to the same option that can be set in the standard UPS dialog, with the difference that the shorter times of 0 and 1 minute can also be set.

Finally, turn off the UPS:If this option is selected, the UPS will switch off its own outputs after shutdown in order to save the batteries. This option also corresponds to the same option that can be set via the standard UPS dialog. Standard value: Selected!.

Turn UPS off wait time [s]: After this delay the system should have shut down, and the UPS switches its outputs off in order to save the battery.

Close the dialog with OK, and then click Apply.


Configuration of the CP903x UPS

UPS software components - Reference

Configuration of the integrated 24V UPS CX2100-09x4

1. Open the BECKHOFF UPS configuration dialog, and then go to Select....

2. Select Beckhoff from the list of manufacturers, and select the Beckhoff CX2100-09x4.

Close the dialog with Finish, and then with Apply. This will cause the UPS service to adopt the settings and start the UPS service.

3. Then, on the BECKHOFF UPS configuration dialog, go to Alarm configuration...

Activate the following options (not absolutely essential).

Enable all notifications: This option will cause the operating system to send messages to the users whenever the power fails (not available under NT 4.0).

Critical alarm: The alarm is triggered once the battery voltage has fallen to a certain level or once battery operation has exceeded a certain time limit. For CX2100-units this value must be set to "0".

When the alarm occurs, run this program: This option can be used to execute an application when an alarm is raised (only available under NT 4.0 if the Microsoft Task Scheduler is installed).

Activate the following options!:

Minutes on battery before critical alarm: This option can be used to specify the battery operation time in minutes until the Critical alarm is triggered. The shutdown of the operating system is only initiated once the alarm has been triggered. This option should be selected in order to protect the battery. Set the "time on battery" to, for example, 2 min. Values between 0 and 720 minutes are permitted. The system will be shut down once this time has elapsed after a power failure. This option corresponds to the same option that can be set in the standard UPS dialog, with the difference that the shorter times of 0 and 1 minute can also be set.

Finally, turn off the UPS:If this option is selected, the UPS will switch off its own outputs after shutdown in order to save the batteries. This option also corresponds to the same option that can be set via the standard UPS dialog. Standard value: Selected!.

Turn UPS off wait time [s]: After this delay the system should have shut down, and the UPS switches its outputs off in order to save the battery. This parameter must be set to "0" for CX20x0-units.

Close the dialog with OK, and then click Apply.


UPS status in the Windows Registry

UPS software components - Reference

UPS information in Windows registry

The UPS service communicates with the Beckhoff UPS driver through the Windows registry. It's allowed to read the UPS registry information. Please use the "Beckhoff UPS Configuration" dialog to change (write) the UPS konfiguration. Be very carefull if you try to change (write) the UPS configuration in the Windows registry directly.

Status information

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\UPS\Status

The keys under here are continuously updated by the UPS driver whenever the status of the UPS changes.

Note:

Not all UPS devices are able to deliver all status infomation. Overview about the supported status information.

Value name | Value type | Description | Default value
BatteryCapacity | REG_DWORD | The percent of battery capacity remaining in the UPS. This elemet is represented as a value in the range of 0 through 100 percent. (The displayed value is rounded to the nearest integer.) | 0
BatteryStatus REG_DWORD The current status of the UPS batteries. This member can be of the following value:
  • 0 := The battery status is unknown;
  • 1 := The batteries are OK;
  • 2 := The batteries need to be replaced;
 0
CommStatus REG_DWORD The status of the communication path to the UPS. This member can be of the following value:
  • 0 := The communication path to the UPS is unknown;
  • 1 := The communication path to the UPS is OK;
  • 2 := The communication path to the UPS has been lost;
 0
FirmwareRev REG_SZ Reports the UPS firmware revision as a displayable string. ""
SerialNumber REG_SZ Reports the UPS serial number as a displayable string. ""
TotalUPSRuntime | REG_DWORD | The amount of remaining UPS run time, in minutes. | 0
TotalUPSRuntimeSec | REG_DWORD | The amount of remaining UPS run time, in seconds. Implemented in UPS software v3.0.0.13 and higher. | 0
UtilityPowerStatus REG_DWORD Reports the status of utility-supplied power into the UPS. This member can be of the following value:
  • 0 := The status of utility-supplied power is unknown;
  • 1 := Utility-supplied power is OK;
  • 2 := A power failure has occurred;
 0
TcPowerFailCnt | REG_DWORD | Power fail counter. Increments every time the UPS service detects power fail. | 0
BatteryReplaceDate REG_SZ Set battery replace date. The latest battery replace date can be set using the Beckhoff UPS Configuration->Configure device.. dialog command. Implemented in UPS software v3.0.0.8 and higher. ""
TcChargeFlags REG_DWORD Battery charge status flags. This member can be one or more of the following values (bits):
  • 0 := Unknown status (all bits are set to 0)
  • 1 := Load status "High" (bit 0 is set);
  • 2 := Load status "Low" (bit 1 is set);
  • 4 := Load status "Critical" (bit 2 is set);
  • 8 := Load status "Charging" (bIt 3 is set);
  • bits 4..6 are reserved;
  • 128 := No battery (bit 7 is set);
  • 256 := UPS fan error (bit 8 is set);
  • bit 9 is reserved;
  • 1024 := Battery replace service intervall has expired (bit 10 is set). Implemented in UPS software v3.0.0.8 and higher;
  • bits 11..31 are reserved;
 0

Status information about intelligent battery unit (e.g.: CX2100-0914 UPS model):

Value name | Value type | Description | Default value
BatteryHardwareVersion | REG_SZ | Hardware version of battery unit. Implemented in UPS software v3.0.0.13 and higher. | ""
BatteryProductionDate | REG_SZ | Manufacturing date of the battery unit. Implemented in UPS software v3.0.0.13 and higher. | ""
BatteryRatedCapacity | REG_DWORD | Rated battery capacity (mAh). Implemented in UPS software v3.0.0.13 and higher. | 0
BatterySerialNumber | REG_SZ | Serial number of battery unit. Implemented in UPS software v3.0.0.13 and higher. | ""

Configuration settings

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\UPS\Config

The keys under here are used by the UPS service to configure the UPS.

Value name | Value type | Description | Default value
Vendor | REG_SZ | UPS vendor name | "(none)"
Model REG_SZ UPS model name ""
RunTaskEnable REG_DWORD Enable/disable the configuration of the Task Scheduler shutdown task:
  • 0 := Disable;
  • 1 := Enable;
  • other values are not allowed;
 0
TaskName REG_SZ Name of the Task Scheduler shutdown task. The Beckhoff UPS configuration dialog is creating shutdown task with the name: "UPS System Shutdown Program". ""
TaskFolder REG_SZ Folder name of the Task Scheduler shutdown task. Empty string is representing the root folder. Implemented only in UPS software v3.0.0.10 and higher. ""
TaskCompatibility REG_DWORD Task Scheduler v1.0 compatibility settings. Implemented only in UPS software v3.0.0.10 and higher.
  • 0 := Automatic, use the newest Task Scheduler interface version (currently v2.0);
  • 1 := Force use of Task Scheduler v1.0 interface;
  • 2 := Force use of Task Scheduler v2.0 interface;
  • other values are not allowed;
 0
RunTaskWait REG_DWORD The max. run time (execution time) of the shutdown task in seconds. After this time the UPS service continues the windows shutdown process.

Implemented/available only in UPS software v3.0.0.8 and higher and available only under Windows Vista, W7, WES 7 (32 and 64 bit) Older operating systems have fixed max. run time value of 30 seconds.

30
ShutdownOnBatteryEnable REG_DWORD Enable/disable the shutdown of operating system after critical alarm:
  • 0 := Disable;
  • 1 := Enable;
  • other values are not allowed;
 1
ShutdownOnBatteryWait | REG_DWORD | Max. run time on batteries before critical alarm. This element is represented as value in range from 0 through 720 minutes. Other values are not allowed. | 2
ShutdownOnBatteryWaitUnit REG_DWORD

Unit of max. run time on batteries before critical alarm. Implemented only in UPS software v3.0.0.13 and higher.

  • 0 := Seconds. Available only under Windows Vista, W7, WES 7 (32 and 64 bit).
  • 1 := Minutes.
 1
NotifyEnable REG_DWORD Enable/disable sending of "power fail" messages:
  • 0 := Disable;
  • 1 := Enable;
  • other values are not allowed;
 0
TurnUPSOffEnable REG_DWORD Activate/deactivate switching off the UPS outputs after shutdown:
  • 0 := Deactivate;
  • 1 := Activate (switch off);
  • other values are not allowed;
 1
TurnUPSOffWait | REG_DWORD | Max. delay time in seconds to switch off the UPS output in order to save battery charge. The allowed values may vary and depends on the used UPS model. | 180
BatteryReplaceNotifyEnable REG_DWORD Enable/disable logging of battery replace warnings in Window Eventlog:
  • 0 := Disable;
  • 1 := Enable;
  • other values are not allowed;

Implemented in UPS software v3.0.0.8 and higher.

0
BatteryReplaceNotifyWait REG_DWORD Months between the latest battery replace date (if known) and the first battery replace warning in the Windows Eventlog. This element is represented as value in range from 0 through 480 months. Other values are not allowed.

Implemented in UPS software v3.0.0.8 and higher.

60

Further settings

KEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\UPS
Value name | Value type | Description | Default value
FirstMessageDelay | REG_DWORD | Seconds between the power failure and first message send to the user. | 5
MessageInterval | REG_DWORD | Seconds between subsequent power fail messages send to the user. | 20


UPS FAQ

UPS software components - Reference

FAQ's and known issues

1. If, when Windows NT restarts (reboots), an P24Vxxxx UPS is installed, its battery may be discharged or the UPS function may be shut down.

The information in this article applies only to:
Microsoft Windows NT Workstation 4.0
Microsoft Windows NT Server 4.0

CAUSE
During the boot sequence, Windows NT sends configuration and detection code to the COM port to determine baud rate and FIFO information, and for mouse detection. The string sent to the port may contain letters, which the UPS interprets as a command for Shutdown or turn off.

WORKAROUND
The adding of the /noserialmice:COMx switch in the Boot.ini, where x equals the COM port number,
stops the detection process of a mouse on that port.

1. Make a backup copy of the Boot.ini file.
2. Remove the hidden, system, and read-only attributes from the Boot.ini file.
3. Using a text editor (such as Notepad) open the Boot.ini file.
4. Add the /NoSerialMice:COMx option to the end of each entry in the [operating systems] section of Boot.ini.
5. Save Boot.ini and quit Notepad.
6. Restore the hidden, system, and read-only attributes to the Boot.ini file.
7. Shutdown and restart Windows NT.

Example for UPS configured on COM4:

multi(0)disk(0)rdisk(0)partition(1)\WINNT="Windows NT"
/NOSERIALMICE:COM4

multi(0)disk(0)rdisk(0)partition(1)\WINNT="Windows NT [VGA mode]"
/basevideo /sos /NOSERIALMICE:COM4

2. The UP dialog under Windows shows battery state: low

The information in this article applies only to:
Microsoft Windows 2000 (german)

The battery state low is only shown in the german version of the OS. With an english OS the device shows the value:good.

It is possible that the translation of the ressources is not correct.

3. The UPS service reports application error during shutdown.

The information in this article applies only to:
Microsoft Windows XP Professional
Microsoft Windows XP Home Edition
Microsoft Windows XP Embedded

WORKAROUND
Please install the latest Windows XP Service Pack.

4. Can I use the Beckhoff UPS Software with Windows XP Home Edition?

Yes. Please install the latest Windows XP Service Pack too.

5. Can I disable (hide in the control panel) the integrated Windows NT4 UPS configuration dialog?

The information in this article applies only to:
Microsoft Windows NT Workstation 4.0
Microsoft Windows NT Server 4.0

Yes, with this registry entry:

Add new key: [HKEY_CURRENT_USER\Control Panel\Don't Load]
and new string value: "UPS.cpl"="no"

6. At power fail no messages are sent to the user even though this option is activated in the Alarm configuration dialog.

The information in this article applies only to:
Microsoft Windows XP SP2

The messages are sent internally from the Microsoft-UPS Service by the help of the massage service. That means the Beckhoff UPS Driver sends the messages not itself. To send messages the Microsoft UPS Service uses a similar mechanism like the mechanism of the net send command.

If you can send on your PC a message with net send to oneself, the UPS service can send messages to the user.

Make sure that the following services under Start->Settings->Control Panel->Administrativ Tools->Services are started. Set the start modus to Automatic:

- Messenger

- Alerter

- Workstation

Please proof with the following command line command if the Alias names are available. Only to Alias names messages can be sent.

C:\>net name

Name
-------------------------------------------
COMPUTER1
HUGO
The command completed successfully.

C:\>

In the example above two entries exist: COMPUTER1 and HUGO. Only to these Alias names messages can be sent.

If no entries exist, the following Workaround helps: Install additionally a Loopback-Adapter:

1. Select Start->Settings->Control Panel->Add Hardware .

2. In the next dialog select the option hardware already connected and confirm with Next.

3. From the list of installed hardware select: Add a new hardware device and confirm with Next.

4. In the next dialog choose the option to install hardware manually (Advanced). And confirm with Next.

5. From the list of device types choose: Network adapters and confirm with Next.

6. For manufacturer choose Microsoft and for device Microsoft Loopback Adapter. Confirm further dialogs with Next and Finish.

7. Next select Start->Settings->Network connections. Give the Loopback-Adapter a fictive address. Confirm the dialogs with OK.

8. At the end proof again the Alias names with net name.

7. The IPC cannot be shut down via the external power-off switch

The information provided in this article applies to the following OS:
Microsoft Windows XP

The behaviour described below does not apply to UPS shutdown in the event of a power failure. In the case of a power failure the IPC is always shut down, even if a logon/password-protected screen saver or computer lock is active.

a) The logon screen saver is active.

The function of the power-off button is suppresses if the logon screen saver is active. The IPC cannot be switched off via the external switch. The PC starts shutting down as soon as the mouse is moved.

WORKAROUND:
 In the registry set HKEY_CURRENT_USER\Control Panel\Desktop\ScreenSaverActive to 0. This setting only deactivates the logon screen saver, not the screen saver for the logged in user. If a screen saver is required for the logon dialog, under power options the system can be configured such that the monitor switches off after a certain time.

b) A password-protected screen saver is active.

The function of the power-off button is suppresses if a user is logged in and a password-protected screen saver is active. The IPC cannot be switched off via the external switch. This behaviour is correct and prevents that an unauthorised person can switch off the IPC in the absence of the user.

WORKAROUND:
Do not issue a screen saver password or enter the password first before pressing the power-off switch.

c) Another user is logged in via remote desktop.

If a user is logged in via remote desktop, the function of the power-off button is suppressed. A message appears indicating that another user is logged and could lose data. There is no workaround for this situation. The IPC can only be shut down once the message was acknowledged (continue shutdown).

d) Lock computer was selected.

If the lock computer was selected (the logon screen with the password request appears), the function of the power-off button is suppressed. There is no workaround for this situation. This behaviour is correct and prevents that an unauthorised person can switch off the IPC in the absence of the user.

8. Access denied. No communication to UPS at COM1 if on-screen keyboard (OSK) is used.

Communication problems may occure if the UPS is configured to use COM1serial communication port and on-screen keyboard is in use. The on-screen keyboard has the ability to start automatically during the IPC start up (boot up) and to receive user input from serial mouse at COM1. In this case the on-screen keyboard don't allows the UPS software the use of serial communication port COM1. The UPS software is trying to open the same allready used serial communication port. The access fails and Win32 error code: Access is denied (0x5) is reported in Windows application log. Please check all running applications if they are using/accessing the same serial communication port.

WORKAROUND:
Change the configuration of the on-screen keyboard:

1. Start on-screen keyboard (OSK).

2. From OSK menue select 'Settings->typing mode'.

3. Select 'Joystick or key to select' and then 'Advanced'.

4. Untick box marked 'Serial, parallel, or game port'.

5. Select 'OK' from 'Scanning Options' dialog .

6. Select 'Click to select' from 'Typing Mode' dialog.

7. Select 'OK' from 'Typing Mode' dialog.

9. The "UPS Shutdown Program" task is not executed if the task configuration is changed to "Windows 7, Windows 2008 R2" or "Windows Vista, Windows Server 2008".

The information in this article applies only to:
Windows Vista
Windows 7
Windows 2008
Windows 2008 R2

CAUSE:

The "Beckhoff UPS Configuration" dialog creates and configures shutdown task for use with Task Scheduler v1.0 interface. After the configuration change (e.g. to Windows 7 or Windows Vista) the shutdown task can only be executed using Task Scheduler v2.0 interface. Older implementations of "Beckhoff UPS Software" are supporting only Task Scheduler v1.0 interface.

WORKAROUND:

Please update your "Beckhoff UPS Software" to newer Version >= 3.0.0.10. The newer Version supports Task Scheduler v2.0 too.


Battery driver for Windows CE

Beckhoff Industrial PCs with Windows CE and 24 V UPS support are supplied with a special Beckhoff battery driver for Windows CE. In these devices the driver is included in the standard CE image. No further configuration settings are required. The UPS hardware is wired internally with the on-board electronics. Only the external UPS battery pack has to be connected to the device (see description in the device documentation).

Power Options in the Control Panel

The Power Options dialog in the Control Panel shows the status of the external power supply and the remaining battery capacity.

Windows CE API interface for applications

Windows CE applications can access the UPS status information cyclically via the GetSystemPowerStatusEx2 API function call.

DWORD GetSystemPowerStatusEx2(
  PSYSTEM_POWER_STATUS_EX2 pSystemPowerStatusEx2,
  DWORD dwLen,
  BOOL fUpdate
);

typedef struct _SYSTEM_POWER_STATUS_EX2 {
  BYTE ACLineStatus;
  BYTE BatteryFlag;
  BYTE BatteryLifePercent;
  BYTE Reserved1;
  DWORD BatteryLifeTime;
  DWORD BatteryFullLifeTime;
  BYTE Reserved2;
  BYTE BackupBatteryFlag;
  BYTE BackupBatteryLifePercent;
  BYTE Reserved3;
  DWORD BackupBatteryLifeTime;
  DWORD BackupBatteryFullLifeTime;
  DWORD BatteryVoltage;
  DWORD BatteryCurrent;
  DWORD BatteryAverageCurrent;
  DWORD BatteryAverageInterval;
  DWORD BatterymAHourConsumed;
  DWORD BatteryTemperature;
  DWORD BackupBatteryVoltage;
  BYTE BatteryChemistry;
  //  Add any extra information after the BatteryChemistry member.
} SYSTEM_POWER_STATUS_EX2, *PSYSTEM_POWER_STATUS_EX2, *LPSYSTEM_POWER_STATUS_EX2;

Please note that not all parameters are supported by the Beckhoff UPS. The main member variables include:

ACLineStatus: Status of the external power supply.

BatteryLifePercent: Battery charge status in percent.

BatteryLifeTime: Remaining battery capacity.

Further information about this API function can be found in the Microsoft online documentation.

UPS interface for TwinCAT PLC

A TwinCAT PLC application can access the UPS status information in read mode via function block FB_GetUPSStatus. Detailed documentation of the function block can be found here: FB_GetUPSStatus.


System behaviour: Battery driver for Windows CE

UPS software components - reference

System behavior: Battery driver for Windows CE

In the event of a power failure the UPS automatically switches to battery operation. The device switches off after it has been running in battery mode for a configurable maximum time.

The maximum time for battery operation is set to 180 seconds by default. This time is configurable via a Windows registry entry.

Start the Registry Editor and search for the following key:

HKEY_LOCAL_MACHINE\Drivers\BuiltIn\Battery\Config\

Search for the following value:

ShutdownOnBatteryWait  REG_DWORD 0x000000b4 (180)

The time is specified in seconds. Permitted range: <0..16200> seconds (corresponds to 270 minutes).

If the value is set, for example, to 0 the shutdown commences immediately in the event of a power failure. The device switches off after a maximum of 20 seconds.


FB_GetUPSStatus

TwinCAT PLC Library: IO Functions

FUNCTION_BLOCK FB_GetUPSStatus

Requirements under NT4, Win2K, WinXP, WinXP embedded:

  • The Beckhoff UPS software components are installed (additional tab under Control Panel->Energy Options->Beckhoff UPS Configuration );.
  • The UPS has been configurated with the Windows UPS service ( Control Panel->Energy Options->UPS ) or the Beckhoff Shell extension ( Control Panel->Energy Options->Beckhoff UPS Configuration ). Further information about the UPS configuration can be found in the considering documentation.

Requirements under Windows CE:

  • Beckhoff CE devices with 24 V UPS service are delivered with a special Beckhoff Battery Driver for Windows CE. The driver is included in the standard CE Image. No further configuration settings are required.

With the FB_GetUPSStatus function block the PLC can read the status of a UPS hardware. The block is level triggered, which means that the status information is only cyclically read while the bEnable input is set. To maintain system loading at a low level, the status information is only read approximately every 4.5 s. When the bValid output is set, the most recently read data is valid. The most recent read cycle was, in other words, executed without error. If an error occurs, the read cycle is repeated, and the error signal is automatically reset as soon as the cause of the error (e.g. no communication with the UPS) has been corrected.

VAR_INPUT

VAR_INPUT
    sNetId		:T_AmsNetId;
    nPort		:T_AmsPort;	(* 0 = Windows UPS service / Windows Battery driver  *)
    bEnable		:BOOL;
END_VAR

sNetId: It is possible here to provide the AmsNetId of the TwinCAT computer on which the function to be executed. If it is to be run on the local computer, an empty string can be entered.

nPort: ADS port number. Set this value to zero. Other port numbers are reserved for applications in future.

bEnable: If the input is set, the UPS status is read cyclically.

VAR_OUTPUT

VAR_OUTPUT
    bValid		:BOOL;
    bError		:BOOL;
    nErrId		:UDINT;
    stStatus		:ST_UPSStatus;
END_VAR

bValid: If this output is set the data in the ST_UPSStatus structure are valid (no error occurs at the last read cycle).

bError: This output is set if an error occurs by execution of the function.

nErrId: Supplies the Ads error number or a command specific error code (table) when bError output is set.

stStatus: Structure with the status information of UPS.

Error codes | Error description
0x0000 | no error
0x8001 | UPS configuration error. Perhaps the UPS is not configured correctly, or no UPS is configured.
0x8002 | Communication error. The communication to the UPS has been interrupted.
0x8003 | Error by reading the status data.

Note:

Not all UPS devices are able to deliver status infomation. Some devices can´t deliver e.g BatteryLifeTime or BatteryReplace-Status.

Example for a call in FBD:

Online data with status information of UPS:

Development environment Target system type UPS hardware PLC libraries to include
TwinCAT v2.8.0, Build > 745

TwinCAT v2.9.0, Build > 945

 PC (i386)

  • Beckhoff P24Vxxxx USV;
  • Integrated Beckhoff Industrial PC 24V UPS connected to CP903x ISA or PCI card;
  • With Beckhoff Industrial PC's delivered APC UPS models supporting smart protocol and configured with Windows UPS Service;
 TcIoFunctions.Lib

( Standard.Lib; TcBase.Lib; TcSystem.Lib; TcUtilities.Lib are included automatically )


ST_UPSStatus

TwinCAT PLC Library: IO Functions

TYPE ST_UPSStatus

TYPE ST_UPSStatus
STRUCT
    Vendor				: STRING;			(* Reports the UPS vendor name as displayable string. *)
    Model				: STRING;			(* Reports the UPS model name as displayable string. *)
    FirmwareRev			: STRING; 		(* Reports the UPS firmware revision as a displayable string. *)
    SerialNumber			: STRING; 		(* Reports the UPS serial number as a displayable string. *)
    BatteryLifePercent 		: DWORD; 			(* The percent of battery capacity remaining in the UPS, represented as a value in the range of 0 through 100. *)
    BatteryLifeTime 			: DWORD; 			(* The amount of remaining UPS run time, in minutes. *)
    eBatteryStatus			: E_BatteryStatus; 	(* The current status of the UPS batteries. *)
    eCommStatus			: E_UpsCommStatus; 	(* The status of the communication path to the UPS. *)
    ePowerStatus			: E_UpsPowerStatus; 	(* Reports the status of utility-supplied power into the UPS. *)
    nPowerFailCnt 			: DWORD; 			(* Power fail counter. Increments every time the UPS service detects power fail. *)
    dwChargeFlags			: DWORD; 			(* Most reserved for future use.
        Battery charge status flags. This member can be one or more of the following values.
        0:	Unknown status		(all bits set to 0)
        1: 	High			(bit 0 is set)
        2: 	Low			(bit 1 is set)
        4: 	Critical			(bit 2 is set)
        8:	Charging			(bit 3 is set)
        -	-			(bits 4 - 6 reserved)
        128:	No battery		(bit 7 is set)
        256: 	UPS fan error		(bit 8 is set)
        -	-			(bits 9 reserved)
        1024: 	Service interval message 	(bit 10 is set)
        -	-			(bits 11 - 31 reserved)
     *)
END_STRUCT
END_TYPE

Not all UPS devices are able to deliver status infomation.

X : The status info is present.

Status info | Beckhoff P24Vxxxx UPS | Beckhoff 24V UPS connected to CP903x ISA or PCI card | APC Back-UPS Pro 280 | APC Smart-UPS 420 | Description
Vendor | X | X | X | X | Reports the UPS vendor name as displayable string.
Model | X | X | X | X | Reports the UPS model name as displayable string.
FirmwareRev | X | X | X | X | Reports the UPS firmware revision as a displayable string. Empty string if not available.
SerialNumber | X | None | X | X | Reports the UPS serial number as a displayable string. Empty string if not available.
BatteryLifePercent | X | None | X | X | The percent of battery capacity remaining in the UPS, represented as a value in the range of 0 through 100. Zero if not available.
BatteryLifeTime | X | None | X | X | The amount of remaining UPS run time, in minutes. Zero if not available.
eBatteryStatus
  • BatteryUnknownStatus if no battery found. Only with UPS software version >=2.0.0.6 and UPS firmware >= 25.1.I
  • BatteryOk
  • BatteryUnknownStatus if no battery found.
  • BatteryOk

 X X The current status of the UPS batteries.
eCommStatus | X | X | X | X | The status of the communication path to the UPS.
ePowerStatus | X | X | X | X | Reports the status of utility-supplied power into the UPS.
nPowerFailCnt | X | X | *X | *X | Power fail counter. Increments every time the UPS service detects power fail.
dwChargeFlags
  • No battery (bit 7 set) only with UPS software version >=2.0.0.6 and UPS firmware >= 25.1.I The battery existence is checked every minute.
  • UPS fan error (bit 8 set) only with UPS software version >=2.0.0.7 and UPS firmware >=40.1.I The fan status is checked every minute. New (second) UPS hardware revision required!
  • Battery replace service intervall has expired (bit 10 is set). Implemented in UPS Software version >= 3.0.0.8;
  • High (bit 0 set) if battery full loaded.
  • Charging (bit 3 set)
  • No battery (bit 7 set) if no battery found.
 None None Battery charge status flags.

*) Only available if model "Smart Signaling to any APC UPS & TwinCAT" configured!

Development environment Target system type UPS hardware PLC libraries to include
TwinCAT v2.8.0, Build > 745

TwinCAT v2.9.0, Build > 945

 PC (i386)

  • Beckhoff P24Vxxxx USV;
  • Integrated Beckhoff Industrial PC 24V UPS connected to CP903x ISA or PCI card;
  • With Beckhoff Industrial PC's delivered APC UPS models supporting smart protocol and configured with Windows UPS Service;
 TcIoFunctions.Lib

( Standard.Lib; TcBase.Lib; TcSystem.Lib; TcUtilities.Lib are included automatically )


E_BatteryStatus

TwinCAT PLC Library: IO Functions

TYPE E_BatteryStatus

TYPE E_BatteryStatus :
(
    BatteryUnknownStatus, 	(*The battery status is unknown.*)
    BatteryOk, 		(*The batteries are OK.*)
    BatteryReplace 		(*The batteries need to be replaced.*)
);
END_TYPE
Development environment Target system type UPS hardware PLC libraries to include
TwinCAT v2.8.0, Build > 745

TwinCAT v2.9.0, Build > 945

 PC (i386)

  • Beckhoff P24Vxxxx USV;
  • Integrated Beckhoff Industrial PC 24V UPS connected to CP903x ISA or PCI card;
  • With Beckhoff Industrial PC's delivered APC UPS models supporting smart protocol and configured with Windows UPS Service.
 TcIoFunctions.Lib

( Standard.Lib; TcBase.Lib; TcSystem.Lib; TcUtilities.Lib are included automatically )


E_UpsCommStatus

TwinCAT PLC Library: IO Functions

TYPE E_UpsCommStatus

TYPE E_UpsCommStatus :
(
    UpsCommUnknownStatus,	(* The communication path to the UPS is unknown. *)
    UpsCommOk, 		(* The communication path to the UPS is OK. *)
    UpsCommFailed 		(* The communication path to the UPS has failed. *)
);
END_TYPE
Development environment Target system type UPS hardware PLC libraries to include
TwinCAT v2.8.0, Build > 745

TwinCAT v2.9.0, Build > 945

 PC (i386)

  • Beckhoff P24Vxxxx USV;
  • Integrated Beckhoff Industrial PC 24V UPS connected to CP903x ISA or PCI card;
  • With Beckhoff Industrial PC's delivered APC UPS models supporting smart protocol and configured with Windows UPS Service.
 TcIoFunctions.Lib

( Standard.Lib; TcBase.Lib; TcSystem.Lib; TcUtilities.Lib are included automatically )


E_UpsPowerStatus

TwinCAT PLC Library: IO Functions

TYPE E_UpsPowerStatus

TYPE E_UpsPowerStatus :
(
    PowerUnknownStatus, 	(* The status of power is unknown. *)
    PowerOnLine, 		(* Power is OK. *)
    PowerOnBattery 		(* A power failure has occurred. *)
);
END_TYPE
Development environment Target system type UPS hardware PLC libraries to include
TwinCAT v2.8.0, Build > 745

TwinCAT v2.9.0, Build > 945

 PC (i386)

  • Beckhoff P24Vxxxx USV;
  • Integrated Beckhoff Industrial PC 24V UPS connected to CP903x ISA or PCI card;
  • With Beckhoff Industrial PC's delivered APC UPS models supporting smart protocol and configured with Windows UPS Service;
 TcIoFunctions.Lib

( Standard.Lib; TcBase.Lib; TcSystem.Lib; TcUtilities.Lib are included automatically )


.topic 1000
Displays about dialog.
.topic 1001
Displays detailed UPS information.
.topic 1002
Displays options for UPS device configuration.
.topic 1003
Displays options for showing how the system is set
to respond during critical power events.
.topic 1004
Displays dialog with options to select vendor, model and communication port.
.topic 1005
Displays online help.
.topic 1007
Closes the dialog box and saves any changes you have made.
.topic 1008
Closes the dialog box without saving any changes you habe made.
.topic 1009
Displays languages of the country supported by the UPS software.
"User default" - Recommended for operating systems with installed Multilingual User Interface pack (MUI).
.topic 1011
Displays advanced shutdown or session end options.
.topic 1010
Restores the default settings.
.topic 1101
Causes the UPS to turn off its power outlets to conserve remaining
battery capacity after performing critical alarm tasks.
.topic 1102
Sets the time the UPS runs on byttery before initiating a critical alarm.
Select the number of minutes that the UPS will provide battery power
after utility power fails. If battery power is almost exhaused, the critical
alarm begins even if the time has not expired.
.topic 1103
UPS turn off delay time.
.topic 1104
Enables the UPS service to display notification messages when a critical action is imminent,
utility power fails or is restored.
.topic 1105
Sets the time that the UPS service will wait before displaying the first warning that utility power failed.
Select the number of seconds that the UPS service will wait after the power failure before displaying the warning.
.topic 1106
Sets the interval between power failure warnings. Select the number of seconds the UPS service will wait each time
it displays a power failure warning before it displays the warning again.
.topic 1107
Sets the specified task scheduler task to run before the UPS service initiates a operating system shutdown.
.topic 1108
Shows list box with all found task scheduler tasks.
.topic 1109
Displays options that you can configure for a selected task scheduler task
that will run before a system shutdown action occurs.
.topic 1110
Creates new task scheduler task with default name
This command is only available under XP and only if the default task is not allready in the list.
.topic 1111
Starts the selected task scheduler task for test purposes.
The task will be stopped automatically after max. runtime of 30 seconds.
.topic 1112
Enables forced usage of XP task scheduler v1.0 interface on Windows Vista or 7 operating system.
.topic 1203
Displays dialog for UPS fimware update.
.topic 1204
Performs self test and views the results:
"OK" - good battery
"BT" - failed due to insufficient capacity or no battery found
"NG" - failed due to overload
"NO" - no results available
.topic 1205
Updates the last battery change date and resets the service interval remainder message.
.topic 1206
Battery type/load characteristic. Allowed values: 0..99;
.topic 1207
Allowed values: 0..99900 mAh, (100 mAh steps/resolution);
.topic 1208
Allowed values: 0..999 mOhm;
.topic 1214
Beckhoff battery pack model type.
.topic 1209
Months before first battery replace service interval warning message. Allowed values: 0..480 months.
Default: 60 months = 5 years and checkbox not selected (disabled).
The message (warning) will be written to the Windows Eventlog.
.topic 1210
Shows the actual set battery replace/service date (latest service).
.topic 1211
Shows the estimated next battery replace/service date (next service).
.topic 1212
Shows the new/current service interval update date.
.topic 1213
Shows the current version of the UPS firmware.
.topic 1301
Displays a list of UPS manufacturers. Select the manufacturer of your UPS.
If no UPS is installed select (None).
.topic 1302
Displays UPS models of the selected manufacturer. Select your UPS model.
.topic 1303
Displays a list of available COM ports. Select the COM port to which your UPS is connected.
.topic 1304
CP903x ISA or PCI card adress.
.topic 1305
Search CP903x ISA and PCI card adresses.
.topic 1401
If the PC is powered down on battery, then the UPS switches off their outputs (and the PC).
If there is still externel voltage, then the UPS switches on again their outputs (and the PC is rebooting). Default: Selected
.topic 1402
This option can be used on systems without Soft-Power-Off feature (e.g. NT4.0 ).
The UPS protection will be disabled after a delay time has expired. This allows to switch off the UPS outputs (and of the PC).
.topic 1403
UPS protection off delay time.


System behaviour

The system behaviour of a Beckhoff Industrial PC with the Beckhoff UPS software and hardware components for the W2K/XP/XPe UPS service.