Configuring the Module DC541-CM for Use as Counting Device

  1. For use as a counting device, the device and the channels have to be configured in the PLC configuration accordingly.

  2. How to add the device in the PLC configuration is described in the chapter before (see Configuring the module DC541 Configuring the Module DC541-CM).

  3. The next step is to set the operating mode of the device. To do so, position the cursor on the entry of the device DC541-CM, right click to open the context menu and then select the function Append Subelement:

  4. Then, select “Counter mode” to configure the device as a counting device.

    In the module parameters, the channels C0…C7 can be configured as:
      Input - Input
      Output - Output
      32 bit counter - 32 bit up/down counter (uses channels C0…C3)
      Limit channel 0 - Limiter for 32 bit counter
      Forward counter - 32 bit forward counter
      PWM - Pulse width modulation
      Frequency measurement - Time and frequency measurement
      Frequency output - Frequency output
../_images/950d5786e38b57870a33139000eba54e

To do so, select the corresponding value for each channel.

Note

Note: If channel C0 is configured as “32 bit counter”, the channels C1..C3 are automatically used, too. In the PLC configuration, these channels are left at the default setting “Input”.

The specified configuration can be read using the Function Block DC541_GET_CFG DC541_GET_CFG.