S5 STL Help......please

Peter_d

Member
Join Date
Jun 2005
Posts
15
Hi all



I am new here and this is my first post. If I am honest, necessity drove me to find this site, however I have to say that after having a good look around the place this is a really well put together site.



Ok, to cut to the chase, I have a problem which I would appreciate any help whatsoever with:



Almost all my PLC programming experience has been with AB PLC5 and SLC 500 PLC's (over 10 years). As such I am fairly well versed in ladder programming. However, I now find myself with a bit of a dilemma.....



I have been landed with a Siemens S5 115U programme to modify. Now, I have got a hold of a demo copy of some software (S5/S7 for Windows from www.softwaretoolbox.com) which has allowed me to have a browse around the programme. Now can you imagine my horror when most of the significant programme sections that I need to understand can not be displayed in ladder, only statement!



I have no experience with STL programming, however using the S5 reference manual I can pick out the basics and convert it to ladder.



Now, I am thinking that trying to convert the statement to ladder is perhaps not the best approach to be taking when trying to understand this programme. I think I really should be making the effort to understand the STL at firsthand, if you know what I mean....



Can anyone point me in the direction of perhaps something I can download which will give me some tuition in making the transition from ladder to STL?



An example of my dilemma is as follows:



A(
A F 250.0
A F 250.1
A F 254.0
O F 250.2
)
A F 253.7
AN F 250.7
S F 251.3
A F 251.3
= F 254.6
O F 251.1
ON F 253.7
R F 251.3
NOP 0
***




In the above STL code I can understand it fine up until the lines:



S F 251.3
A F 251.3
= F 254.6
O F 251.1
ON F 253.7
R F 251.3
NOP 0
***




From my bungled attempts to translate this in to ladder logic I seem to end up with a set instruction followed in series by a N.O. contact and then a coil?? Obviously some confusion on my part!



Also how do the lines after the "=" statement fit in? And also the "NOP" statement?? I believe this means no operation all outputs set to zero?



Now I really don't want to come on here and expect folks to spoon feed me STL advice so I would really appreciate if anyone can direct me towards any good learning resources. For some additional background, I am based here in South Korea and I am pretty much on my own with out any backup....so know you know my situation...any help any of you guys can offer will be very much appreciated..........

to summarise...I need to learn STL S5 programming...and fast!



cheers



Peter_d



sorry it's such a long post for my first offering (wot no embarresed smilie?)
 
just try www4.ad.siemens.de

Hi,


my friend just try out the site www4.ad.siemens and there go to s5 folder. There u can find free programming manual for S5 and system manual for 115 and be carefull if your cpu is 941/942 because its does not have any program memory area inside and it always uses memory in the slot for that.....this is a bit change as compare to most other S5 CPUs. Also with S5 u cannot translate complete programm in to LAD/FBD .....afterall its S5....so don't go in that direction.. if you need feel any difficulty u can contact me at [email protected]
 
Hi
Let your rung end at the Set instruction, then repeat the preceding logic with the logic following the Set instruction. Does that make sense?

 
Preceding
logic S (or OTL)
--||--------------()----

Then...

Same preceding
logic = (or OTE)
--||--------------()----



Edit - can't get ladder to display right, but the 'S' and the '=' should be over the output --()--
 
Last edited:
Peter,

NOP = No operation
S = Set or Latch in AB
R = Reset or Unlatch in AB

This logic could really be seperated out into multiple rungs of code. S5 or Siemens does it all together.

Your Quetion: From my bungled attempts to translate this in to ladder logic I seem to end up with a set instruction followed in series by a N.O. contact and then a coil?? Obviously some confusion on my part!

My Answer: In the logic the Bit F 251.3 is set on and then if F 251.3 is true then turns on bit F 254.6. This could be done in 2 rungs to understand it.

Dave
 
