Sample program 2 - short-circuit detection (voltage-controlled)

Sample program 2 - short-circuit detection (voltage-controlled) 1: Download

Program description and function

This sample program has the same function as sample program 1. Here, too, a short-circuit is to be detected with the help of the LED output of the EL2596.

However, this sample program 2 uses the “Voltage Control” operation mode, so that a specified voltage is output at the LED output.

For this purpose, as described in the chapter Commissioning, the values for the supply and output voltage, as well as the maximum output current must also be specified in the CoE data.

Sample program 2 - short-circuit detection (voltage-controlled) 2:
Setting current and voltage values in the CoE

The specified output values are then output at the output of the LED terminal. “Voltage Control” mode must be selected as the output mode (CoE index 0x8004:01).

Sample program 2 - short-circuit detection (voltage-controlled) 3:
Selecting the “Voltage Control” operation mode

“Standard digital output (with info data)” is used as the predefined PDO.

Sample program 2 - short-circuit detection (voltage-controlled) 4:
Selection of the Predefined PDOs “Current Control (with info data)”

In the sample program, diagnostic data are read from the diagnostic messages of the terminal. To do this, the NetID of the EtherCAT network and the ID of the EL2596 must be specified in the global variable list (GVL).

Sample program 2 - short-circuit detection (voltage-controlled) 5:
Sample program 1 - GVL

The NetID can be displayed in TwinCAT under the EtherCAT Master on the “EtherCAT” tab. The ID must be specified in the GVL as sNetID in inverted commas as a string.

Sample program 2 - short-circuit detection (voltage-controlled) 6:
Displaying the NetID

The ID of the slave can also be found in the EtherCAT master. The “Online” tab must be selected in order to do this. This value must then be specified as nSlaveAddr.

Sample program 2 - short-circuit detection (voltage-controlled) 7:
Displaying the slave address

The sample program can then be started. To use the sample program, the included visualization should be opened.

Sample program 2 - short-circuit detection (voltage-controlled) 8:
Sample program 2 - Visualization
Sample program 2 - short-circuit detection (voltage-controlled) 9:

Limiting the peak current in case of short-circuit

If a short-circuit occurs at the LED output, currents >6 A can flow for a short time. In order to limit the peak output current, a resistor in the low ohm range can be connected in series with the component on which a short-circuit is to be detected.