Omron CX-PROGRAMMER V9 Operation Manual page 103

Table of Contents

Advertisement

PART 1: CX-Programmer
CHAPTER 2 – Quick Start Guide
Writing a Program
Creating Symbols
An important step in creating a Ladder Program is the definition of those PLC data areas that are to be
referenced by the program. It is possible to skip this step, and use addresses directly within the program. It is
better, however, to create symbolic names for the addresses so that the programs become more readable and
maintainable.
Use the following procedure to create symbols.
1, 2, 3...
Repeat this procedure for each of the other entries in the following table:
RedLight
GreenLight
RedLightTimer
AmberLightTimer
GreenLightTimer
AmberOnlyTimer
RedTimerDone
AmberTimerDone
GreenTimerDone
AmberOnlyTimerDone
TimeInterval
Note:
CX-Programmer _Page 20
The following program sequences a set of traffic lights. The sequence is a standard British
sequence of the following order:
Red light only;
Red and Amber lights together;
Green light only;
Amber light only.
Writing a ladder program consists of:
Creating symbols;
Creating the ladder program;
Compiling (automatically checking) the program;
Transferring the program to and from a PLC;
Comparing the program with the PLC program;
Monitoring the program during execution;
Performing an on-line edit (if necessary).
1. Click in the Diagram Window and select the View Local Symbols button from the
toolbar.
2. Select the New Symbol button from the toolbar. The Insert Symbol dialog is displayed.
3. Enter 'AmberLight' in the Name field.
4. Set the Address or value field to '10.01'.
5. Leave the Data type field set to 'BOOL' to indicate a bit (binary) value.
6. Type 'Prepare to go / stop' in the Comment field.
7. Select the OK pushbutton to proceed.
Name
Address
10.00
10.02
1
2
3
4
T0001
T0002
T0003
T0004
48
It is important to use the standard form of addresses in CX-Programmer. Depending upon
their defined type, addresses may have two components – a channel and a bit number. In the
Data Type
BOOL
Stop.
BOOL
Go.
NUMBER
Timer for the red light period.
NUMBER
Timer for the amber light period.
NUMBER
Timer for the green light period.
NUMBER
Timer for the amber only period.
BOOL
BOOL
BOOL
BOOL
NUMBER
Speed at which the sequence works (ticks).
Comment
OMRON

Hide quick links:

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the CX-PROGRAMMER V9 and is the answer not in the manual?

Questions and answers

Table of Contents

Save PDF