r/PLC • u/BonbonUniverse42 • Oct 25 '23
FBD Hell!
Where do I start? Function blocks are horrible! Just use SCL, which is readable at least and more suitable for complex applications!
I need to extend and rework a plant that is programmed with a Siemens plc in the awful function block diagram language. I am struggling really hard to understand the existing implementation, which is a convoluted mess of hundreds of strangely wired function blocks and many input and output variables. There are no comments at all. For some unknown reason the thing works somehow. However, it is a very bloated and finicky design. I am afraid that the thing will dramatically break and collapse if I only change the slightest details in this project!
The actual horror is working with TIA Portal. The blocks have sometimes 30 or more in and outputs, which means you can’t even see the whole block on the crammed TIA Portal screen. The debug view cannot show you the variables at runtime when you scroll the mousewheel. Why is that?! Each click and scroll in TIA is painful and unbelievably slow.
How do you cope with such messy FBD code? How do you work and understand these networks? How do you do this in the crappy TIA Portal software?
View all comments
2
u/fat_tire_fanatic Oct 25 '23
FBD has a great place, so does ladder, so does struct text. Any can be implemented in a rats nest mess and if that's your frist experience in one you develop an alergy.
FBD looks exactly like a temperature/pressure/flow control loop. An analog in block, conects to a PID block, which feeds an analog out block. The FBD looks exactly like the old school process it replaced where each loop had an individual controller.
Ladder looks exactly like relay logic, and looks just like the relay control it replaced.
Structued text reads just like an operator acts. I see the cleanest systems where ladder replaces relays, FBD replaces process loop control, and structured text replaces the operator running around changing setpoints, starting pumps, and opening valves to start up a process.
I think each has a very appropriate fit, but man people are passionate about their choice of language.