# How to document/model a PLC based project?

T

#### Tom Reaney

I am looking for help in how to tackle a PLC based project for a machine
with an IP67 operator interface and mobile broadband connection for a
hydraulic press machine.

Initially I need to model/describe what is it that I need the machine to do.
I propose using the waterfall model of software development (shows my age)
which I believe is adequate for a project of this nature:

1. *Requirements
specification*<http://en.wikipedia.org/wiki/Software_Requirements_Specification>
2. *Design* <http://en.wikipedia.org/wiki/Software_design>
3. Construction (AKA
*implementation*<http://en.wikipedia.org/wiki/Implementation>or
coding)
4. Integration
5. Testing and *debugging* <http://en.wikipedia.org/wiki/Debugging> (AKA
Verification)
6. *Installation*<http://en.wikipedia.org/wiki/Installation_(computer_programs)>
7. *Maintenance* <http://en.wikipedia.org/wiki/Software_maintenance>

I can write it down and describe the functions. What I want to ensure is
that I'm using an industry standard representation. I can do a flowchart by
hand but would prefer to do this with software. Any pointers as to where to
find a template for an automated machine would be helpful. I'd love an Excel
spreadsheet model to help with this.

The machine will be a hydraulic press with hydraulic rams controlled via
electro hydraulic solenoid valves switched by the PLC. Ideally 12V DC
operation but if I have to go to 24V DC I will. Digital IO = 16 digital IO
with room to expand to 32 IO and possibly 64 IO. Analog IO = 4.

PLC scan time not important. Ability to retain (no-volatile) logs of
operational data is critical - things like hours of operation, output, idle
times...

For the PLC programming, Structured Text would be my preferred method
although I can handle ladder logic. No idea as to program size as yet. Need
USB interface.

Operator interface will be flat panel, touch screen, IP67. Color possibly
depending on cost. PLC and other electrical items will be housed in an IP67
enclosure.

Communications - local. I'd like to be able to interface a laptop to
the PLCvia a standard CAT 5 RJ24 ethernet cable via a web browser. If
available -
wirelessly connect.

Communications - remote. The machines will be used in fields. I need the
ability to be able to connect to them remotely via a mobile phone
connection. Ideally mobile broadband (hundreds of kbps) but HSDA/GPRS (10's
of kbps) at a minimum. I'm looking for a functional equivalent of *
www.logmein.com* <http://www.logmein.com/> (LogMeIn Free) for PC's for the
PLC world if such an animal exists.

Tall order but I'd appreciate it if you can point me in the right direction.

__________________________
Tom Reaney
REANEY COMPUTER
*www.reaneycomputer.com* <http://www.reaneycomputer.com/>
*[email protected]* <[email protected]>
(087) 745-4566
========================

M

#### Michael Griffin

1) An "industry standard representation" flowchart would be a combination of state diagrams and grafcet (also known as structured flow chart), or just state diagrams. State diagrams are good for processes which branch all over, while grafcet is good for processes that are long linear sequences with parallel operations. To be honest though, most people in this industry seem to get by with just hacking away until it looks like most of the bugs are gone.

If you have any questions about the above, let me know, and I would be happy to go into more detail. It's not difficult once you have the basic concepts. The diagrams are also a big help in estimating the machine cycle time and optimising the sequence.

2) As for software, I've found that just drawing the diagrams with the drawing features in OpenOffice Draw or in MS-Word seems to be good enough. Anything more complicated doesn't seem to be worth the effort.

I don't know the details of your machine, but I suspect you should be able to get the whole diagram on one or two pages. What you want to do is draw the diagram, then write the program, then use the diagram to test the machine. Trying to draw the diagram after the fact usually turns out to be an exercise in futility.

3) As for the model of PLC to use, a number of different small PLCs should work. The best one to choose will in large part depend on what distributors are in your area. Also look into the cost of programming software, as that can get quite expensive in some cases.

4) For programming language, you will probably be limited to ladder logic in this hardware size range. It is also a better choice because quite frankly SCL is only very rarely used and nobody who has to service the equipment later is likely to understand it.

5) Most PLCs have non-volatile RAM in which you can store information. Some have supercapacitors for short term (up to a week) storage. You probably want to install a battery for longer term backup. Most PLCs accept a battery, but it usually has to be ordered separately.

6) For the MMI panel, you usually order that with the PLC. You will usually need special software to program it (check the cost for this).

7) Some PLCs have a simple web server. It is often an add-on expansion card. Many of them can also send e-mail and FTP.

8) For remote log-in, I assume you intend that for remote programming software or troubleshooting using the programming software.

9) Your application appears to be for mobile use. Some PLCs are built for 12VDC operation. That should be another item in your requirements list. You will probably however want some sort of electrical noise filtering between the vehicle power system and the PLC.

I don't know who the distributors are in your area. However, Siemens, Schneider, Koyo, Omron, Mitsubishi, etc. are all good candidates to consider. Put your hardware requirements list together (don't forget programming software), contact some local distributors, and talk to them about the application. You want to make sure that not only does the hardware work, but also that you can lay your hands on spare parts quickly when necessary.

D

#### Don

I've had pretty good luck with Unitronics Vision series PLC/HMI for small applications. The units are reasonably priced (< $1000, depending on model) and the programming software can be downloaded for free at the company's website www.unitronics.com CANbus and RS-232 is standard and an ethernet or RS-485 port are available as options. For a minimum working system, you'll need the base unit plus a "Snap I/O" module, which as the name implies, snaps onto the rear of the main unit. Only downside so far is they're in a plastic housing. Also, the analog I/O is uni-polar. I have been using these units to replace a similar Siemens C7-613 ($4K)

My two cents...

I have no business or financial relationship with either Unitronics or their distributors other than that of a satisfied customer.

M

#### Marcos T. B.

Tom,

An "hydraulic press machine" may need to comply with several regulations. This may include special hardware and software, beyond the client requirements.

Just a remainder.

Marcos T. B.

B

#### BCG

Mr. Tom,

1. Prepare FDS (Functional Design Specification) in which you have to explain your requirements, designed hardware structure, communication protocols & links between devices, electrical standards following, PLC program details, functioning of the system, etc. with necessary drawings. Based on the FDS, project development activities will be started.

2. Then comes DDS (Detailed Design Specifications), in which you have to explain how you developed the system and HMI screens and total system. This document is usually prepared in parallel with the project development activities.

3. Then prepare the system test documents-FAT & SAT, etc.

I hope this is what you are expecting.

Regards,
BCG
Optech Automation Technology