Need help - confused/think i am loosing it

irondesk40

Member
Join Date
Jan 2008
Location
nc
Posts
630
Have a piece of code that was uploaded out of a machine we have in China, that has a lot of indexed addressing and I am trying to figure out a section that I am totally confused on.

If you do a search for b12:3/5 you will see where in the code b16:3/0 is used to turn on the output under certain conditions.

Could someone tell me what I am overlooking, I can not find b16:3/0, but it does get turned on when monitoring the program according to the tech over the phone.
I finally was able to get online with it through our company network, and when i monitored it, i saw it come on as well, but can not figure out how. It appears whoever wrote it has a lot of experience at index type programming.



Thanks
 
irondesk40 said:
Have a piece of code that was uploaded out of a machine we have in China, that has a lot of indexed addressing and I am trying to figure out a section that I am totally confused on.

If you do a search for b12:3/5 you will see where in the code b16:3/0 is used to turn on the output under certain conditions.

Could someone tell me what I am overlooking, I can not find b16:3/0, but it does get turned on when monitoring the program according to the tech over the phone.
I finally was able to get online with it through our company network, and when i monitored it, i saw it come on as well, but can not figure out how. It appears whoever wrote it has a lot of experience at index type programming.



Thanks

As Controlled stated, more than likely this bit is being controlled by an HMI. Do you have a copy of the HMI software, there must be one as one ladder file LAD4 is labelled OP_INTRFCE
 
no do not have the hmi software.

only thing i know at the moment, is that tech i was talking to on phone said that nobody is touching the screen or anything, but does come on.

it is a chemical tank system, example is that there are two tanks, tank a, and tank b.

Tank a fills up

Tank a gets full, then the dispense or drain valve will turn on and the contents of the tank will drain, and tank a is also piped so that when tank a turns on, it will also drain out and flow into tank b, which is set up as a reserve tank.

When normal running, whenever tank a starts to fill, the drain valve for tank b (reserve) will turn on and be used while tank a is being filled. There are a couple of other of the systems with same program that are running correctly, this system for some reason, the tank b (reserve) will not drain when the main tank a is filling sometimes.
on other machines, when monitoring, the bit will turn on and cause the tank b (reserve) to drain while tank a is filling. So at the moment, without any comments, assume that the code i mentioned is what is controlling it.
hope this makes sense
 
there are other systems in the plant with the same plc that are on the company network that i can go online with and monitor.
 
The bit is being set by the program.

Ladder 8, rung 4 - when N19:1 = 3.
Ladder 9, rung 4. - when N19:2 = 3.
Ladder 10, rung 4. - when N19:3 = 3.
Ladder 11, rung 4 - when N19:4 = 3.
Ladder 12, rung 4. - when N 19:5 = 3.

The indirect instruction is OTE B16:[POINTER]/0

When the POINTER = 3, then bit B16:3/0 will be indicated.
 
Last edited:
Alaric said:
The bit is being set by the program.

Ladder 8, rung 4 - when N19:1 = 3.
Ladder 9, rung 4. - when N19:2 = 3.
Ladder 10, rung 4. - when N19:3 = 3.
Ladder 11, rung 4 - when N19:4 = 3.
Ladder 12, rung 4. - when N 19:5 = 3.

The indirect instruction is OTE B16:[POINTER]/0

When the POINTER = 3, then bit B16:3/0 will be indicated.

WOW, a classic Got ya for search, find all, and cross reference.

This must be a Ron Beaufort class exercise. I'm sure he has posted on this the passed.
 
I first ran a search on B16:3 and looked for indirect addressing on the bit. Then I ran a search on B16 and scanned the list for indirect addressing on the word. I spotted the first one B16:[N19:1]/0 right away. Luckily, I also spotted the second one nearby and saw that it was using N19:2 as the indirect pointer. Thats when I realized that there were multiple occurneces. Apparently I missed half of them.

Although I didn't use one, you can use wildcards in searches. B16:*/0 would have found all of them.

A072308A.JPG


As you can see, I wasn't thorough enough because I missed five more instances where N20:1 through N20:5 were used as indirect address pointers as well. (but what do you expect from free help anyways? 🍺 )

I'll leave it up to the OP to finish figuring out how the indirect pointers are set and which ones are relevant.
 
Last edited:
Alaric said:
I first ran a search on B16:3 and looked for indirect addressing on the bit. Then I ran a search on B16 and scanned the list for indirect addressing on the word. I spotted the first one B16:[N19:1]/0 right away. Luckily, I also spotted the second one nearby and saw that it was using N19:2 as the indirect pointer. Thats when I realized that there were multiple occurneces. Apparently I missed half of them.

Although I didn't use one, you can use wildcards in searches. B16:*/0 would have found all of them.

A072308A.JPG


As you can see, I wasn't thorough enough because I missed five more instances where N20:1 through N20:5 were used as indirect address pointers as well. (but what do you expect from free help anyways? 🍺 )

