Different plc languages

Liam 28

Member
Join Date
Nov 2008
Location
Dublin
Posts
53
Hi All

I was at a interview for work experience for college and I was asked about different methods of programming plc I said I was familiar with ladder logic and SFC . And I was asked could program through words say text something similiar to c code . I was not aware of this could any one tell me a good book or site where I could read up and research this method also any thing good on DCS and modbus.Any help would be great.
 
Thanks for the link. This may sound silly but the code I was looking at in the document does this allow you to to control say a output which may start a motor. Can you write a complete program in this langugae or is it used in conjuction with ladder if so would ladder be on one page and then this text on another or are they both on the same page of code. Sorry for all these questions but is there a name for this type of programming like there is for ladder or sfc.Thanks again for the help.
 
Yes, you can turn ON/OFF real outputs using Structured Text (ST).

Output := TRUE; (equivalent to a SET coil/instruction)

Output := FALSE; (equivalent to a RESET coil/instruction)

Q := (A AND B) OR C;

--|A|--|B|----------(Q)
|............|
.----|C|----

Do some background reading into Boolean algebra if you are not already familiar with the topic. It should help you express logic in ST.

You can also write a whole program in ST if you wish. I generally won't recommended it. (But if you have to program a Beckhoff PLC then...)

I tend to only use ST for data manipulation. If you want to perform operations on arrays, UDTs or strings etc it is generally easier and clearer to do so in ST.
It would also help if you learn a language like C or (C++ or Java to a lesser extent).

As an aside, I make a rule of writing to real outputs only in one location and only in ladder. This speeds up troubleshooting.
 
Last edited:
Thanks guys for the help really appreciate it it gives me a starting point to reearch structred text.I was wondering if the structered text is combined with ladder say on the say page or is there different files say one for ladder and one for structured text and would be downloaded to the PLC as aseperate files.
 
With all of the PLCs that I use (AB, Wago, GE RX3i) you are forced to create a different file for each type of code. They cannot be used in the same file, but you can call another file or program block written in a different language. Typically, I will write code that is math intensive in ST but leave things like interlocks and standard logic in ladder.

Regards
 

Similar Topics

i have two plc 1. s7-1212dc/dc/dc ip; 192.168.0.1 2. s7-1500 1513-1pn ip; 192.168.3.2 i need to get data from plc1 to plc2. any idea how to do...
Replies
5
Views
138
I'm currently working on a PLC setup and could use some advice on the best way to manage my power supply units (PSUs). Here's the configuration...
Replies
3
Views
419
I`m looking into different solutions for gathering data from different PLC`s (different manufacturers) to a central storage locally or cloud. The...
Replies
12
Views
862
Hello I was wondering how to link a button in Wonderware to two different PLC’s? This button is a reset button that resets both PLC’s. - one plc...
Replies
3
Views
232
Hi, If we have PLCs on different subnets is it possible to do TCP comms data transfer between them? I'm assuming if we use a routing switch and...
Replies
3
Views
824
Back
Top Bottom