PLC 5 Programming

ben

Member
Join Date
Jun 2002
Posts
37
Ok we bought the PLC5 programming software we get on line to our PLC5 we edit and enter a simple rung and a counter. Simple yea? Erm no! Why when I verify do I get an error? Do I need to verify the program offline and download when the plant is stopped? Not very practial, what am I doing wrong? I assume my CPU is a high enough level, it lets me do the edits on line in the first place. Its not like the RS Logix 500 is it!
Time to read the textbooks I think! Can anyone suggest some good reading url's?

Thanks

Ben
 
No, you should have no problem with online editing. You more than likely have a syntax error in your logic somewhere. The Error window should tell you where the problem is.
 
what does the crystal ball say?

when the error pops up, the next thing you should do is click the word "ERROR" right on the popup screen - the software's cursor will jump and take you as close as possible to the "scene of the crime" - my GUESS is that you've used an invalid address (or improper syntax) for your timer (example: T4:0 is valid - T4/0 is NOT) - a good place to start looking is in the online help files - at the very top of the RSLogix screen, click Help - PLC-5 Instruction Help and then the TON selection - this will usually give some valid addressing and setup examples - if this doesn't work, then give us a specific example of what you're trying to enter - this should be a simple thing - please tell us what the error message is -

incidentally, thanks for letting us know how the furnace PID turned out - glad you got it working -
 
Not there yet

Erm, I didn't note the error down, I was waiting for that Q.

I just dragged a rung and then a counter off the task bar put an existing XIC in the rung and called the counter for example COUNTER_1.

I got an error when I verified?

I will make a note of the error tomorrow.....still reading for the time being....

Ben
 
You need to give the symbol "Counter_1" a valid data table address. e.g. C5:0

Simplest to simply use the C5 address and add the symbol later. Otherwise, edit the symbol name for the address you want to use before you try to program it.

Also note that you can't create or expand data table files on-line.
 
online/offline vs. run/program

Ben,

Obviously you have confused the PLC-5 platform with the newer ControlLogix platform. With the PLC-5 processors you MUST use a valid address (I repeat: ADDRESS) for your counters, etc. This is what Gerry was getting at. In ControlLogix you are allowed to just “make up” a tagname for the counter - but that won’t work with the PLC-5. Specifically, a PLC-5 counter will have an address such as “C5:0”. Now you ARE ALLOWED to give the counter’s address a “nickname” (something like COUNTER_1 would be acceptable) - and this “nickname” might LOOK LIKE a ControlLogix tagname - but in the PLC-5 system, the “nickname” MUST be tied to a valid existing address. The “nicknames” I’m referring to are called “SYMBOLS” in the PLC-5 family - which is what Gerry was referring to in his post.

Going just a little further - you CAN make online changes to the PLC-5 processor (as Vetteboy correctly pointed out) but even so there are some things that you can NOT do while the processor is actually RUNNING its program. For example: You cannot resize a data table file. Specific example: If your processor’s memory does NOT already have a C5:1 counter location assigned - then you cannot add that counter WHILE THE PROCESSOR IS RUNNING the program. For example: You would NOT be allowed to “accept” a new rung with the non-existent counter on it - since that operation would require resizing the counter data table file - to “make room for” the new counter. On the other hand, if you were to put the processor into the PROGRAM mode, then you WOULD be able to accept the new counter’s rung (assuming that the addressing syntax is correct). Of course putting the processor into the PROGRAM mode shuts down the plant and makes the boss very unhappy.

I’m bring these items up because you said you were going to be “reading up” and the RSLogix5 book has some errors in it. Take a look at:

Getting Results with RSLogix 5 Manual

On Adobe page 66 of 115 - or book page 56 - we find the following:

Online editing restrictions

During an online editing session you cannot:
resize data table files
create or delete program files
change program file protection

The first two restrictions are in error. With the PLC-5 processors, you CAN resize the data table files while ONLINE - and you CAN create or delete program files while ONLINE - but you CANNOT do these operations while the processor is actually RUNNING the program. You can change the program file protection (the third item) at any time.

