Sign in to follow this  
Followers 0
hipoint2

Control Logix Indirect Address'

7 posts in this topic

Does anybody know if you can use an expression for a indirect address'. For example ADD(Test[whocares-1],1,test2);

Share this post


Link to post
Share on other sites
Yes except the whocares-1. The "-" is an invalid charactor Misunderstood the question. No I'm pretty sure you can't

Share this post


Link to post
Share on other sites
As long as Test is an array and Whocares is a DINT tag, you can do that. I first assumed that was Whocares minus 1, which is a valid expression, but not embedded in a ladder ADD instruction. You can embed that in a CPT instruction however or in ST. CPT Test2 "Test[Whocares - 1] + 1" Edited by Alaric

Share this post


Link to post
Share on other sites
Actually Alaric it looks like it is a valid expression. I just tried it and it worked. Only one catch. If whocares is 0 then it points to -1 and faults the processor.

Share this post


Link to post
Share on other sites
That would explain why I couldn't find the darn thing in the tag database. The new things that you learn about these Logix controllers. Thanks again.

Share this post


Link to post
Share on other sites
Well I'll be dipped. I learned something too. I would have thought it was valid only in a CPT instruction. I'll have to give this a try myself. I've got a CompactLogix at my desk I can try it on.

Share this post


Link to post
Share on other sites
Ok I've played with it and can't find any snags in it besides watching not to point outside the data boundary. Hipoint, I wold still use caution in using this method It does not work with the Micrologix 1100 so I'm guessing that it doesn't work with any RsLogix 500 products

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0