Description of the Function
The PWS_DIAG function block is used to read the
status of redundant power
supplies in a Modicon M580 PAC main rack with an Ethernet backplane (local or remote rack, other
connected Modicon M580 PAC).
The power supply status is interpreted with the PWS_DIAG_DDT or DDT type.
The additional parameters EN and ENO may also be configured.
FBD Representation
Representation:

LD Representation
Representation:

IL Representation
Representation:
CAL PWS_DIAG_Instance (ENABLE:=Enable, ABORT:=Abort, IP_ADDRESS:=IP_Address,
DONE=>OperationSuccessful, ACTIVE=>OperationActiv, ERROR=>FaultyOperation,
STATUS=>ErrorCode, LEFT_PWS=>LeftPwsDiagnostics, RIGHT_PWS=>RightPwsDiagnostics)
ST Representation
Representation:
PWS_DIAG_Instance (ENABLE:=Enable, ABORT:=Abort, IP_ADDRESS:=IP_Address,
DONE=>OperationSuccessful, ACTIVE=>OperationActiv, ERROR=>FaultyOperation,
STATUS=>ErrorCode, LEFT_PWS=>LeftPwsDiagnostics, RIGHT_PWS=>RightPwsDiagnostics);
Description of Parameters
The following table describes the input parameters:
Parameter |
Type |
Comment |
|---|---|---|
|
|
Set to 1 to diagnose the status of a power supply. |
|
|
Set to 1 to abort the current operation. |
|
|
The
|
The following table describes the output parameters:
Parameter |
Type |
Comment |
|---|---|---|
|
|
Operation completed indication. Set to 1 when the execution of the operation is completed successfully. |
|
|
Operation in progress indication. Set to 1 when the execution of the operation is in progress. |
|
|
Set to 1 if an error is detected by the function block. |
|
|
Code providing the detected error identification. |
|
or
|
Diagnostic data for the power supply located on the left side of the rack (CPS1 marking on the rack). |
|
or
|
Diagnostic data for the power supply located on the right side of the rack (CPS2 marking on the rack). |
Terminology Used in PWS_DIAG_DDT or PWS_DIAG_DDT_V2 Type and Power Supply Concerned
Redundant power supplies representation in a rack:

CPS1: Left-most power supply marking on the rack.
CPS2: Right-most power supply marking on the rack.
Description of the power supply concerned by the State field bits of the function block output
parameters:
Parameter |
|
Bits of the |
Concerned Power Supply |
|---|---|---|---|
|
|
Bits 0...4 ( |
CPS1 (left-most power supply) |
Bits 5...7 ( |
CPS2 (right-most power supply) |
||
|
|
Bits 0...4 ( |
CPS2 (right-most power supply) |
Bits 5...7 ( |
CPS1 (left-most power supply) |
Pws••• field or bit) is the one that
currently provides the diagnostic data that appear in the structure.
The other power supply (OtherPws••• bit) is the second power supply located on the same backplane that
communicates some of its diagnostic data to the power supply currently
diagnosed.Description of PWS_DIAG_DDT and PWS_DIAG_DDT_V2 Type
Detailed description of PWS_DIAG_DDT and PWS_DIAG_DDT_V2 structures:
Field |
Size |
Value |
|---|---|---|
|
1 |
Power supply major firmware version. |
|
1 |
Power supply minor firmware version. |
|
1 |
Model identifier. |
|
Bit 0 |
|
Operating mode of the power supply:
|
||
|
Bit 1 |
|
Status of the power supply:
|
||
|
Bit 2 |
|
Role of the power supply:
|
||
|
Bit 3 |
|
Position of the power supply:
|
||
|
Bit 4 |
|
Major status of the power supply:
|
||
|
Bit 5 |
|
Major status of the other power supply:
|
||
|
Bit 6 |
|
Communication of the diagnosed power supply with the other power supply:
|
||
|
Bit 7 |
|
Status of the other power supply:
|
||
|
1 |
Current drawn on the 3.3 Vdc power supply internally and delivered to the rack as a producer (unit: mA, accuracy: +/-5%, value range: 20...4500 mA). The master delivers current to the rack, the slave does not deliver current to the rack. |
|
1 |
Voltage measured on the 3.3 Vdc power supply output (unit: mV, accuracy: +/-2%, value range: 3238...3471 mV). NOTE: On a master
power supply, the voltage on the output corresponds to the rack voltage.
On a slave, the voltage on the output represents the voltage that
can be applied to the rack if it becomes a master.
|
|
1 |
Current drawn on the 24 Vdc power supply internally and delivered to the rack as a producer (unit: mA, accuracy: +/-5%, value range: 36...1750 mA). The master delivers current to the rack, the slave does not deliver current to the rack. |
|
1 |
Voltage measured on the 24 Vdc power supply output (unit: mV, accuracy: +/-2%, value range: 23512...24593 mV). NOTE: On a master
power supply, the voltage on the output corresponds to the rack voltage.
On a slave, the voltage on the output represents the voltage that
can be applied to the rack if it becomes a master.
|
|
1 |
Internal power supply temperature measured (unit: °C, accuracy: +/-1%). |
|
1 |
Operating time as master since last power on (unit: s). |
|
1 |
Operating time as slave since last power on (unit: s). |
|
1 |
Operating time as master since manufacturing (unit: s). |
|
1 |
Operating time as slave since manufacturing (unit: s). |
|
1 |
Energy delivered by the power supply since manufacturing (unit: mWh). |
|
1 |
Estimated remaining life time in percent. The estimated remaining life time value represents the wear of some components in the power supply. This value is a theoretical estimation based on an algorithm that integrates several parameters such as working temperature, up-time, power consumption, and so on. When this value reaches 0% the power supply may still be working perfectly, but there is a high likelihood that a hardware defect occurs soon. NOTE: When the estimated remaining life time reaches
0, there is no automatic swap (the power supply is used as long as
it delivers the requested current and voltages).
|
|
1 |
Estimated remaining life time in months. NOTE: Only available in the
PWS_DIAG_DDT_V2 structure, RemainingLTMO refers to the same value as RemainingLTPC but converted in months (see
above). |
|
1 |
Number of power-on since manufacturing or since last clear command with PWS_CMD. |
|
1 |
Number of under voltage detected below low threshold (94 Vac +/-5%) on primary voltage since manufacturing or since last clear command with PWS_CMD. |
|
1 |
Number of under voltage detected below high threshold (194 Vac +/-5%) on primary voltage since manufacturing or since last clear command with PWS_CMD. |