Common source of confusion: The terms “ONLINE” and “RUNNING”.

The term “ONLINE” indicates that your programming computer is COMMUNICATING with the processor. Specifically, the term “ONLINE” has absolutely NOTHING to do with whether the processor is RUNNING the program or not.

The term “RUNNING” means that the processor is scanning the program rungs and trying to control its outputs. Now the processor might be ONLINE (communicating with your programming terminal while it’s RUNNING) - or it might be OFFLINE (not communicating with your programming terminal while it’s RUNNING). Secret handshake: The “online/offline/communicating” issue has ABSOLUTELY NOTHING WHATEVER to do with the “running/scanning/controlling” issue. Night and day. East and West. Completely separate issues.

Got that? Then don’t let what comes next confuse you. I'm including the following just for our many SLC users. Since you're using the larger PLC-5 family, the next part doesn't apply to you.

BUT - with the SLC family of processors, the restrictions listed above ARE CORRECT. With that particular (smaller) platform, in order to resize the data table files; create or delete the program files; or change the program file protection - you MUST go “OFFLINE” (specifically, you must STOP communicating with the processor) and make the necessary changes. Once the changes have been made, they must then be downloaded to the processor in order to take effect.

One more step and we’re finished. With the SLC-5/03, SLC-5/04, and SLC-5/05 processors, - (but NOT with the smaller SLC-500, SLC-5/01, and SLC-5/02 models) - you CAN make ONLINE changes to the program rungs - and the processor can actually be RUNNING its program too. Specifically, you can add and change the program rungs while the processor is RUNNING. More specifically, you do NOT have to shut down the plant just to change the rungs. It might help to think of a rung edit as a “minor” change. BUT - (with any SLC processor) - you still can NOT:

(1) resize data table files,
(2) create or delete program files, or
(3) change program file protection

while you are ONLINE (think: "communicating") with the processor.

Think of these as “major” changes to the processor’s memory structure. You’ve got to jump through some additional hoops to get these done.

Please post again if you have any other questions. I’m out of time for today.

Incidentally, the RSLogix software was originally written (as RSLogix500) for the SLC-500 family of processors. Later it was adapted (as RSLogix5) for the PLC-5 family. I have a hunch that the “book” errors I’ve listed above crept in while the documentation was being “cut and pasted” - and no one caught the differences between the platforms. And yes, I’ve reported these errors before.
 
Last edited:
Chances are Ron nailed it down for you.

I feel after you size your data table to cover the addresses you will be using and assign proper addresses your error sill vanish.
The PLC-5 family must have the proper structure to the addressing, I=Input or O=Output, Rack number, Module group, Slot number, Bit number, such as I0001/10.
Some people combine the slot number and bit numbers to read "Bit-10" but in reality it is "Slot-1" "Bit-0". each module group fills two slots, Slot-0 and Slot-1.
It is not as complicated as it seems, just read up and all will become clear.

Roger
 
I've run across the data table size problem before, what I try to do is always leave a little room in each data table for future expansion for 'ON LINE" or "WHILE RUNNING" edits. Otherwise you will have to shut everything down just to add a timer, or possibly even a bit address for a contact. Given that it's not a little processor with a big program..
 
PLC-5 addressing modes

Quote from rogerhollingsworth:

each module group fills two slots, Slot-0 and Slot-1.
It is not as complicated as it seems, just read up and all will become clear.

Obviously Roger has a lot more going for him than I did when I tried to learn PLC-5 addressing. But then I freely admit that I’m not the brightest bulb on the tree. Anyway, I read - and I read - and I read - and then finally I gave up on the books. In desperation, I set up a real chassis in the lab and experimented with different setups until I understood.

Big ideas: The PLC-5 supports two-slot; and one-slot; and half-slot addressing modes. These modes are determined by setting DIP switches on the chassis backplane. Before we start counting the modules, we need to know exactly which addressing mode our particular chassis is using. If the processor is actually located in the chassis (in other words: we’re dealing with a local chassis rather than a remote chassis) then we can easily find the addressing mode by going to the Processor Status table and looking on the Switches tab. Big hint: While you’re there, press the “Help” button at the bottom of the window - then keep following the links for more info about addressing. Secret handshake: When it says “I/O Pair” it means an Input module and an Output module.

