5 ms·
One thing missing here and in most of the visual programming discussions since it sits in a somewhat adjacent SCADA industry is Ladder Logic[1]. It was pretty
by vvanders 5y ago
One thing missing here and in most of the visual programming discussions since it sits in a somewhat adjacent SCADA industry is Ladder Logic[1].
It was pretty illuminating how many parallels ladder has with the visual and scripting solutions I'd worked with in GameDev. Hot-reload under running processes, visual debugging very reminiscent of node based visual editors. I ended up automating our greenhouse with a P100[2] from Automation Direct and was pretty impressed with how straightforward it was to use.
Structured text is making in-roads in some places from what I can tell but ladder still seems to dominate because it's easily understood and maps well to a "relay based" mental model. It seems to be very sticky, at least more than most visual scripting languages I'm familiar with.
[1] https://en.wikipedia.org/wiki/Ladder_logic https://en.wikipedia.org/wiki/Ladder_logic
[2] https://www.automationdirect.com/adc/shopping/catalog/programmable_controllers/productivity_series_controllers/productivity1000_(stackable_micro_plc)/cpus/p1-540 https://www.automationdirect.com/adc/shopping/catalog/progra...
- mikewarot 5y agoLadder logic is powerful stuff. I learned it at Westinghouse in the 1980s. It's a non-Von Neuman based programming methodology well suited to real time environments. Every ladder gets executed once per cycle, and there are usually a few hundred cycles per second. Special functions are implemented in boxes, like delays, counters, etc. My task back then was to feed the entire I/O state into a ring buffer, and when a "crash" of the steel mill happened, a host PC could then download the entire buffer, giving access to information about what happened in the seconds BEFORE the crash. It would be fairly easy to port to the Arduino, if someone hasn't done it already. Yep - it's been done https://cq.cx/ladder.pl https://cq.cx/ladder.pl Because Ladders are text based, you could use Teco/EDT/Vi/Emacs/WordStar macros on them.
- vvanders 5y agoYeah, it's a pretty neat ecosystem. PLCs are kinda like the Legos of automation, incredibly easy to mix and match with a fair number of (insecure) standard protocols. I briefly toyed with the idea of building out some open source hardware/software but I didn't really seem like there was enough of a userbase to make it viable. Anyone using it professionally wants support and 10+ years of parts, most maker/hobby projects want direct access to code. Still some pretty neat concepts for putting together highly customized processes with extensible and interchangeable hardware.
- high_byte 5y agoif you show them how insecure their current hardware is, it will sell. if it supports the old protocol but secure it should be transparent to them
- mikewarot 5y agoYou don't understand how industry works. If it works, you don't replace it, you get it fixed when it breaks. Nobody is going to willingly risk their factory, plant, etc. on some new supposedly better hardware. They'll keep what works going for 100+ years if they can. It is totally logical for them to do so. The "security" threat can be band-aided over with a new firewall at the internet access. Replacing any component of the control system introduces an element of risk. Downtime is horrendously expensive, and can ruin a business. Only a fool would do anything to introduce the risk of downtime in the name of "efficiency".
- mikewarot 5y agoI'm sorry about the tone of my other reply. In retrospect it was rude.
- liketochill 5y agoI use ladder for Boolean logic but transfer functions and block diagrams and numerical flow is better visualized with function block diagrams. It helps one gain an intuitive understanding of the effect of each term in a transfer function as you watch it operate in a way that structured text doesn’t offer.
- fest 5y agoIndeed, it's still very much alive in European industrial automation scene. The ladder logic lends itself well for majority of industrial automation problems (e.g. turn on the motor until the part triggers a sensor, then activate a pneumatic cylinder to push it sideways). The control flow can be easily followed for debugging. Since it's also easily interfaced with structured text modules, one can write procedural code for problems that are more easily expressed in procedural code (in my experience: statemachines, network communication, loops), but still use ladder logic that's more understandable by other people who may be maintaining the machine down the roead.