STEP 7 and RSLogix5000

Can you provide an example? I hear this bounced around a lot but with nothing to back it up.

Step7 utilize the use of real pointers that point to memory locations instead of values as opposed to L5Ks "pointers" that just lets you choose some element in an array.

Check this out:
http://www.plcdev.com/siemens_s7_indirect_addressing

Note that I'm certainly no Siemens expert, and use Rockwell for the most part. This is just a thing that i miss.
 
Last edited:
I wish I knew the Logix5000 software as well as I know the Step7 software, then I could give a qualified answer to the original answer. I suspect that I will not be the only reader of this topic thinking that.

Like Jesper, I too see the built in web server in the Profinet processors a great innovation that I am starting to experiment with. Is there an alternative in RSLogix5000?

I've always been ammused by the automatic type conversion argument. Wht would you want to multiply an INT by a REAL? and what result should you expect, a REAL or an INT? I will, however, agree that coding this in Ladder is a complete pain but in STL it's simple: ITD, DTR.

"Multiply Red Circle by Blue Square" = Purple ??? Sorry, couldn't resist.

Nick
 
Step7 utilize the use of real pointers that point to memory locations instead of values as opposed to L5Ks "pointers" that just lets you choose some element in an array.

Check this out:
http://www.plcdev.com/siemens_s7_indirect_addressing

Note that I'm certainly no Siemens expert, and use Rockwell for the most part. This is just a thing that i miss.


I think this boils down to semantics.

Elements of an array are memory locations. The difference is that in S7 the memory locations are fixed whereas in Logix5000 they are dynamic. I can easily create an array in Logix5000 and treat it like flat memory in just the same fashion. I don't see any difference between an "array" in Logix5000 and a DB file in S7.

Or to turn it around and look at it from another perspective, isn't the base S7 memory structure just one big "array" of memory.


Most importantly, can you pose a real world example where the way that S7 handles pointers allows you to solve a problem that you otherwise would not be able to do in RSLogix5000 with the way they handle pointers? Perhaps you can post an example of this S7 code and we can try and do the same thing in RSLogix5000 as an excercise?

I am wrong here or am I missing something?
 
I've always been ammused by the automatic type conversion argument. Wht would you want to multiply an INT by a REAL?
Nick

I could probably spend a full week coming up with examples of why. For a generic answer, say I have a FOR loop type structure where I am performing a calculation based on the "INT" index of the FOR LOOP, but that is say operating on a value that is REAL such as (weights, costs, etc.)

My question is "Why wouldn't you"?



and what result should you expect, a REAL or an INT?
Nick

The answer to that is from basic SET theory. INTs are a subset of REALs. If you multiply an INT with a REAL, then you get a REAL.

I will, however, agree that coding this in Ladder is a complete pain but in STL it's simple: ITD, DTR.
Nick

For instance, the last project I was on was talking to Lenze drives over Profibus. All the Lenze data was in INT format, however many values were such that the values were resolved (ie 0 to 3000 rpm = 0 to 2^14 counts).

Therefore for every single value on every single drive I had to first convert the INT to a DINT, then from a DINT to a REAL. And I could do my math on that value to scale it to real world units.

ITD, DTR may be simple/easy, but it is still completely and unecessarily a complete waste of my time and realestate on the screen for code that shouldn't need to exist.

And why on earth does S7 not have a INT to REAL instruction???


"Multiply Red Circle by Blue Square" = Purple ??? Sorry, couldn't resist.

Nick

Multiply Number by a Number = Number?!?
 
"Therefore for every single value on every single drive I had to first convert the INT to a DINT, then from a DINT to a REAL. And I could do my math on that value to scale it to real world units."


Man I hope you didnt do this- thats what FB/FC's are for
Build one FB for your drive and call x times
 
"Therefore for every single value on every single drive I had to first convert the INT to a DINT, then from a DINT to a REAL. And I could do my math on that value to scale it to real world units."


Man I hope you didnt do this- thats what FB/FC's are for
Build one FB for your drive and call x times

In the context of how it was done it would not have resulted in any significant benefit.
 