Quick example of PLC-5 addressing: In the address I:123/17 ....

I = it’s on the Input data table
12 = the rack number
3 = the module group number
17 = the bit number

Quick definition department: A “rack” is defined as 8 words of input AND 8 words of output. Don't use the word "rack" to refer to a chassis. That is the BIGGEST source of confusion in the whole subject.

Note to Roger: To the best of my knowledge, in PLC-5 systems the “slot number” that you mentioned in your post usually comes into play only when we’re dealing with Block Transfer Reads and Writes. I’ve never seen it included right there in the address the way you showed it - is this just a typographical error - or a new trick for this old dog to learn?

I’m going to be tied up for the rest of the week. If anyone wants to continue with this “PLC-5 addressing scheme” topic - please feel free to take the ball and run with it. I just did a search for “slot and addressing” and didn’t find anything on the subject. Then again - everybody might already have this one nailed. I’m usually the last one to figure this type of stuff out.

Final warning: Any two-slot; one-slot; or half-slot addressing information which you happen to find on the I/O Configuration screens may OR MAY NOT be correct. This is just a documentation feature (window dressing) and if no one has bothered to set it up correctly, then it may certainly be incorrect. The information on the Processor Status table is different and it should always be correct - since it actually reads the chassis DIP switches. Still - be careful - just because the LOCAL chassis happens to be set up for two-slot is NO guarantee that a REMOTE chassis is set up the same way. Each chassis in the system CAN be different.

Note to SLC users: You usually don’t have to worry about this subject at all. The SLC’s have a much simpler method of I/O addressing.

P.S. Micah’s idea of adding a few “spares” to his data tables is an EXCELLENT one. You can do that by right-clicking the data table file icon - and then click “properties” - and then increase the number of “elements”. Don’t forget if you’re working with an SLC you’ll still have to download the altered program to the processor in order for your changes to take effect.
 
Last edited:
It is used in Block Xfers etc.. but only because it is the over all addressing scheme, it just happens to be required in Block Xfers but not required to look at it that way in I/O.
It isn't a new trick it is just the structure of Allen-Bradleys addressing scheme for the enhanced family. I suppose it is a carry over from the old days when A-B didn't have high-density cards but it still has the same meaning when you break down the addressing scheme.
Sticking with low density cards, to lessen the confusion, each slot has its bits 0 thru 7, Slot-0 bits would appear as;(slot-bit) 00, 01, 02 etc.. while Slot-1 would appear as ;(slot-bit) 10, 11, 12, etc.. (not Ten, Eleven, Twelve)
That is why they use the term "Module Group" rather than "Module".

Close Ron, and usually looked at that way (nothing wrong with looking at it that way because it still works.)

Quick example of PLC-5 addressing: In the address I:123/17 ....

I = it’s on the Input data table
12 = the rack number
3 = the module group number
17 = the bit number

