#2079: PLCs: The Grey Boxes Running the World

Why factories still run on ladder logic, VxWorks, and rugged grey boxes instead of cloud servers.

0:000:00
Episode Details
Episode ID
MWP-2235
Published
Duration
21:06
Audio
Direct link
Pipeline
V5
TTS Engine
chatterbox-regular
Script Writing Agent
Gemini 3 Flash

AI-Generated Content: This podcast is created using AI personas. Please verify any important information independently.

The Hidden Brain of Industry
If you walk into a modern automotive assembly plant, you see robotic arms and conveyor belts. But the brain controlling it all isn't a sleek server rack; it's a rugged grey box mounted to a DIN rail in a dusty electrical cabinet. This is the Programmable Logic Controller (PLC), the uncelebrated backbone of the modern world. While the tech industry obsesses over the cloud and AI, PLCs run silently for years without rebooting, ensuring water flows, power stays on, and food processing plants keep moving.

The Global Giants
The PLC market is dominated by five major vendors, and geography largely dictates which one you use. In Europe, Siemens is the undisputed king, holding roughly 30% of the global market. Their SIMATIC S7 series, particularly the S7-1500, is the gold standard for high-end automation, having shipped millions of units. Crossing the Atlantic to North America, the landscape shifts to Rockwell Automation under the Allen-Bradley brand, controlling about 25% of the market. Their ControlLogix and CompactLogix platforms are ubiquitous in American heavy industry.

In Asia, the players shift again. Mitsubishi Electric’s iQ-R Series is legendary for execution speed, while Omron dominates robotics and compact automation. It’s also worth noting that Schneider Electric, now a major player, actually invented the very first PLC in the late 1960s under the Modicon brand. This fragmented market means that unlike the smartphone world with iOS and Android, industrial automation is a patchwork of regional standards and proprietary ecosystems.

Determinism: Why You Can't Use a Raspberry Pi
The most critical characteristic of a PLC is determinism. A standard computer operating system is "best effort"—if a background update causes a millisecond lag, you might not notice. In a factory, however, a delay can be catastrophic. If a high-speed press with fifty tons of force receives a stop signal ten milliseconds late because the CPU was busy, a machine worth millions could be destroyed, or an operator could be injured.

PLCs guarantee that code executes within a specific, fixed time window, usually measured in microseconds, every single time. This reliability is why you can't just use a standard PC to control a nuclear reactor. Under the hood, this determinism is often powered by a Hard Real-Time Operating System (RTOS) like VxWorks by Wind River. VxWorks is a monolithic kernel designed for high-availability embedded systems; it’s what runs the Mars Rovers and is hidden inside many Siemens and Rockwell PLCs. It handles task scheduling and memory management to ensure that microsecond timing is never compromised.

The Programming Paradox
Despite the advanced hardware, the programming languages often look ancient. The IEC 61131-3 standard defines five languages, the most famous being Ladder Logic. To a software engineer, Ladder Logic looks like a relic—a visual language of horizontal "rungs" between power rails, using contacts and coils to represent logic.

However, Ladder Logic persists due to the "Three AM Maintenance Tech" rule. When a factory line goes down in the middle of the night, the original programmer is likely asleep. The person on the floor is an electrical technician. If the code is in C++, the tech is helpless. But if it’s in Ladder Logic, they can see the live "power flow" on the screen. They can instantly see if a "Safety Gate Closed" contact is green (active) or red (inactive), diagnosing a dirty sensor or misalignment without needing to understand complex code. Ladder Logic is essentially a diagnostic tool disguised as a programming language, bridging the gap between digital logic and physical wiring.

For more complex tasks, engineers use Structured Text (ST), which resembles Pascal. ST handles heavy lifting like complex PID loops or data logging that would be unwieldy in Ladder. Most modern programs are hybrids: ST handles the "brainy" math inside Function Blocks, which are then displayed in Ladder Logic for the maintenance crew. Other languages like Function Block Diagrams (FBD) cater to process industries like oil refineries, mimicking piping diagrams, while Sequential Function Charts (SFC) are perfect for state machines (e.g., fill tank, heat, stir).

The Rise of the PAC and Industrial Edge
The line between hardware is blurring. Traditional PLCs handled simple "bits and bobs"—on/off logic. Today, high-end units are often called Programmable Automation Controllers (PACs), which are multidisciplinary, handling high-speed motion, complex processes, and IT networking in one device. A modern Siemens S7-1500 has more power than a PAC from a decade ago.

