why use structured text and function block over Ladder

Another point:

Many programmers, especially those who've learned in a more computer science background as opposed to electrical engineeeing one don't really understand computers intimately enough to fully appreciate what happens inside a PLC (or PC for that matter). A lot of things are handled behind the scenes by a compiler even before the CPU ever touches the code so to speak.

Good machine programming involves a very intimate and elemental relationship with with the machine and the process.
 
I think IntraDave has an excellent point

When the conversion to "computer control" was desired by the auto industry, there were already existing programming languages available (cobol?, fortran?, others?...) that could have been implemented.
CRINGE at the thought!!! The resources required to write code in Fortran was not industrial friendly. At that time I was typing and generating cards that would be fed to CDC computer. It would take hours sometimes to get my cards back just to find I made a mistake and have to make a correction on a card punch and turn the cards back in. That is no way to program. I didn't even like programming back then because of this.

So WHY develop a language that "looks like" the existing relay/wiring schematics? It certainly makes sense to develop something the current labor pool (both engineering AND maintenance) could more easily support. Kudos to Modicon and Morley for their foresight.
Actually, I don't see how any other decision could be made. Relay logic is relatively simple compared to what was being done in fortran or cobol. Back then the development tools for these high level languages left a lot to be desired. I know I wouldn't want to write code with the tools they had then. Ladder programming didn't requires make files, linkers and locaters and ANY visual programming would be MUCH more efficient than just getting an error message on a print out.

I think things would be MUCH different if C#, Visual Basic, or Python existed back then. I think it is a matter of timing.

Structured text is an oddity. ST is different from other high level languages in that there are functions and function blocks. Functions are much like functions in C or any other language but function blocks are something extra.

ST is still better for motion control than FBD, IL, or LD. Couple ST with a state machine like SFC and you have a winner.
 
Starter on Ladder and Basic

When I started programing PLC's I was already programing PC's in Basic. I am not sure if Java or Python existed back then they would be favored ovedr Ladder Logic. The reason I say this is because of hardware. Languages and everything else evolve because of hardware not the other way around. So my 2 cents to add to this conversation is watch the hardware and it will dictate what language you use. It maybe because of the complexity of future systems Ladder may go the way of the Doo Doo bird but I wouldn't hold my breath. Also the flip side is things are always going to get more complicated and there is limitations to ladder. The thing to rememeber is all are needed and what is needed at any perticular moment is as several have mentioned "what are you trying to do" and "what are you trying to do it with"

So yougins...learn ladder... dinasours (myself included) learn the rest... and if you use the wrong one at the wrong time...you suck...(n)
 
in 1973 I was learning 'Basic' on a time share computer terminal with honeywell. THIS was a main frame
in 1976 I started my apprenticeship as an electrician.
There was one machine out of about 300 that had PCB's for its control system (TTL) everything else was hard wired control systems
(Relay Logic)
I had to redesign control system in my third year and use a Stepping Relay.
I am a dinosaur -
Squared and TE PLC's were only just starting to be introduced into new machinery - Not popular in old machinery

Retro-fitting to PLC's started in the early 80's
 
It was economics, not union rules, that forced the use of Ladder Logic in the early PLCs. Only engineers (and not many of them!) and computer specialists understood programming at that time - it was essentially Fortran or Cobol or machine language. You aren't going to pay a bunch of these guys to run around the factory floor and debug a program, particularly when you already have electricians on staff that understand how the field devices work. Besides, based on personal experience, it would be a lot easier to teach an electrician how to write programs in ladder logic than it is to teach a bunch of "suits" how a transfer line works.
 
Peters discussion about punch cards brought back some memories. The first computer programs I wrote in school were on punch cards. I learned the hard way one icy winter morning to number my cards. I slipped on the ice and my stack of cards for a program I had been working on for days went flying. I had to hand sort everything to get it back into order. It took several hours and my assignment was late. After that I hand numbered my cards. Thankfully I never had to use them in industry. The first control computer I worked with was a DEC PDP8A - it used 'modern' paper punch tape. I actually got to where I could read the instructions on the tape by looking at the dot patterns.
Thankfully those days are long gone.
 
