Articles : Make your own PLC - Reliably
by: Dick Hollenbeck, President, SoftPLC Corporation
This article describes how you can build your own programmable controller, reliably. We look at selection criteria for each component separately and address reliability, price, and vendor service.
A few defacto hardware standards have emerged. The vendor competition in these segments is continually driving prices down, and this trend isn't about to stop.
Whether you are a Systems Integrator, OEM, or End User, you can now build your own PLC, and there are compelling reasons to do this.
|What is a PLC?
Your new open architecture Programmable Logic Controller has traditional PLC functionality. It should be programmable in run mode, has several programming and communications ports, forces I/O, does on-line searching, and backs up its program and datatable in non-volatile solid state memory. It is programmable with a personal computer, and should interface with a wide range of existing HMI products.
Additionally, this new PLC can operate directly on a personal computer LAN, making it easy to perform program maintenance. It can even back itself up to a file server, and it's probably faster and less expensive than other PLC's. You can even define new building block instructions which are seamlessly integrated into the programming environment.
Interestingly, your new PLC could consist of parts from 3 to 10 of your favorite vendors! You ask, "What? But who has overall responsibility for making it work?" Answer, you do. And this is not new. You have that same responsibility every time you buy a traditional PLC from one of the PLC market leaders. Think about it, if a PLC doesn't work you replace the bad part, whether it's a processor, power supply, I/O card, or memory card. You call the vendor and they send you a replacement part; that is, if you don't already have one in stock. You fix it, don't you?
You already know how to replace the parts of a traditional PLC. Your new, open architecture PLC is no different in this regard.
Your new PROCESSOR is an industrially hardened personal computer. But more importantly, it's an open architecture PLC.
In the end, your new PLC gives you the ultimate maintenance luxury: if after several attempts to replace a bad part with supposedly working components, should it still not work, then you can drop the vendor and find a new one for this component.
|Selecting the I/O
This is one of two areas where you need to choose carefully because the cost of switching I/O type and/or vendor later is higher than all other areas except one. The cost of switching I/O depends on your spare parts inventory and maintenance personnel training investment, and whether you are using an open architecture I/O bus or not.
Selection criteria to consider, in order of importance are: types of voltages and currents supported, software driver availability, reliability, maintainability, vendor support, size, and speed.
Your I/O vendor choices now include PLC vendors, third-party I/O bus vendors, and computer I/O vendors. While the PLC revolution was taking place during the 80's, the computer I/O vendors were pioneering new I/O technologies which in some ways are now superior to traditional PLC I/O. No matter, you can choose from multiple categories now because your new PROCESSOR is an industrially hardened computer and most PLC vendors & I/O vendors make adapter cards enabling a computer to run their I/O. So if you want, you may be able to stick with the same I/O you are already using.
Usually an I/O interface card plugs into your PROCESSOR's backplane and from there you cable to the I/O. In some cases a third party interface card may be needed. This is like buying an ethernet card or modem board for your personal computer from someone other than the computer vendor. It's no big deal.
Bottom line: it's no longer possible for one company to be all things to all people. Sometimes going with a company who specializes in a particular area gives you a best in class solution.
Not a complete list, but several I/O vendors to consider: Phoenix Contact, Wago, Entrelec, Advantech, ComputerBoards, Allen-Bradley, and GE Fanuc. The GE Fanuc Series 90TM/30 I/O adapter is a good buy, costing under $100. Advantech makes serial I/O blocks that don't require an interface card. ComputerBoards makes direct PC plug-in cards for ISA, PC/104, and PCI bus.
I have seen End Users contact their existing PLC Vendors and insist that they make an I/O interface card for ISA bus, so they can continue using their existing I/O with their new open architecture PROCESSOR. This lets the End User retrofit existing PROCESSOR installations with the new open architecture PROCESSOR and achieve the benefits of superior networking immediately.
|Selecting the Processor
There may be no need for a monitor or keyboard at runtime. These are liabilities and decrease system reliability. All non-I/O communications with the PROCESSOR should take place either over a LAN, serial port, or backplane, similar to a traditional PLC. Some KERNEL's require a monitor and keyboard, with others it is an option which may be helpful for diagnostics.
We treat each PROCESSOR component separately. They may not all come from the same vendor. Bus architecture is most important. You get the most options and best prices by sticking with ISA bus. Industry Standard Architecture is just that.
Some End Users opt for coprocessors which may be housed in anybody's computer or industrial workstation. Several companies make hardened ISA/PCI co-processors like this with PC-104 mounting sites for interface adapters, giving you a PLC PROCESSOR on a card. You are not limited to ISA however. CompactPCI and VME vendors offer multi-CPU solutions.
My preference is not the co-processor approach, but the ISA industrial shoebox. It is an inexpensive, dedicated box that is about the size of a small shoebox and uses a LAN to talk to the HMI or programming package running elsewhere. It has industrially hardened components rated at least 0-50 degrees C. Your baseline shoebox PROCESSOR should have a hardened power supply and a passive backplane. Unlike a desktop computer, the CPU and MEMORY should be contained on one or more separate plug-in cards housed on a passive backplane, where they are easily replaced in the event of failure or upgrade. Also, PC/104 vendors make very small, embedded industrial computers for a resulting PROCESSOR that is less than 6 inches square.
To protect against vibration, use a box which has a hold down bar across the front edge of the plug in cards opposite from the screw-down bayonet. PC/104 is also very good in this regard by design, without the need for special bracket protection.
IMPORTANT: Use a UPS (Uninterruptible Power Supply) system to provide continuous power and make normal dynamic ram essentially non-volatile. (Some software KERNEL's can be set up to sense their own loss of power and back up their application images to disk before total failure.)
Several vendors to consider are Advantech, Ant Computers, Texas Microsystems, and Mitac.
Keep the door open to PCI bus. Its higher performance, jumper free configuration, multi-master architecture, and mainstream desktop usage, make it a clear winner for the future. Yet another bus, CompactPCI is an industrial version of PCI with a completely different form factor, and is much more expensive than PCI.
After bus architecture your next most important criteria is price, followed by vendor service. There is little or no cost for you to switch PROCESSOR vendors. Make sure your PROCESSOR vendor knows you expect good service and don't be afraid to change. Let the laws of supply and demand work for you. You are the customer.
|Selecting CPU & Memory
There are a number of excellent CPU cards available. Having MEMORY on
board the CPU card means the CPU doesn't have to go across the backplane
to access memory. Soldered connections are more reliable than physical contact
points. Given a choice, choose surface mounted (soldered) parts over socketed
parts. Select MEMORY which does parity checking.
You need 3 types of MEMORY: (1) AT BIOS firmware, (2) 8 to 32 MB of dynamic
RAM, and (3) 8 to 16MB non-volatile battery backed up SRAM disk or FLASH
disk or both. Type (3) is a solid state disk. Avoid mechanical disks entirely.
This means no floppy or hard drives!
PCMCIA memory adapters and cards are also available. These cards give
you a nice credit card sized portable solid state disk for easy transportation
of control programs, and are recommended in the event you don't have a
There are two types of FLASH file systems in use currently. The newer
type allows use of the convenient DOS copy command when writing to FLASH.
The older type requires you to create a disk image first, and should be
avoided because of its inconvenience. FLASH memory is available as ISA
Cards, PC/104 cards, PCMCIA cards and today most industrial CPU cards
support Flash memory as a chip.
Go with a hardened CPU card, rated at least 0-50 degrees C. For about
the same cost, you can find some rated 0-80 degrees C with an MTBF of
25 years! Economies of scale make your best buy a 486-100MHz, which is
plenty of horsepower for most industrial control applications and well-designed
KERNELS. Pentium and Celeron CPU's are also becoming very affordable,
even in industrial form factors. Low-power Pentiums are even better for
applications requiring a lot of speed or processing power, since the CPU
fan required for standard Pentium CPU's is a fragile part - a problem
waiting to happen. If you do use a standard Pentium CPU, we suggest replacing
the CPU fan with a heat sink for better reliability.
Although you may not have a monitor, keyboard, or floppy connected at
runtime, some CPU cards have interfaces for these devices on board and
may be used temporarily to install the KERNEL. After KERNEL installation,
the monitor, keyboard and floppy may be removed.
Criteria, in order of importance, are reliability, price, vendor support,
and new FLASH file system support. There is little or no cost to you to
swap CPU/MEMORY vendors. You should find what you need for less than $500.
Again, there is no cost for you to change vendors later.
|Selecting Network Interface Hardware
You hit pay dirt. Your new open architecture PLC capitalizes on all the
tremendously innovative advances in the personal computer networking field.
There's lots of competition, economies of scale, and great minds at work
in the personal computer networking field. 100BASE-T Fast Ethernet is available
now for less than $50 per card - no control network approaches it for speed.
Very reliable 10BASE-T cards can be had for $25.
Proprietary PLC networks serve only one purpose: to lock you into that
particular PLC vendor. Rockwell's "new" ControlNet is a perfect
example of this - a 5MB network in today's world is ludicrous. TCP/IP
ethernet can be deterministic, and at 100MB, determinism isn't even an
Go with 10BASE-T, 100BASE-T, or 100BASE-VG ethernet network interfaces.
Later, consider adding an ethernet switch to your LAN to partition your
control network segments from your MIS network segments into separate
collision domains. It can all remain one LAN however. Most CPU cards today
include a 10/100BASE-T ethernet port on-board.
It needs to be said again (because you'll hear otherwise from the PLC
vendors), "proprietary PLC networks serve only one purpose: to lock
you into that particular PLC vendor." The greatest networking minds
in the business work in companies like 3COM, DEC, IBM, Standard Microsystems,
and INTEL and not in PLC companies. So why do PLC companies continue to
bring forth "new networking technologies"? Now you know.
|Selecting the Control Software Kernel
The KERNEL is the runtime software component which converts the industrially
hardened computer into a PLC. This is your most important component selection.
When you select a KERNEL vendor, you select that vendor's philosophies
and know-how, and there are a number of important differences to be aware
of. Some KERNEL vendors want you doing HMI, data logging and control all
on the same CPU running on some type of Windows operating system. Other
vendors are conservative and more conscious of reliability issues.
The question not to ask is whether you can effectively perform control,
HMI, and logging all on the same CPU. The real question is, "should
First, what do you possibly gain? One cubic foot of plant volume because
you have one less computer box around? A few dollars in hardware savings?
How about a few kilowatt-hours? These gains are trivial in comparison
to the cost: seriously decreased system reliability.
My company, SoftPLC Corporation, offers a control KERNEL called SoftPLC.
Our philosophy and experience has brought forth a very conservative approach
to this business. We are able to look the customer in the eye and say
in clear conscience that when you install our KERNEL on industrially hardened
computer hardware, that you truly get a PLC. Our opinion on this matter
is strong, as shown in the following analogies.
You might hire a part time secretary to do typing or bookkeeping for
you. They might even carry a pager so you can call them when you need
them. When they are not needed they can work other jobs across town. No
problems here. These are non-mission critical jobs.
What about running your plant? Would you hire a part time operator and
leave your plant unattended for any amount of up time? Part time wouldn't
be right, even if the operator has a beeper. What if the operator were
to get bogged down in other jobs or get caught in traffic travelling across
Reliability is your first KERNEL selection criterion. Do you go with
a vendor who wants you to dedicate a CPU or do you go with one who encourages
you to take risk?
Remember this: there is reliability in simplicity. Multi-tasking operating
systems are not simple. Windows is a good platform for HMI, data analysis, or programming software, but they
are not platforms on which to base a real-time PLC KERNEL. How many times
have you had to reboot Windows? How many of those times would have been
acceptable in a control environment? Silicon is cheap, so dedicate it.
I can not stress this enough.
Your next most important selection criterion is ease of learning. How
familiar are your people with the programing model used by the KERNEL?
Do you already know ladder logic, flow chart, statement list, state logic,
or structured text? What is the best match for your people?
Is the system open architecture? Is there a toolkit enabling somebody
other than the vendor to add I/O drivers and new instructions?
Other issues to consider are the features of the program development
editor. Can you do online run-mode programming? I/O forcing? On-line search
and replace? Non-sequential rung display? Datatable watch windows? Intelligent
program difference detection? Is there program documentation support,
rung comments, and address descriptions (labels)?
Can you do off-line simulation and testing of the application logic?
Can you include a process model in that simulation?
What kind of networking support is there? Some KERNEL's can coexist on
both existing PLC networks and personal computer LANs.
What other products does the vendor have? How much experience in real
time control do they have? How long has the company been in business?
Speed is not a particularly important criterion, because in the unlikely
event the software is not fast enough, simply buy a faster CPU. By the
time you look twice the faster CPU hardware will have halved in price.
If you are uncomfortable entrusting your plant to a small software firm
(as most KERNEL suppliers are), ask them if they will put the source code
into escrow. That way if the KERNEL vendor should go out of business,
you are protected.
Company size is not a particularly good measure of expertise, nor stability
for that matter. A smaller company can be more responsive to your needs.
In this day of legendary customer service objectives, finding a customer
driven KERNEL vendor is not hard. Just call SoftPLC Corporation if you
You may have other specialized requirements. An open architecture hardware and software system means you are never locked out or in. There are plenty of plug-in cards and drivers and Systems Integrators who specialize in assisting people in building these kinds of systems. A consequence of reorienting toward open architecture systems, is that vendors become LESS important, and your relationships with System Integrators become MORE important. There are a number of SI's who can build these kinds of systems for you.
Your completed PROCESSOR may only have 2-3 cards in it: CPU/MEMORY, the I/O interface card, and maybe an ethernet card. Excluding the software KERNEL and I/O interface, you will be able to put together a PROCESSOR solution for well under $700, today. Tomorrow it will cost even less.
View Printer Friendly Page
Certain pages on this site may require some of the following:
Last modified: March 12, 2007
Copyright © 2014 SoftPLC Corporation
All Rights Reserved
SoftPLC and TOPDOC are registered trademarks of SoftPLC
Corporation. All other trademarks are the property of their respective owners.
This website is produced by SoftPLC Corporation
"as is" without warranty of any kind,
either expressed or implied, including,
but not limited to merchantability, fitness
or non-infringement. In no event shall
SoftPLC Corporation be liable for any
special, indirect or consequential damages
or any damages whatsoever resulting from
loss of use, data or profits, arising
out of or in connection with the use of
any information posted on this site.