Question- in a SLC 500 Bit Shift / File what does the # mean in # B3:25

Cydog

Member
Join Date
Feb 2018
Location
Maryland
Posts
313
Good Afternoon,

I’m looking at some examples in a SLC 500 and I took notice of a Bit Shift that has the File position with a # B3:25 . What does the # mean ?

Thanks so much .
 
Here is what I see in RSLogix help; I think the bottom part regarding "File addressing" and highlighted in red. is what you are looking for.

zzz.png
 
Funny how the help, helped.
Bit like RTFM seems to help when you can't understand something, or worse, when you blow something up, then read the manual and go, l shouldn't have done that.
 
The description of the # indicator in SLC/PLC5 instruction addresses is an indication the the instruction is referencing a "base plus offset" address. The SLC/PLC5 processors maintained a "firmware" address offset register. This allowed you to do indexed addressing without the "indirect addressing" address definition format. The offset register (one of the S: registers) would contain a value that would be added to the base address indicated in the instruction to determine the actual address being accessed. So if and address was defined in an instruction like #N7:0 and the value in the offset register was 12 the actual address being reference would be N7:12.
Interestingly the "file" instructions used this same address offset register to perfom their functions. So a COP instruction would need to have its addresses defined using the # indicator in order to increment through the data as it copied. In many cases the instructions won't babysit the value of the offset register when they are done with it, which can lead to some interesting results.

You can use the # indicator in any address. You just have to understand what it means. A young programmer once use the # indicator in the source of a move instruction simply because he saw it used that way the first time he saw a MOV used in a program. He was completely confused when he was getting what looked like arbitrary data in the destination of the MOV. The instruction was simply using the random value that happened to be in the offset register to index into an address he didn't expect.

Keith
 

Similar Topics

Everyone, i am in the process of purchasing the Slc 500 version of software to support what we have and i have a question. Several of our...
Replies
9
Views
770
In a slc 500 plc I am trying to move data with out using a lot of moves. I want to move data from n7:1 to n7:2 and data that was in n7:2 to n7:3...
Replies
16
Views
1,358
Hi all I have a SLC 5/04 with a BAS module sending print data to a dot matrix printer. In the Basic program in this module, there are what...
Replies
4
Views
1,918
I recently had a 5/04 lose its program for what I'm atributting to a cheap battery that was installed 6 months ago so installed a EEPROM. I...
Replies
2
Views
1,221
This is my first post. I have been working in the HVACR field for ten years but am pretty new to PLC's. I work 'in-house' at a factory now as a...
Replies
4
Views
2,148
Back
Top Bottom