OK..if I understand your correctly you are saying that take the result of the logic up until the S instruction and sum this up to arrive at either a 1 or 0 and then use this as the first instruction in another serious of ladder instructions?


i.e.

if previous logic up to set instruction = 1 then

-|/|- followed by the next lot of logic?
 
dmark88 said:
Peter,

NOP = No operation
S = Set or Latch in AB
R = Reset or Unlatch in AB

This logic could really be seperated out into multiple rungs of code. S5 or Siemens does it all together.

Your Quetion: From my bungled attempts to translate this in to ladder logic I seem to end up with a set instruction followed in series by a N.O. contact and then a coil?? Obviously some confusion on my part!

My Answer: In the logic the Bit F 251.3 is set on and then if F 251.3 is true then turns on bit F 254.6. This could be done in 2 rungs to understand it.

Dave

my god...perhaps I am begining to understand this.....

give me a few minutes and I will post the original STL and my conversion to ladder..will appreciate any comments...
 
ok guys how does this look:


1.) Original STL code:

A(
A F 250.0
A F 250.1
A F 254.0
O F 250.2
)
A F 253.7
AN F 250.7
S F 251.3
A F 251.3
= F 254.6
O F 251.1
ON F 253.7
R F 251.3
NOP 0
***

2.) My (first attempt at) Translation to ladder

Rung 1:

F250.0 F250.1 F254.0 F253.7 F250.7 F251.3
-| |------| |------| |-----| |-----|/|------( )
| F250.2 |
|----| |----------------|

Rung 2:
F251.3 F254.6
--| |----------------------------------------( )
| |
| F251.1 |
|-| |-----|
| |
| F253.7 |
|-|/|-----|

Is this correct? Still not sure how the R F251.3 instruction at the end fits in?
 
KBrodin said:
I don't have S5 on this machine. Attached is a S7 version of the STL code. Replace the Ms with your Fs and this is what it should look like.

wow thanks man...I need to print this out and spend a couple of mins checking this...as you will see form my previous post I am not quite there yet.......
 
Peter_d said:
wow thanks man...I need to print this out and spend a couple of mins checking this...as you will see form my previous post I am not quite there yet.......

Your welcome. Looking back over it, I noticed that I reversed Networks 2 & 3 -- Sorry. But you get the idea.
 
KBrodin said:
I don't have S5 on this machine. Attached is a S7 version of the STL code. Replace the Ms with your Fs and this is what it should look like.

OK I think I now understand the flow of this logic. Thank you very much for your post with the ladder translation.

I still find the order of the lines in the STL programme a little confusing when compared to the ladder translation but I am getting there. I think I need to study this example a bit more to get some more understanding. Howver many thanks to you for my first lesson in STL!
 
KBrodin said:
Your welcome. Looking back over it, I noticed that I reversed Networks 2 & 3 -- Sorry. But you get the idea.

ah ha! Now that makes even more sense now!! LOL!

as a great man once said............eureka!!
 
Hi,

I was trying for you to translate it into ladder. Just remove the NOP 0 at the end of you code and you should be able to switch your rung between STL and LAD.

I've tried in S5 and it worked.
Rudi
 

Similar Topics

Hi, I have never done any STL thus far but I now need to do some inderect addressing. I'm trying to write to a DB register by having a drop-down...
Replies
6
Views
1,910
Hi I wondered if anyone could help translate the following two networks into Lad as they don't directly translate. I've had a go myself but need...
Replies
20
Views
7,610
Hello nice to meet you, im new in here, I'm currently trying to convert code written in STL for a S7-400 to SCL for an S7-1500, because when i run...
Replies
5
Views
267
Hi! I am working on a project were we will be replacing an 300 CPU with a 1500 CPU and we are working on migrating / converting code. There is a...
Replies
9
Views
1,026
Hello everyone, friends. I asked a similar question before, and you helped, but I'm very weak in STL and I'm having trouble learning it. What I...
Replies
2
Views
736
Back
Top Bottom