Didn't know that, wildcard trick. Pretty nice.
 
Alaric said:
I first ran a search on B16:3 and looked for indirect addressing on the bit. Then I ran a search on B16 and scanned the list for indirect addressing on the word. I spotted the first one B16:[N19:1]/0 right away. Luckily, I also spotted the second one nearby and saw that it was using N19:2 as the indirect pointer. Thats when I realized that there were multiple occurneces. Apparently I missed half of them.

Although I didn't use one, you can use wildcards in searches. B16:*/0 would have found all of them.

A072308A.JPG


As you can see, I wasn't thorough enough because I missed five more instances where N20:1 through N20:5 were used as indirect address pointers as well. (but what do you expect from free help anyways? 🍺 )

I'll leave it up to the OP to finish figuring out how the indirect pointers are set and which ones are relevant.


Wow - thanks alot, i will be honest, i searched and searched, hav e to admit using this kind of addressing is very confusing to me.
Have a hard time understanding why you would write it this way, i know there are probably hundreds of good reasons, just seems like it makes it harder to troubleshoot later. I also know that if I understood it better, it would not seem so difficult.
again - thanks alot, and as far as leaving up to the original poster, good thing I would not have to answer that quickly, cause i would not be able to, but still trying to study as much as possible.
Thanks
 
not much I can add to this one ...

I’ve been tied up all day - and it looks like my distinguished colleagues have had all the fun ...



but just to add a little bit of insignificant fluff, here are a few comments - feel free to skip them ...



from irondesk40:



Have a piece of code ... that has a lot of indexed addressing



technically speaking this is INDIRECT addressing - and not INDEXED addressing ... “indirect” uses the [square brackets] characters to enclose a “pointer” ... “indexed” uses the #pound sign# character to indicate the use of the system’s “Index Register” (S:24) for “file” operations ... this doesn’t really change anything, but knowing the difference between the two addressing methods might help you do your research and study on the subjects ...



have to admit using this kind of addressing is very confusing to me ... if I understood it better, it would not seem so difficult.



here’s a simple trick that might help you understand the concept ... from the menu at the top of RSLogix500, select View - and then Properties - and then click the Address Display tab ... find the box for “Display Value for Indirect Address” - and then watch the way an example of an indirect address gets displayed on your screen when this box is checked or unchecked ... this is a pretty simple way of visualizing just how the processor will interpret (or decode) your indirect addresses ...



displayb.JPG





note that when “Display Value” is checked ON, you can still easily read the address of the pointer by “floating” your mouse over the address ...



from Mickey:



WOW, a classic Got ya for search, find all, and cross reference.
This must be a Ron Beaufort class exercise.



yep ... and one thing that we’d stress along the way would be the setup of the “Search” feature ...



findall.JPG




even with the “wildcard” in place, you can still miss things if the Search feature isn’t set up for a “wide open” search (all ladder files, and wrap around) ...



another thing interesting along these lines: indirect addresses do NOT show up as “used” when the “Usage” feature is applied ... simple reason: the RSLogix software has no way of “reading” the ladder logic program to predict the range of values that will be fed into the pointer ...


from Alaric:


No doubt our esteemed colleague Ron has some better tricks up his sleeve.



nope ... nothing “better” than what you’ve already demonstrated - but if you’re looking for something “different” some people prefer the “XRef” feature over the “Find All” search ... the “solution” to the problem at hand would come out looking something like this:



xref_a.JPG




personally I prefer the “Find All” feature with a "wildcard" - just the way you did it ...



party on ...
 
Last edited:
Ron

I will be honest, that has been very helpful.
I have a usb mem stick, and I constantly go on here and search for your post, and then print them out as a pdf file and save it to my usb stick for reference, has saved my butt quite a few times.

Thanks
 
here is a screen shot of section in the program where i moved the cursor after going into properties and changing it the way that was selected.
Could someone explain how when i moved the cursor over the top of the N17:1, it showed N17:[N19:1]

I just have a hard time understanding it.

Hate to keep asking, but have done mostly omron plc's, but in the last couple of years have had some ab projects, and this type of addressing is just not sinking in.

Maybe Ron could post a indirect addressing for dummys, I know I would purchase it.

Thanks
 

Similar Topics

Hi all, I'm modifying a system and came across a dint tag used in a way I've never seen before. The tag name is cvProcess yet he has a xic named...
Replies
2
Views
2,614
I'm fairly new to Rockwell software, I've had some basic training in the past but nothing too advanced. My company and I use Reliable products for...
Replies
11
Views
268
Hi all, I am having issues accessing my Cimplicity software - the site code changed after re-install and I am no longer able to attain a new key...
Replies
10
Views
158
Good day all! Can someone help me with the procedure to update Beijers E700 firmware? The Panel I am working on is firmware 2.04v and I would...
Replies
1
Views
62
Back
Top Bottom