ladder programming advice

L

Thread Starter

lim

<pre>
---------
----||-----|/|----------------------|countdown|
output Feedback | | timer |
bit bit | | 5 sec |
| ---------
|
|----||----------(alarm)
timer done
bit

</pre>
if after 5sec i don't get my output feedback bit=1, then alarm=1. if i have alot of these individual output, feedback and alarm bit, HOW can i reuse the above rung without creating them individually??? i am using Omron CX ladder programming.
 
J

Johan Bengtsson

Well, since you probably want the 5 second timer to be counted individually for each output I suppose - then you can't do anything except have those rungs duplicated.

I don't know about your programming tool, but that might have some macros, custom function blocks or other feature to make entering similar rungs over and over easier.



/Johan Bengtsson

Do you need education in the area of automation?
----------------------------------------
P&L, Innovation in training
Box 252, S-281 23 H{ssleholm SWEDEN
Tel: +46 451 49 460, Fax: +46 451 89 833
E-mail: [email protected]
Internet: http://www.pol.se/
----------------------------------------
 
R
If you have a sequence programmed in your logic, (do step 1; if step 1 done and OK to proceed do step 2; if step 2 done and OK to proceed then do step 33; ...)
THEN

Rung 1
if sequence is not complete, compare the sequence word (eg. CH19), with a LAST
STEP word(CH18). if they are equal for 5sec, SET a Fault_Present bit (20.00)

(LD 25313, CMP ch19 ch18,
if EQ(25506) TIM 0 #50
if TIM0 SET 20.00

Rung 2
If the Sequence does not match, (ie it DID get to the next step), then move
CurrentStep into LastStep

LD 25313, CMP ch19 ch18
if not EQ MOV ch19 ch18

Then your next rungs will have to be:
LD 20.00 AND FaultCondition1 ANDNOT Feedback1 OUT FaultAnnuciator1
etc. for all your fault inputs.

If you need a small sample of code, I use this in A-B CPU's sometimes, you could convert it to CXPro.
Ask me if you want.

Rob
RoTaTech
[email protected]
 
I think many people may be interested in seeing
your code. Could you post in the PLC Archive?

thanks,
mjv
 
Top