It gets broke down one more step;
In the address I:123/07 (module groups Left hand slot....
In the address I:123/17 (module groups Right hand slot....

I = it’s on the Input data table
12 = the rack number
3 = the module group number
1 = the slot number(right hand side)
7 = the bit number

Another term that is often misused is "Rack", Rack is not the physical hardware device that holds the PLC and modules, that is called the "Chassis". A "Rack" is an I/O count of 128.

Allen-Bradley is guilty of misuse when it comes to the terms (BIT) & (RACK) in their literature. That will truly confuse someone who is just learning.

Roger
 
Last edited:
Follow-up

Below is an excerpt from an A-B manual. As I mentioned in my earlier post, the addressing scheme came about prior to high density cards and deals with 8pt cards. I will need to retract one of my statements about it not being too confusing because it does get there.

A-B speaks of a "physical RACK" and "Logical RACK" they also speak of a "physical Slot" and a "Logical Slot" and most of the time they do not bother to distinguish which they are talking about, thus confusion. I have worked with the PLC-5 for so many years it just don't seem confusing, until I really think about it.

EXCERPT;
slot (physical)
a location in a chassis for installing a module. The number of physical slots per group determines the addressing mode, for example, 2-slot addressing is used when a group contains 2 physical slots.

slot (logical)
really applies only to 2-slot addressing. The logical slot is the slot number within the group as opposed to the physical slot number. In 2-slot addressing, each group contains two logical slots, slots 0 and 1. In all other addressing modes, the logical slot number is always zero.

:unsure:
Roger
 
slots, bits, groups, racks, chassis

AB used to describe I/O addressing using the slot-bit notation circa 1981. It worked well for the 1771 series I/O when they only had 8-point modules. I think it was probably developed as a presentation or teaching method to avoid getting bogged down in explaining octal numbering. Also, in those days, racks and chassis were the same thing. The confusion set in with the introduction of 16 and 32 point modules and the accompanying concept of logical racks. Complementary addressing added to the mix.

I'm pretty sure the decision to use octal numbering preceded the slot-bit idea. For instance, the 1774 used octal addressing through-out, but originally used 1778 I/O which had 16 point modules. The PLC-2 family was also completely octal but was introduced with 1777 I/O which used bulky 4 point modules. I don't know how the slot-bit notation would apply to those I/O types. The use of octal numbering started to diminish with the PLC-3, was reduced further in the PLC-5, and eliminated in the SLC and ControlLogix (unless communicating on RIO or DH+).

Octal numbering and addressing was popular with a lot of computer manufacturers in the 60's and 70's - was it a fad? a geek thing? or was there some engineering rationale?
 
PLC-5 addressing test

Here’s a simple example - let’s see what we come up with. This is the biggest PLC-5 chassis that Allen-Bradley makes - 16 I/O slots - plus 1 for the processor. I’ve plugged a very common type 16-point AC output module (model 1771-OAD) into the very last slot. A pump is connected to terminal number 12. Questions:

What is the address of the pump if we’re using 2-slot addressing?
What is the address of the pump if we’re using 1-slot addressing?
What is the address of the pump if we’re using 1/2-slot addressing?

[attachment]

I’ll post my answers on the practice board. Let’s see if we all come up with the same thing.

If you need any info on the module, you can find it here:

1771-OAD module installation instructions

address test.jpg
 
My compliments

I almost posted:

Answer: D - Not enough information given

because you didn't talk about complementary I/O.

If you have complementary I/O turned on, that 16-slot chassis becomes a 8-slot (logical) rack (assuming single-slot addressing), with slots alternating between 16-point input and 16-point output slots.

If you use analog modules (ones that require block transfers to talk to the modules), then you have to use the module variable (0 for the first slot of the complement, 1 for the second slot) to let the PLC know which card you are communicaing with.

As I said, I almost posted it.

But a quick check of my facts tells me that the chassis with the PLC in it (which is what you have), can't use complementary addressing, so I won't bother to muddy the waters further. (Good thing you didn't make that a remote I/O rack).
 
Last edited:
my answer

Ron,

My answer are:

Address for 2 slot addressing: 007/12

Address for 1 slot addressing: 017/12

Address for 1/2 slot addressing: 037/12

Is my answer correct?

Thanks,

Deer
 

Similar Topics

Hello colleagues, Some time ago I started my adventure with programming. With your help and the courses, things are starting to come together...
Replies
13
Views
678
Dear All, I need a sample PLC program to count the output pulse of a mass flow meter so that a specific amount of mass (for example 100gm)can be...
Replies
2
Views
146
Hi Please I have zeilo smart relay #SR2A201BD but I don't have it's programming cable. Can I use any general usb/rs232 converter? Or need...
Replies
3
Views
150
Hi, Does anyone have thoughts or know of, can point in the right direction any published materials with a plumbing centric point of you explaining...
Replies
1
Views
164
@ All: what is your best guess on a potential range in increase in efficiency in % (i.e. saved programming hours, greater output, etc.) when...
Replies
5
Views
349
Back
Top Bottom