C01 & c04 example.rss (cont’d) – Electro Cam PL-1746 Series User Manual

Page 127

Advertising
background image

8-14 Utility & Example Ladder Programs

C01 & C04 Example.rss (cont’d)

Pulse Edit (cont’d)
Once the steps above have been completed, the pulses ‘ON’ value can be read from N7:2, and the ‘OFF’ value can be
read from N7:3. After the first pulse has been read back, we can read the value located in N10:7, which will tell us how
many pulses are in that channel. If there are multiple pulses in that channel, you can enter the pulse number you would
like to read into N7:4, then enter a ‘1’ in B3/0. That pulses ON and OFF values can be read from N7:2 and N7:3,
respectively.

Write to a word/integer/bit
Note: Do not overlap pulses in one channel. If you overlap pulses in one channel, an internal error will be generated in the
Module Status Register. If an error is generated, enter a ‘1’ in O:1/8 ‘Clear Error Bit’.

To enter a pulses’ on/off values from the CDM, do the following:
1. Enter the program in which we would like to write the pulse to in N7:0
2. Enter the channel which we would like the pulse to be written to in N7:1.
3. Enter the pulse’s ‘ON’ value in N7:2.
4. Enter the pulse’s ‘OFF’ value in N7:3.
5. Enter ‘3’ in N7:6
6. Enter ‘1’ in B3/0.

Once the above steps have been completed, we can read the pulses’ on/off value as explained in example 1.

Increment On
To increment the on edge of a pulse from the CDM, we do the following:
1. Enter the program in N7:0
2. Enter the channel number in N7:1.
3. Enter the pulse number which you would like to increment in N7:4.
4. Enter ‘5’ in N7:6.
5. Enter ‘1’ in B3/0.

Notice that each time you ‘toggle’ B3/0 to one, you increment the ON edge of that pulse by one increment.

Decrement On
To decrement the ON edge of a pulse from the CDM we do the following:

1. Enter the program in N7:0.
2. Enter the Channel in N7:1.
3. Enter the pulse number in N7:4 if there are multiple pulses in the channel.
4. Enter ‘7’ in N7:6.
5. Enter ‘1’ in B3/0.

Notice that each time you ‘toggle’ B3/0, the pulses on edge is decremented by 1.

The remaining pulse edit functions available are Increment OFF edge, Decrement OFF edge, Increment both the ON
and OFF edge, and Decrement both the ON and OFF edge. These functions are all performed in the same fashion as
functions 3 and 4, except you change the value that is written into N7:6. The values entered for each function are as
follows:

1 = Read.
3 = Write.
5 = Increment ON Edge.
7 = Decrement ON Edge.
9 = Increment OFF Edge.
11 = Decrement OFF Edge.
13 = Increment both the ON and OFF Edge.
15 = Decrement both the ON and OFF Edge.

Advertising