Here's some example Step 7 processing that flashes one digital output, Q0.0 The aim of the implementation was to hide how Q0.0 was been flashed.

I would be interested to see the comments on how to copy this implementation in AB
 
I think this boils down to semantics.

Elements of an array are memory locations. The difference is that in S7 the memory locations are fixed whereas in Logix5000 they are dynamic. I can easily create an array in Logix5000 and treat it like flat memory in just the same fashion. I don't see any difference between an "array" in Logix5000 and a DB file in S7.

Or to turn it around and look at it from another perspective, isn't the base S7 memory structure just one big "array" of memory.


Most importantly, can you pose a real world example where the way that S7 handles pointers allows you to solve a problem that you otherwise would not be able to do in RSLogix5000 with the way they handle pointers? Perhaps you can post an example of this S7 code and we can try and do the same thing in RSLogix5000 as an excercise?

I am wrong here or am I missing something?

If you remember this thread:
http://www.plctalk.net/qanda/showthread.php?p=450795#post450795

I was looking for a way to pass an address instead of a value. I got it done by moving the different values into 1 adress and just pass that each loop but that's not my point. I couldn't pass the address.

Not everything is in arrays. Look at inputs on PointIO which is not in arrays. If you want to pass all the inputs from an inputcard into it's own AOI, you have to AND each bit in the inputword with 1 inside the AOI.

I realize that everything I just said can be done in R5K, but like the address conversion thing it's just that there's more clean ways to do things.

Ultimately what you seem to be looking for is a project that can't be done in one of the controllers, and I can't imagine that such a project.
 
Here's some example Step 7 processing that flashes one digital output, Q0.0 The aim of the implementation was to hide how Q0.0 was been flashed.

I would be interested to see the comments on how to copy this implementation in AB


Was waiting for these.
 
For instance, the last project I was on was talking to Lenze drives over Profibus. All the Lenze data was in INT format, however many values were such that the values were resolved (ie 0 to 3000 rpm = 0 to 2^14 counts).

Therefore for every single value on every single drive I had to first convert the INT to a DINT, then from a DINT to a REAL. And I could do my math on that value to scale it to real world units.



What???

So you had a move or load /transfer for each control and status
on all the pzd data?

Thats definately the wrong way to program
 
Here's some example Step 7 processing that flashes one digital output, Q0.0 The aim of the implementation was to hide how Q0.0 was been flashed.

I would be interested to see the comments on how to copy this implementation in AB


Thanks LD. Thats the kind of thing I was asking for. I'll try and fiddle with this some later.
 
If you remember this thread:
http://www.plctalk.net/qanda/showthread.php?p=450795#post450795

I was looking for a way to pass an address instead of a value. I got it done by moving the different values into 1 adress and just pass that each loop but that's not my point. I couldn't pass the address.

Not everything is in arrays. Look at inputs on PointIO which is not in arrays. If you want to pass all the inputs from an inputcard into it's own AOI, you have to AND each bit in the inputword with 1 inside the AOI.

I realize that everything I just said can be done in R5K, but like the address conversion thing it's just that there's more clean ways to do things.

Ultimately what you seem to be looking for is a project that can't be done in one of the controllers, and I can't imagine that such a project.

Jesper, Thanks for taking the time to explain. I'll take some time to think it over.
 

Similar Topics

Hi guys I have never done a step register so I need help . I have a compact logix plc which I've been asked to add an extra function.the machine...
Replies
3
Views
2,308
I am having a step7 v5.4 program where the blocks are encrypted and locked. And the manufacturer is stopped the support. Is there any ways to...
Replies
2
Views
132
Good Morning, Hoping someone with some Siemens experience can give me a hand with this one. Customer has a S7-200 cpu, which has a 6GK7...
Replies
0
Views
214
HI! HOW COULD I OBTAIN THE NAMES OF THE STEPS OF A ROUTINE IN SFC LANGUAGE IN STUDIO5000? Or is there a system variable that gives me those...
Replies
0
Views
331
I'm just trying to figure out the right method of adding a DO card to an existing rack. It's not the *next* open slot, but I have to move the AO...
Replies
5
Views
527
Back
Top Bottom