AB RSlogix5 CTD

Join Date
Apr 2002
Posts
1
I am trying to use a CTD to count down for 10 counts, but when the CTD is triggered the accumulated value starts counting down from 0 then goes to the negative numbers. Shouldnt this CTD start at the preset value of 10 and count down to 0?
 
CTD behavior in PLC-5

You probably have to begin with the accumulated value equal to the preset. At that point (it's a little wierd to my way of thinking) the DONE bit will be on.

Each false-to-true transition of the rung will count down by one, until you reach zero. If you roll over to negative numbers the DONE bit will come on again.

If you use a RES (Reset) instruction, the accumulated value will go to zero. Probably you'll want to instead reset the counter by MOVing a value of 10 back into the accumulator.

As I learned it, the CTD instruction wasn't really meant to be used alone, but rather in conjunction with the CTU instruction on the same Timer data element, so one would increment and one would decrement the counter's value. That's why you don't really have an opposite accumulator function with CTD; the PLC is still thinking of a "up" counter.
 
Last edited:
I almost always use the add instruction (or in your case, the subtract instruction) for all of my counting. You don't have to play games with the EN bit to disable the false to true transition requirment of the counters, plus its just plain easier.
 

Similar Topics

I could use some help figuring out the layout of a Remote I/O channel Diagnostic Files in a PLC5 using RSLogix5. I've attached a screen shot of...
Replies
14
Views
3,616
Hi all. I was wondering if anyone knew a way to renumber Ladder Numbers in RSLogix 5. I have deleted some of the old Program Files in my Project...
Replies
2
Views
1,517
Yesterday a coworker informed me of an issue with his laptop. Anytime he opens an RSlogix5 project, and tries to go online, the entire program...
Replies
1
Views
1,361
Hi Friends, 1. Please, what are the differences between RSLogix5 and RSLogix500? 2. Troubleshooting/Fault finding tools in RSLogix5? 3...
Replies
1
Views
1,113
Hi , i'm looking for copy of RSlogix5 or a laptop with that software on it. I need it to upload code ,so i can rewrite it. any help would be...
Replies
30
Views
7,797
Back
Top Bottom