Help - Search - Members - Calendar
Full Version: S5 Help
Forums.MrPLC.com > PLCs and Supporting Devices > Siemens
jtoney
I have an old machine, program dated 1989, from a European company that I need to upgrade the PLC to an A-B PLC. Most of the logic is ladder logic, but there are a few series of STL statements that I have no idea of what they are doing. I have searched these forums, but have not seen logic that is set up quite like what I have. I have listed these below. Any help translating them to ladder will be greatlt appreciated. I do understand how to determine the address being used and the descriptions, but not the actual programming. Thanks.

SEGMENTO 1 0000 TIMER DATA
0000 :A DB 11 -TEMP TIMERS DATA
0001 :***


SEGMENTO 13 005D SPACING STEP COUNTER
005D :A DB 12 -CONT COUNTERS DATA
005E :U E 0.3 -FC4 INDEX DEVICE POS
005F :U M 12.6 -ICP START SPACING STEP
0060 :ZV Z 2 -C2 SPACING STEP
0061 :UN M 12.6 -ICP START SPACING STEP
0062 :R Z 2 -C2 SPACING STEP
0063 :L Z 2 -C2 SPACING STEP
0064 :L DW 2
0065 :>=F
0066 :S M 12.7 -FCP END SPACING STEP
0067 :U M 12.7 -FCP END SPACING STEP
0068 :U E 0.2 -FC3 INDEX DEVICE CYL
0069 :R M 12.7 -FCP END SPACING STEP
006A :A DB 11 -TEMP TIMER DATA
006B :***


SEGMENTO 24 00BE STEP MADE CONTROL
00BE :UN E 0.2 -FC3 INDEX DEVICE CYL
00BF :U A 10.5 -EV3 BAR STEP SOL VALVE
00C0 :O T 5 -T5 STEP CONTROL TIMER
00C1 :S M 13.4 -SPE STEP MADE CONTROL
00C2 :O E 0.3 -FC4 INDEX DEVICE ON POS
00C3 :O E 8.3 -PM REM EMERGENCY RESET PB
00C4 :R M 13.4 -SPE STEP MADE CONTROL
00C5 :***



SEGMENTO 1 0000 FLASHING
0000 :UN M 100.0
0001 :L KT 025.0
0003 :SE T 0
0004 :U T 0
0005 := M 100.0
0006 :U M 100.0
0007 :UN M 100.1 -FL FLASHING
0008 :S M 100.2
0009 :U M 100.0
000A :U M 100.1 -FL FLASHING
000B :R M 100.2
000C :UN M 100.0
000D :U M 100.2
000E :S M 100.1 -FL FLASHING
000F :UN M 100.0
0010 :UN M 100.2
0011 :R M 100.1 -FL FLASHING
0012 :BE
JesperMP
It is in german notation, so that may explain why it is hard to read. U=und=and for example.
Here is my attempt at a pseudo tranlation to AB Ladder lingo.


SEGMENTO 1 0000 TIMER DATA
0000 :A DB 11 -TEMP TIMERS DATA Opens DB11 for subsequent use.
0001 :***


SEGMENTO 13 005D SPACING STEP COUNTER
005D :A DB 12 -CONT COUNTERS DATA (Opens DB12 for subsequent use)
005E :U E 0.3 -FC4 INDEX DEVICE POS XIC E0.3
005F :U M 12.6 -ICP START SPACING STEP (and) XIC M12.6
0060 :ZV Z 2 -C2 SPACING STEP = COUNT UP Z2
0061 :UN M 12.6 -ICP START SPACING STEP XIO M12.6
0062 :R Z 2 -C2 SPACING STEP = RESET Z2
0063 :L Z 2 -C2 SPACING STEP LOAD Z2.ACC (actual value)
0064 :L DW 2 LOAD DW2 (=DB12.DW2)
0065 :>=F COMPARE GREATER OR EQUAL TO
0066 :S M 12.7 -FCP END SPACING STEP OTL M12.7
0067 :U M 12.7 -FCP END SPACING STEP XIC M12.7
0068 :U E 0.2 -FC3 INDEX DEVICE CYL (and) XIC E0.2
0069 :R M 12.7 -FCP END SPACING STEP OTU M12.7
006A :A DB 11 -TEMP TIMER DATA (Opens DB11 for subsequent use)
006B :***


SEGMENTO 24 00BE STEP MADE CONTROL
00BE :UN E 0.2 -FC3 INDEX DEVICE CYL XIO E0.2
00BF :U A 10.5 -EV3 BAR STEP SOL VALVE (and) XIC A10.5
00C0 :O T 5 -T5 STEP CONTROL TIMER BST AND T5.DN BND (timer "done" bit)
00C1 :S M 13.4 -SPE STEP MADE CONTROL OTL M13.4
00C2 :O E 0.3 -FC4 INDEX DEVICE ON POS XIC E0.3
00C3 :O E 8.3 -PM REM EMERGENCY RESET PB BST XIC E8.3 BND
00C4 :R M 13.4 -SPE STEP MADE CONTROL OTU M13.4
00C5 :***



SEGMENTO 1 0000 FLASHING
0000 :UN M 100.0 XIO M100.0
0001 :L KT 025.0 = (start timer T0)
0003 :SE T 0 (Timer T0 contd.)
0004 :U T 0 XIC T0.DN (timer "done" bit)
0005 := M 100.0 OTE M100.0
0006 :U M 100.0 XIC M100.0
0007 :UN M 100.1 -FL FLASHING (and) XIO M100.1
0008 :S M 100.2 OTL M100.2
0009 :U M 100.0 XIC M100.0
000A :U M 100.1 -FL FLASHING (and) XIC M100.1
000B :R M 100.2 OTU M100.2
000C :UN M 100.0 XIO M100.0
000D :U M 100.2 (and) XIC M100.2
000E :S M 100.1 -FL FLASHING OTL M100.1
000F :UN M 100.0 XIO M100.0
0010 :UN M 100.2 (and) XIO M100.2
0011 :R M 100.1 -FL FLASHING OTU M100.1
0012 :BE
jtoney
QUOTE (JesperMP @ Sep 15 2009, 08:21 AM) *
0063 :L Z 2 -C2 SPACING STEP LOAD Z2.ACC (actual value)
0064 :L DW 2 LOAD DW2 (=DB12.DW2)
0065 :>=F COMPARE GREATER OR EQUAL TO


Thank you for the info, it has been a tremendous help. The only question I really have is what value is being loaded to compare to the counter accumulated value. I have listed the called DB below.

0: KF= +0004; UNUSED
1: KF= +0004; UNUSED
2: KF= +0004; NUMBER SPACING STEP
3: KF= +0004; UNUSED
4:

I believe that the counter value is being compared to a constant of 4, but am not sure.
JesperMP
"KF" tells us that the value is formatted as an integer, so 4 is correct.

edit: Since this value is placed in a datablock, it is not a constant. The "4" is probably just a default value.
Most likely the value can be adjusted on an operator panel for example.

Generally, all values that are stored in DBs, and appear to be not set anywhere by code, are probably operator udjustable settings.
jtoney
JesperMP,

I think I have this under control now. Thank you very much.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2010 Invision Power Services, Inc.