This is a PLC web site and I'm surprised that no one knows how their profession started.
Auto manufactures used to allow only 2 weeks in August for changeover to the new models. They were so desperate for bodies that they even hired this 16 year old as a die setter helper.
The machinery was controlled by relay logic and that required an army of electricians to reprogram by rewiring.
Long story short...Modicon won out because their software could be used by electricians who were more plentiful than programmers.
That leads me to the core of this thread. Equipment is purchased for only one reason and that is to create revenue for the end user. Everyone involved, mechanical designers, programers should focus on uptime instead of a simple or "elegant" design or program. A cumbersome, bulky mechanical design that allows for faster bearing change-out is far superior to a simple design that takes 8 hours to replace 2 10 dollar bearings.
Same with a program.
 
I forgot to mention
The earlier PLC's could only be programmed in Mnemonics.
(Ld01 out01) etc
RLL was the first improvement
 
Anyone remember Omron LSS? You could program in ladder or mnemonics. It was interesting to switch back and forth and see what the mnemonic equivilent to ladder was.

In all honesty, the controller doesn't run ladder diagrams, ST or FB. I'm pretty sure it's all converted into machine readable code anyway. All those niceties are for amusment of us humans.
 
Aren't most PLC programs considered "interpreted" vs "compiled".
Either way, the end result is always machine-level code specific to the chipset?
I remember cutting some teeth using the 8088 chipset, and I think the original Apples were 6052 chips? I seem to recall doing some machine level programming for those.....but my memory and some old bad habits have left me a little fuzzy.
 
I am pretty happy with a mix of LAD and ST ("SCL" in Siemens lingo).
What could be really nifty is if you could seamlessly write LAD and ST in the same program block.
I.e. one rung written in LAD, followed by some ST lines, then again followed by LAD. I cant see why not.
At the moment I do exactly that with LAD and STL, but ST would be much nicer than STL.
 
I remember Omron LSS - Syswin and Cxprogrammer
Mitsubishi (MEDOC) and Hitachi (ACTSIPE).
8088 prcessor's did not exist prior to August 12, 1981 (29 years ago)
(Quote Wikipeadia)
As I Stated earlier - P/C's did not exist Prior to the early 80's

Mnemonics can still be used - but i dont know, or need to know, how higher level programming would be done in that mode.
 
Last edited:
I remember Omron LSS - Syswin and Cxprogrammer
Mitsubishi (MEDOC) and Hitachi (ACTSIPE).
8088 prcessor's did not exist prior to August 12, 1981 (29 years ago)
(Quote Wikipeadia)
As I Stated earlier - P/C's did not exist Prior to the early 80's

Mnemonics can still be used - but i dont know, or need to know, how higher level programming would be done in that mode.

That sounds about right.
I built a HERO robot (from Heathkit....remember them?) in about 1982/83, which used the 6808 chip (NOT 8088).
Then, about 1986, I think the Apple 2 was using the 6502, which we used for a different robot system.

DI-NO-SAUR
 
Last edited:
I remember the heathkit and Apple but at that time i was working for Toyota Australia - thwy kept me very busy
 

Similar Topics

I am curious on something with a Case Statement in Structured Text. I am not the greatest at it so I want to know if my assumption is wrong or...
Replies
5
Views
2,203
Is there a reason why Studio5000 structured text and function block seems incomplete? I have the license for them but it appears there are...
Replies
9
Views
2,738
I have read all the posts I can find on ramp functions. I need some help with getting a linear ramp output. I want to have a ramp function...
Replies
9
Views
7,412
Hello, I am using studio 5000 pro and am trying to figure out the structured text. Here's my scenario: An operator scans a barcode, the barcode...
Replies
15
Views
238
I have an expression in a structured text routine of a Logix controller that looks more or less like the following: ResultInteger := Integer1 *...
Replies
13
Views
390
Back
Top Bottom