CHAPTER 3

advertisement
Chapter 3
Programming a
Programmable
Controller
Copyright © 2002 Delmar Thomson Learning
Objectives
Describe the available options for
programming a PLC.
Explain what online is in comparison to
offline.
List the advantages of software
programming with a personal computer
over a handheld programming terminal.
Copyright © 2002 Delmar Thomson Learning
Objectives (cont’d.)
Explain the differences when interfacing
a notebook personal computer to a
PLC.
Discuss open or soft PLC programming.
Provide an overview of the IEC 1131-3
standard.
Copyright © 2002 Delmar Thomson Learning
PLC Run Mode
The PLC can do nothing without
someone developing a program and
loading it into the PLC processor’s
memory.
Once the program has been loaded into
PLC memory the processor is put into
run mode.
While in run mode, the processor is
solving the ladder program.
Copyright © 2002 Delmar Thomson Learning
PLC Run Mode (cont’d.)
While in run mode, the processor reads
field device input signals and stores
them in memory.
There is one memory location for each
input screw terminal’s on or off state.
Field device status information is stored
in the input status table.
Copyright © 2002 Delmar Thomson Learning
PLC Programming
Oldest programming method is the
handheld programmer.
Most popular programming method is
IBM-compatible personal computer
using either DOS or Windows software.
Higher-end PLCs can only be
programmed using software.
Copyright © 2002 Delmar Thomson Learning
Allen-Bradley SLC 500
Programming Options
Copyright © 2002 Delmar Thomson Learning
Image courtesy of Allen-Bradley, a Rockwell Automation business
Allen-Bradley SLC 500
Handheld Terminal (HHT)
Copyright © 2002 Delmar Thomson Learning
Image courtesy of Allen-Bradley, a Rockwell Automation business
Handheld Programmer and
SLC 500 Modular Processors
Handheld used only on fixed SLC 500,
5/01 and 5/02 processors.
5/03, 5/04 and 5/05 modular processors
allow software programming only.
MicroLogix 1000 PLC has own
handheld programmer.
Copyright © 2002 Delmar Thomson Learning
Smart Handheld Programming
Terminal Advantages
Compact size.
Easy to use and learn, no software required.
Low cost; cheaper than notebook computer.
Easy to transport a program to the field.
Easy to transfer PLC program to HHT for
editing or troubleshooting.
Copyright © 2002 Delmar Thomson Learning
Smart Handheld Programming
Terminal Disadvantages
Holds one program at a time.
Newer more complex processors do not
support.
Limited capability to display ladder rungs.
Documentation not displayed.
Many keystrokes needed to program or edit
ladder program.
Dead battery means program lost.
Copyright © 2002 Delmar Thomson Learning
Software Programming
Using PC Advantages
Newer software Windows based.
View or monitor multiple ladder rungs.
Documentation displayed.
Easy to scroll through rungs for
troubleshooting.
Copyright © 2002 Delmar Thomson Learning
Software Programming
Using PC Advantages (cont’d.)
Programs stored on computer’s hard
drive.
Programs transferred to floppy or
CDROM.
Easy editing and programming, drag
and drop, cut and paste, etc.
Copyright © 2002 Delmar Thomson Learning
Software Programming
Disadvantages
Maintenance personnel must learn
Windows programming software.
Notebook computers are expensive.
Interface cards are expensive.
Personal computers not designed for
factory use.
Frequent software upgrades.
Copyright © 2002 Delmar Thomson Learning
Allen Bradley 1747-PIC Interface
1747-PIC communication box used to
communicate from a PC’s serial port to
a SLC 500 family data highway 485
PLC.
Connects to any PC with a serial port.
Communicates with fixed SLC 500, and
5/01, 5/02, and 5/03 modular
processors.
Copyright © 2002 Delmar Thomson Learning
AB 1747-PIC Interface
Converter Interface
Copyright © 2002 Delmar Thomson Learning
Image courtesy of Allen-Bradley, a Rockwell Automation business
Connecting a GE RS-422/RS-485
to a RS-232 to a PC
Copyright © 2002 Delmar Thomson Learning
Image courtesy of GE Fanuc Automation
Connecting a GE RS-422/RS-485
to a RS-232 to a PC (cont’d.)
Easy connection between personal
computer and Series 90-30 or 90-70
PLC.
Connects to computer serial port.
Connects up to 50 feet away.
Copyright © 2002 Delmar Thomson Learning
Desk Top or Industrial Computer
Interface to PLC
Allen Bradley 1784-KTX interface card.
PC ISA expansion slot card.
Connects to data highway plus or data
highway 485 processors.
Set up RSLinx software drivers to
communicate.
Copyright © 2002 Delmar Thomson Learning
Allen-Bradley’s
1784-KTX Interface Card
Copyright © 2002 Delmar Thomson Learning
Image courtesy of Allen-Bradley, a Rockwell Automation business
1784-KTX Card and
Network Interface
Easy network connectivity between
personal computer and up to 64 data
highway plus PLC 5 or SLC 5/04
processors (nodes) on DH+ network.
Up to 32 data highway-485 SLC 500
family processors on network.
Copyright © 2002 Delmar Thomson Learning
Node Addresses
Each device on the network will require
a unique identifier called a node or
station address.
Data highway plus network will support
up to 64 nodes, using octal addresses.
Data highway-485 network will support
up to 32 nodes, using decimal
addresses.
Copyright © 2002 Delmar Thomson Learning
Communicating to
Multiple SLC 500s
Copyright © 2002 Delmar Thomson Learning
Image courtesy of Allen-Bradley, a Rockwell Automation business
Notebook PC Interface to PLC
Direct serial connection
Hardware interface device such as
1747-PIC
PCMCIA card
Copyright © 2002 Delmar Thomson Learning
PCMCIA Interface Card
Notebook PCs do not have expansion
slots for installation of KTX card.
PCMCIA card is a credit-card sized plug-in
interface card.
Allen-Bradley’s PCMCIA card is called the
1784 PCMK card.
1784 PCMK card serves as an interface
between a PLC and a PC used as a
programming terminal.
Copyright © 2002 Delmar Thomson Learning
1784 PCMK Card Installation
Interface between notebook PC and
either DH+ or DH-485.
Interface PLC 5 or SLC 500 family
processors.
Insert card into notebook computer
PCMCIA slot.
Copyright © 2002 Delmar Thomson Learning
PCMK Card Insertion into a PC’s
PCMCIA Slot
Copyright © 2002 Delmar Thomson Learning
Image courtesy of Allen-Bradley, a Rockwell Automation business
Interface Cable Attachment
to PCMK Card
Copyright © 2002 Delmar Thomson Learning
Image courtesy of Allen-Bradley, a Rockwell Automation business
Interface Cable Attachment
to PCMK Card (cont’d.)
One cable to communicate to SLC 500
DH-485 processors
One cable to communicate to SLC 5/04,
DH+processor
Same DH+ cable will communicate to
PLC 5 processors
Copyright © 2002 Delmar Thomson Learning
Interface Cable from
PCMK Card to PLC Processors
Copyright © 2002 Delmar Thomson Learning
Image courtesy of Allen-Bradley, a Rockwell Automation business
Industrial Computers
Notebook and desktop personal
computers were not designed for
continuous use in the manufacturing
environment.
Copyright © 2002 Delmar Thomson Learning
Industrial Computers
Are Designed to Withstand:
Dirt.
Shock.
Vibration.
High temperatures.
Wash downs.
Copyright © 2002 Delmar Thomson Learning
Industrial Computer Features
Shock-mounted hard drives
Air filters with air intake fans
Hazardous environment rating
NEMA 12, 4, and 4X ratings
Integrated mouse on front panel
Air-conditioned enclosure not required
Modular for easy repair
Copyright © 2002 Delmar Thomson Learning
Two Styles of
Industrial Computers
Panel-Mount
Computer and monitor built into one
integrated unit
Rack-Mount
Computer either separate component
mounted in standard 19-inch rack or
embedded inside enclosure
Separate monitor or touch screen display
Copyright © 2002 Delmar Thomson Learning
Rockwell Automation’s RAC 6181
Computer Connections
Copyright © 2002 Delmar Thomson Learning
Image courtesy of Allen-Bradley, a Rockwell Automation business
Connecting Industrial Mouse and
Keyboard to the RAC 6181
Copyright © 2002 Delmar Thomson Learning
Image courtesy of Allen-Bradley, a Rockwell Automation business
What Is the IEC 1131-3?
Standardize PLC programming
A program developed on one system could
be used on other PLC platforms with
minimum modification.
Programming languages, Part 3 of the
1131-3 standard, has attracted the most
attention internationally.
Copyright © 2002 Delmar Thomson Learning
IEC 1131-3
Programming Standard
Defines a consistent set of set of
programming languages for PLCs:
Ladder diagram
Function block diagram
Instruction list
Structured text
Sequential function block
Copyright © 2002 Delmar Thomson Learning
Sequential Function Chart
Similar to flowchart programming.
Consists of steps and transitions.
Each step is represented by a box that
contains one or more major actions.
When actions in the box are satisfied, the
box is exited.
Transition step must be true before next
step.
Copyright © 2002 Delmar Thomson Learning
Sequential Function Chart
(cont’d.)
Copyright © 2002 Delmar Thomson Learning
Sequential Function Chart
OR Logic
Copyright © 2002 Delmar Thomson Learning
Sequential Function Chart Illustrating
a Simultaneous Branch
Copyright © 2002 Delmar Thomson Learning
Download