The most significant trend is the collision of IT and OT (Operational Technology). We are seeing Linux and containers like Docker invading the factory floor. Platforms like Phoenix Contact’s PLCnext and Siemens’ Industrial Edge are introducing true Linux-based controllers. These systems use a hybrid approach: a real-time extension "hijacks" specific CPU cores for deterministic control, while standard OS cores handle networking and UI. This allows for "PC-based control" where complex processing power meets industrial reliability, signaling a massive shift in how factories will be programmed and maintained in the future.

Downloads

Episode Audio

Download the full episode as an MP3 file

Download MP3
Transcript (TXT)

Plain text transcript file

Transcript (PDF)

Formatted PDF with styling

#2079: PLCs: The Grey Boxes Running the World

Corn
Imagine you are standing in the middle of a massive automotive assembly plant. It is loud, it is rhythmic, and there are hundreds of robotic arms moving with sub-millimeter precision, welding frames and glass into place every few seconds. Now, if you look for the brain of that entire operation, you aren't going to find a sleek server rack or a liquid-cooled gaming PC. You’re going to find a grey, ruggedized plastic box mounted to a DIN rail inside a vibrating, dust-filled electrical cabinet. That is the Programmable Logic Controller, or PLC. It has been running the exact same loop of code, twenty-four hours a day, for the last fifteen years without a single reboot.
Herman
It really is the uncelebrated backbone of the modern world, Corn. People talk about the cloud and AI all day, but if the PLCs stop, the water stops flowing, the power grid goes dark, and the food processing plants freeze up. Today’s prompt from Daniel is a deep dive into this exact ecosystem. He wants us to look at the "Big Five" vendors, the hidden operating systems that actually make these things deterministic, and why we are still programming multi-million dollar factories using a language that looks like a 1920s electrical blueprint.
Corn
Yeah, Daniel really went into the weeds with this one. He’s asking about the major players like Siemens and Rockwell, the real-time OSes like VxWorks that hide under the hood, and the whole IEC sixty-one-one-thirty-one dash three standard. Plus, he wants to know why Ladder Logic just won't die and how things are changing with Linux and Docker hitting the factory floor. By the way, quick shoutout to our script today—it’s being powered by Google Gemini three Flash. Herman Poppleberry, I know you’ve been itching to talk about industrial automation ever since you saw that Stuxnet documentary, so where do we even begin with these "grey boxes"?
Herman
We have to start with the sheer scale of the players involved because this isn't like the smartphone market where you have two big choices. In the PLC world, geography is destiny. If you are in Europe, you are almost certainly living in a Siemens world. Siemens has roughly thirty percent of the global market. Their SIMATIC S-seven series, specifically the S-seven fifteen-hundred, is essentially the gold standard for high-end automation. They’ve shipped something like twenty million S-seven units over the decades. They are the 800-pound gorilla of the industry.
Corn
And if you cross the Atlantic to North America, that gorilla turns into a different animal, right? That’s where Rockwell and Allen-Bradley live.
Herman
Precisely. Well, I shouldn't say precisely—I'll just say you're right on the money. In the United States, Rockwell Automation, under the Allen-Bradley brand, owns about twenty-five percent of the market. Their ControlLogix and CompactLogix platforms are the bread and butter of the American automotive and heavy industry sectors. Then you go to Asia, and it’s Mitsubishi Electric with their iQ-R Series, which is legendary for execution speed. You also have Omron, which is huge in robotics and compact automation, and Schneider Electric, which actually invented the very first PLC back in the late sixties under the Modicon brand.
Corn
It’s wild to think that the company that started it all, Modicon, is still a major player. But I want to poke at something you mentioned earlier. You called these things "deterministic." For the average person who thinks a fast computer is just one that opens Chrome quickly, what does "deterministic" actually mean in a factory setting?
Herman
This is the core of why you can't just use a Raspberry Pi or a standard Windows PC to run a nuclear reactor. A standard operating system is "best effort." If your mouse lags for a millisecond because a background update started, you might not notice. But if a PLC is controlling a high-speed press that is coming down with fifty tons of force, and the "stop" signal arrives ten milliseconds late because the CPU was busy checking for a software update, someone loses a hand or a machine worth five million dollars is destroyed. Determinism means that the PLC guarantees the code will execute within a specific, fixed time window—usually measured in microseconds—every single time, forever.
Corn
So no "Blue Screen of Death" while the molten glass is being poured. I assume that means the operating systems running on these things are nothing like what we use at home. Daniel mentioned VxWorks. Is that the secret sauce?
Herman
It is for a lot of them. VxWorks, made by a company called Wind River, is what we call a Hard Real-Time Operating System, or RTOS. It is a monolithic kernel designed for high-availability embedded systems. It’s what runs the Mars Rovers, and it’s also what is hidden inside the Siemens S-seven fifteen-hundred and the Rockwell ControlLogix. When you buy a multi-thousand dollar PLC from Rockwell, you aren't seeing the VxWorks command line. You’re seeing their proprietary firmware on top of it, but underneath, it’s that rock-solid RTOS handling the task scheduling and memory management to ensure that microsecond timing.
Corn
That’s fascinating because it means these competing giants are actually built on the same foundational architecture in many cases. But then you have the outliers. Daniel brought up Beckhoff and their TwinCAT system. They take a totally different approach, don't they? They’re basically putting a PC in the cabinet?
Herman
Beckhoff is the rebel of the group. They use what they call "PC-based control." They take a standard Industrial PC—which looks like a PLC but has an Intel or AMD processor—and they run Windows on it. Now, you might ask, "Wait, didn't you just say Windows is too unstable for this?" And you'd be right. But Beckhoff uses a real-time extension called TwinCAT. It basically "hijacks" one or more cores of the CPU away from Windows. When the computer boots, the TwinCAT kernel starts first and tells Windows, "You can have these three cores for your UI and your files, but this fourth core belongs to me. I own the hardware interrupts." So even if Windows crashes or does a forced update, the real-time control core keeps chugging along, completely unaffected.
Corn
It’s like a landlord who lives in the basement and owns the whole house, but lets a messy tenant live upstairs in the living room. The tenant can set the curtains on fire, but the foundation of the house—the machine control—is totally fine. It’s a clever way to get the benefits of a PC, like easy networking and big storage, without the reliability nightmares.
Herman
It’s very clever, and it’s why Beckhoff and their competitor B-and-R are so popular in high-speed motion control. If you’re doing something incredibly complex, like a machine that folds and packages three hundred cardboard boxes a minute, you need the raw processing power of an i7 or a Xeon chip, which traditional PLCs often lack.
Corn
Okay, so we’ve got the hardware and the invisible OS. Let’s talk about the part that actually drives people crazy: the programming. Daniel listed a bunch of acronyms from the IEC sixty-one-one-thirty-one dash three standard. The big one everyone mentions is Ladder Logic. Herman, please explain to me why, in the year twenty-six, we are still using a programming language that looks like a ladder made of lightbulbs and switches.
Herman
It’s the "Ladder Logic Paradox," Corn. To a software engineer coming from Python or C-plus-plus, Ladder Logic looks like an ancient relic. It’s a visual language where you draw horizontal "rungs" between two vertical power rails. You place "contacts" which represent inputs—like a button being pressed—and "coils" which represent outputs—like a motor turning on. If there’s a path of "power" from left to right, the output turns on.
Corn
It sounds like a glorified version of a logic gate diagram. But seriously, why haven't we moved on?
Herman
Because of the "Three A-M Maintenance Tech" rule. Imagine a factory line goes down in the middle of the night. The guy who wrote the code is asleep three states away. The person on the floor is an electrical technician. If the code is in C-plus-plus, that tech is helpless. But if it’s in Ladder, they can plug their laptop in, see the live "power flow" on the screen, and see exactly which rung is "broken." They see that the "Safety Gate Closed" contact is green, but the "Part Present" sensor contact is red. Boom. They know the sensor is dirty or misaligned. They fix the physical hardware, and the line starts moving again. Ladder isn’t for the programmer; it’s for the person who has to fix the machine when it breaks.
Corn
That actually makes a ton of sense. It’s a diagnostic tool disguised as a programming language. It bridges the gap between the digital logic and the physical wiring. But Daniel also mentioned Structured Text. Is that the "grown-up" version for people who want to actually write code?
Herman
Well, not exactly, but essentially. Structured Text, or ST, looks very much like Pascal. It’s high-level, it’s text-based, and it’s where you do all the heavy lifting. If you need to calculate a complex PID loop for temperature control, or you’re doing a lot of string manipulation and data logging, you do not want to do that in Ladder. It would look like a thousand rungs of madness. In ST, it’s just a few lines of "if-then-else" logic. Most modern programs are a hybrid. You use Structured Text for the math and the "brainy" stuff, and you wrap it in a Function Block that the maintenance guy can see in his Ladder diagram.
Corn
I like that. It’s like having a clean user interface for the high-level logic. What about the others? Function Block Diagrams and Sequential Function Charts? They sound like they’re for specific industries.
Herman
They are. Function Block Diagram, or FBD, is huge in the process industry—think oil refineries or chemical plants. In those worlds, engineers think in terms of "flows." You have a block for a valve, a block for a pump, and you just draw lines between them. It looks like a Piping and Instrumentation Diagram, which is what those engineers are trained to read. Sequential Function Chart, or SFC, is more like a flowchart. It’s perfect for "state machines." Step one: fill the tank. Step two: heat it to eighty degrees. Step three: stir for ten minutes. It makes the sequence of operations very clear.
Corn
It sounds like the IEC standard was basically a way to make sure that no matter what your background was—electrician, chemical engineer, or software dev—there was a language that spoke your dialect. But things are shifting now, right? We’re seeing the "blurring" Daniel mentioned. PLCs are becoming PACs. What’s the difference there, or is it just marketing fluff?
Herman
It started as marketing, but it became a real technical distinction. PAC stands for Programmable Automation Controller. The idea is that a traditional PLC was just for "bits and bobs"—on and off logic. A PAC is multi-disciplinary. It can handle high-speed motion control, complex process loops, and IT-level networking all in one unit. Today, the line is almost gone. A high-end Siemens S-seven fifteen-hundred is technically a PLC, but it has more computing power and networking capability than the "PACs" of ten years ago.
Corn
So it’s like how we used to have "cell phones" and "PDAs," and now we just have smartphones that do everything. But the real "A-ha" moment in Daniel's prompt for me was the mention of Linux and containers on the plant floor. That feels like a massive collision of two different worlds. You’re telling me people are running Docker on the same device that controls a high-voltage assembly line?
Herman
It is happening right now, and it’s the biggest trend in the industry. It’s often called "Industrial Edge." Companies like Phoenix Contact have their PLCnext platform, which is a true Linux-based controller. Siemens has their "Industrial Edge" modules. The logic is this: you keep your mission-critical, deterministic safety code in the RTOS side—the VxWorks or the proprietary firmware—because you need that microsecond guarantee. But you want to run a Python script to analyze vibration data and predict when a bearing is going to fail. Or you want to run a Node-RED dashboard to show the plant manager the O-E-E—Overall Equipment Effectiveness—in real-time.
Corn
So instead of having a separate PC next to the PLC to do the "smart" stuff, you just run it in a container directly on the PLC hardware.
Herman
Right. It saves space, it reduces wiring, and most importantly, it brings the "IT" world and the "OT"—Operational Technology—world together. You can push an update to a thousand PLCs across ten factories using the same DevOps tools you'd use for a web app, while the actual machine control remains "air-gapped" and protected within the real-time kernel. It’s the best of both worlds.
Corn
I can see the appeal, but it also sounds like a security nightmare if you aren't careful. We’ve all seen what happens when industrial systems get exposed to the open internet. If I’m running a Docker container with twenty different dependencies, am I opening a backdoor into my centrifuge?
Herman
That is the million-dollar question. This is why the "OT" world moves so much slower than the "IT" world. A software dev might update a library every week. A controls engineer wants to touch that PLC once every ten years. The industry is currently wrestling with how to maintain that "five nines" of reliability while still getting the benefits of modern software. This is where vendors like Schneider Electric are leaning into things like their ePACs, which have hardened Ethernet right in the backplane.
Corn
It’s a fascinating tension. On one hand, you have the "if it ain't broke, don't touch it" mentality of the factory floor, and on the other, you have the "move fast and break things" energy of modern software. And the PLC is the literal physical point where those two philosophies are smashing into each other.
Herman
It really is. And you see it in the vendors' strategies. Siemens is pushing "Software-Defined Automation" very hard. They want the hardware to become a commodity and the value to be in the "Digital Twin" and the virtual commissioning. They want you to be able to simulate your entire factory in a cloud environment, test every line of code, and then push it to the physical PLCs only when you know it works perfectly.
Corn
Which is a lot better than the old way of "program it on-site and hope the robotic arm doesn't punch a hole through the wall on the first run."
Herman
I've seen that happen, Corn. It’s a very expensive sound.
Corn
I bet. Now, let’s get practical for a second. If someone is listening to this and they’re a developer who’s tired of building CRUD apps and wants to get into the "world of things," where do they start? You can't exactly "download" a ten-thousand dollar Siemens S-seven and a factory line to play with in your bedroom.
Herman
You actually can get closer than you think. There’s a software suite called CODESYS. It is a device-independent development environment that follows the IEC standard we talked about. A lot of smaller vendors like Wago, Eaton, and even some Raspberry Pi industrial shields use CODESYS as their "O-S." You can download the development tool for free, and you can actually turn a Raspberry Pi or even your own PC into a functional PLC for testing. You can write Ladder Logic, Structured Text, and build a web-based H-M-I—Human Machine Interface—without spending a dime on hardware.
Corn
That’s a great tip. It’s like a "gateway drug" into industrial automation. And if you’re more into the open-source side, you mentioned Phoenix Contact’s PLCnext. That seems like a great bridge for people who already know C-plus-plus or Python.
Herman
It’s a game-changer. It allows you to use high-level languages alongside traditional PLC languages. You can literally have a C-plus-plus program and a Ladder Logic program sharing the same variables in real-time. It’s the ultimate "peace treaty" between the old guard and the new school.
Corn
I love the idea of a "peace treaty" in the form of a grey plastic box. It’s funny, we started this talking about how these things haven't changed in fifteen years, but by the end of this deep dive, it feels like we’re right on the edge of a total revolution in how stuff is made.
Herman
We really are. The "Big Five" are still dominant because of that legacy trust, but the "PC-based" guys like Beckhoff and the "Open" guys like Phoenix Contact are forcing everyone to evolve. Even Rockwell and Siemens are adding Linux layers and container support because they know they can't keep the "black box" closed forever.
Corn
Well, I think we’ve covered the map on this one. From the massive market share of Siemens to the "hidden" VxWorks operating system, and the reason why Ladder Logic will probably outlive us all. It turns out the "weird grey box" in the cabinet is a lot more sophisticated than it looks.
Herman
It’s a masterpiece of engineering, honestly. Making something that can survive in a hot, dusty, electrically noisy environment for two decades while executing a loop every millisecond is arguably harder than writing a social media algorithm.
Corn
Oh, I believe it. One has to handle "likes," the other has to handle "literal explosions if it fails." I know which one I’d rather be responsible for. Before we wrap up, I want to circle back to one thing Daniel asked about: the future of AI and ML in this space. We talked about containers, but are we actually seeing "AI PLCs" yet?
Herman
We are seeing the first steps. Mitsubishi and Omron have both released modules that have built-in "AI" for predictive maintenance. Basically, the PLC monitors the current draw and vibration of a motor, and it uses a pre-trained model to say, "Hey, this motor sounds like it’s going to fail in three days." It’s not "Generic A-I" like a chatbot; it’s very specific, "narrow" A-I designed for edge reliability. We aren't going to see a PLC "hallucinating" a factory schedule anytime soon, thank goodness.
Corn
"I'm sorry, Dave, I'm afraid I can't weld that chassis today. I'm feeling a bit uninspired." Yeah, let’s keep the LLMs in the podcast booth and out of the heavy machinery for now.
Herman
Agreed. But the convergence of 5-G and these Linux-based PACs is going to make "Mass Customization" a reality. Imagine a factory where every single car coming down the line is completely different, and the PLCs are reconfiguring the robots in real-time based on a cloud-based order. That’s the "Industry four-point-zero" dream.
Corn
It’s a wild future. And it’s all going to be running on some version of these grey boxes we talked about today. Herman, this was a blast. I feel like I could actually walk into a factory now and not just look at the robots, but look at the cabinets and know exactly what’s going on inside.
Herman
That’s the goal! Just don't touch any of the high-voltage rails while you're admiring the DIN mounts.
Corn
Noted. No licking the PLCs. Got it. Well, that’s our deep dive into the world of industrial control. Thanks to Daniel for the prompt that sent us down this rabbit hole. There’s something genuinely satisfying about knowing how the physical world is actually "programmed."
Herman
It makes you look at every soda can and every car door a little bit differently, doesn't it?
Corn
It really does. Alright, let’s wrap this up. Huge thanks as always to our producer, Hilbert Flumingtop, for keeping the gears turning behind the scenes. And a big thank you to Modal for providing the GPU credits that power this show. If you’re building something that needs serious serverless compute, check them out.
Herman
This has been My Weird Prompts. If you learned something today or if you actually work on a plant floor and want to tell us how wrong we are about Ladder Logic, we’d love to hear from you.
Corn
You can find us at myweirdprompts dot com for the RSS feed and all the ways to subscribe. And if you're enjoying the show, a quick review on your podcast app really helps us reach more curious nerds like you.
Herman
Until next time, stay curious and keep an eye on those status LEDs.
Corn
Catch you later.

This episode was generated with AI assistance. Hosts Herman and Corn are AI personalities.