I am forced to really learn how to program a S7

Yes, but it is the ability to call indirectly or use call back functions/FBs that I haven't seen mentioned before that is intriguing. Now I can see why one would want to roll your own call instead of using the macro CALL.

They've been mentioned. When you get down to the UC FB level and manipulating AR2, basically anything is possible. Let your imagination run wild.

BTW, the
Code:
   UC FC[MW20] works
   UC FB [#Callthisblock] doesn't, at least not for me.

Is #CallThisBlock an INT? Is it a temp variable? I don't think it will work as an input parameter, and would have to be passed to a temp variable as an INT. This is another reason that I don't use parameters as a rule- if there is enough information to know what to type for a parameter, there is enough information to know how to calculate it. It comes down to proper code design.

I am looking for another USB-MPI adapter. The Siemens USB-MPI adapeter is very expensive for what it does. I see third part options. Does anybody have good experiences with the third party USB-MPI adapters. The Softing one looks good but I bet they charge as much as Siemens does.

Does it have to be USB? That is just so 90s. I use the Softing Ethernet-MPI adapter, and will never look back. Kind of nice being able to go online through a wireless hub via MPI.
 
They've been mentioned. When you get down to the UC FB level and manipulating AR2, basically anything is possible. Let your imagination run wild.
Yes, but again the code I was writing for the Ethernet had to be something that any LAD programmer can use.

Is #CallThisBlock an INT? Is it a temp variable?
I used the name of a FB. I doubted that would work because calling a FB can be done directly. I didn't try using an int. I will try that.

I don't think it will work as an input parameter, and would have to be passed to a temp variable as an INT. This is another reason that I don't use parameters as a rule- if there is enough information to know what to type for a parameter, there is enough information to know how to calculate it. It comes down to proper code design.
Part of the problem is that the documentation doesn't provide examples for all the ways UC can be used and what the parameters can be. You sound like me now complaining about not enough information but I agree with you on this point.

The advantage of using parameters is that the person that uses the FC or FB can see what is required but I can see why you feel this way. It is crazy that an ANY pointer can't be loaded from the VAR_IN but can be from the VAR_TEMP. If you don't use VAR_IN then you don't have this problem.


Does it have to be USB? That is just so 90s. I use the Softing Ethernet-MPI adapter, and will never look back. Kind of nice being able to go online through a wireless hub via MPI.
I will look into that. It doesn't need to be USB. If it cost about the same I will get it. The Siemens MPI-USB adapter that I use now will talk to the new PLCs at 1.5 Mbs. Can the Softing Etherent/USB adapter do that?

I installed Step7Lite at home last night. I am waiting for the last of the S7 to come back from the test labs. I can preconfigure the profibus controller to talk to one of our controllers. Our controller can then log everything that is sent over the PLC like a real time trace. The controller will also let me simulate what ever I want. I am just limited to 8 32 bit registers in and out. That is the limit that the old S7 could send in one Profibus DP packet with data consistency. That is still pretty good. 32 bits and 7 DWORDs, DINTs or REALs that can be logged every 0.5 milliseconds which is faster than the Profibus DP can update.

I got the CP5512 running with the Step7Lite. It seems slow compared to the USB-MPI. I don't know if it is the CP5512, the old S7 316-2 DP or the Step7Lite.
 
I got the CP5512 running with the Step7Lite. It seems slow compared to the USB-MPI. I don't know if it is the CP5512, the old S7 316-2 DP or the Step7Lite.
The MPI port on the 316-2DP is limited to max 187.5kbps. Maybe that is the explanation.
The CP5512 is much faster than the USB adapter.
 
Yes, but again the code I was writing for the Ethernet had to be something that any LAD programmer can use.

That's a different issue. If the code has to be written a certain way, then unfortunately a lot of the tools have to stay in the toolbox.

Part of the problem is that the documentation doesn't provide examples for all the ways UC can be used and what the parameters can be. You sound like me now complaining about not enough information but I agree with you on this point.

It's because I doubt they ever expected anyone to do it that way. I struck onto it my accident myself.


I will look into that. It doesn't need to be USB. If it cost about the same I will get it. The Siemens MPI-USB adapter that I use now will talk to the new PLCs at 1.5 Mbs. Can the Softing Etherent/USB adapter do that?

Yes, it will communicate at all baud rates, and over PPI and ProfiBus as well.
 

Similar Topics

is it possible to external read the Forced_value list from a PLC using UnityPRO? I need to get this data. It could be via modbus, ops... or even...
Replies
5
Views
2,444
So View SE 10 was the last to support HMI alarm tags. View SE 11 says you must migrate them to Alarm and Events. The View SE alarm summary will...
Replies
0
Views
1,895
I'm using an L33 PLC with an Ethernet I/P Point IO 1734-VHSC24 high speed counter to read in from an encoder, then calculating the counts per...
Replies
5
Views
1,752
So I have a dryer project that connects to the PLC and says "equal". When I connect it shows there are forced bits, but when I double-click on the...
Replies
3
Views
2,186
Hello All, I am using Allen Bradley Control Logix system, from the machine supplier I got the controller program developed in RS Logix 5000...
Replies
2
Views
2,034
Back
Top Bottom