Index addressing through S:24

merzee

Member
Join Date
Sep 2003
Posts
1
Hi everybody,
I have been using AB SLC 500 for some time but have come across index addressing quite recently. On one of our programs it is being used, first on one rung it is to clear S:24 and thereafter on other rungs as LEQ, LES, ADD. When I connected online i found that this S;24 was changing to random values and i am not able to understand the reason to this. Moreover does this S;24 have some internal timing whereby it keeps incrementing or does it follow rungs. AB's documentation are not very clear, so could someone help me out here.
Marzi
 
You may specify an address as being indexed by placing the "#" character in front of the address. When an address of this form is encountered in the program, the processor takes the element number of the address and adds to it the value contained in the Index Register S:24, then uses the result as the actual address. For example:
#N7:l0 where S:24= 15, The actual address used by the instruction is N7:25.
 
From what I can remember S:24 is also used internally for the file instructions. This is why you are probably seeing it change values. If you use it make sure you set it to the value you require in the rung before the use of the index. Regards Alan Case
 
The help file on RS Logix 500 says ...


Indexed addressing is valid with SLC 5/02, 5/03, 5/04, and 5/05 or with the MicroLogix 1000 processors only.

An indexed address is one which is offset from its indicated address in the data table. Indexing of addresses applies to word addresses in bit and integer data files and also to the preset and accumulator words of timers and counters, and to the length and position words of control elements.

The offset value is contained in word 24 of the status file (S:24). The number in S:24 can be positive or negative.

The indexed address symbol is #. When programming, place it immediately before the file type identifier in the word address. For example #N7:2 is an indexed address.

Warning! The # symbol is also required for addresses in file instructions which also make use of word S:24 to store an offset value. If you are using file instructions in your program as well as indexed addressing, make sure that you load the correct offset value in S:24 prior to using an indexed address that follows a file instruction. Otherwise, unpredictable operation could occur, resulting in possible personal injury and/or damage to equipment.

Data tables are not expanded automatically to accommodate indexed addresses.

When you create the indexed address, follow these guidelines:

Make sure the index value (positive or negative) does not cause the indexed address to exceed the file type boundary.
When an instruction uses more than two indexed addresses, the processor used the same index value for each indexed address.
Set the index word to the offset value you want immediately before enabling an instruction that uses an indexed address.

____________________________________________________

Attached ladder is one example of its use.

l1.jpg
 
If you have an extra micrologix 1000 laying around I would
sugguest building the SAMPLE program included with RSLogix
500. It can teach you bunches.
 

Similar Topics

I need help with some index addressing. I am working on converting a program from a RS 500 PLC to a Logix 5000 PLC. I dont know how to make that...
Replies
23
Views
4,905
I am an amatuer but used to be professional real time embedded guy. PLC and micro works differently i see. I finally need to use indexing as a way...
Replies
1
Views
1,663
Any one out there in "Automation Land" using JMobile Studio from http://www.jmobile.net/ ?? We are using this and trying to do index adressing...
Replies
0
Views
2,108
I was wondering if intouch is capable of index addressing? I have a 104 graphics that all need a different tooltip status depending on the PLC tag...
Replies
1
Views
1,642
I've got a rung that uses the first pass bit to initiate a For argument. In the Routine named 'Alarm' I have something like this...
Replies
15
Views
10,236
Back
Top Bottom