Download as pdf or txt
Download as pdf or txt
You are on page 1of 144

Programmable Controller

KV-1000 Series ABOUT THE KV-1000


About the KV-1000

Introduction Manual KV-1000 Functions

KV-1000 Device Configuration

MAKING A LADDER PROGRAM


What Is a Ladder Program?

KV STUDIO Functions

Flow of Work for Making a Program

Making Projects

Setting up Units
(Unit Editor)

Making a Ladder Program


(Ladder Editor)

Check Operation of the Ladder


Program (monitor)

Checking Program Operation without


a PLC(simulator)

REDUCES PROGRAMMING
MAN-HOURS
Turning Specific Sections of Programs
into Parts for Re-use (modules)

Procedure for Using Modules

About Local Devices

Making Original Instructions


(macros)

Procedure for Using Macros


Preface
This document clearly describes the features and functions of the KV-1000 Series, and methods
of operation for first time users of the PLC. It also presents the useful information (descriptions of
new features and some specific examples of use, etc ) for existing customers using the PLC.
Be sure to thoroughly read this document and fully understand the KV-1000 Series. More detailed
information about the KV-1000 Series and descriptions for using the Series are described in the
KV-1000 Series Programming Manual, and descriptions relating to the Series hardware and CPU
integrated functions are described in the KV-1000 Series User's Manual, descriptions relating to
the instructions are described in the KV-1000 Series Instruction Reference Manual. You should
also read these manuals together with this document.
Store this manual in a safe place so that you can retrieve it whenever necessary.
See to it that this manual reaches the last person who is going to use the KV-1000 Series.

■ KV-1000 Series Related Manuals

Type of Manual Description of Manual


Ladder Support Software
KV STUDIO / KV BUILDER This manual describes how to install KV STUDIO and KV BUILDER.
Installation Manual
Programmable Controller
This manual. This manual describes in simple terms the basic function and how
KV-1000 Series
to use the KV-1000 Series for first time users.
Introduction Manual
Programmable Controller
This manual describes the specifications of the KV-1000 Series, integrated
KV-1000 Series
functions, and methods of operation.
User's Manual
Programmable Controller
This manual describes how to make ladder programs using the KV-1000
KV-1000 Series
Series, and modules/macros and local devices.
Programming Manual
Ladder Support Software
KV STUDIO This manual describes how to operate KV STUDIO.
User's Manual
Programmable Controller
KV-1000 Series This manual describes the instructions available for the KV-1000 Series.
Instruction Reference Manual
Programmable Controller
KV-1000 Series This manual describes the system macros available for the KV-1000 Series.
System Macro Manual
Programmable Controller
KV-1000 Series
This manual describes how to make script programs using the KV-1000 Series.
Script Programming
Manual
Programmable Controller
KV-1000 Series
This manual describes the script functions available for the KV-1000 Series.
Script Function
Reference Manual

1
Brief description of the reference manuals
The following shows where you can see in the manuals for different purposes while using the KV-
1000 and KV STUDIO.

KV STUDIO / KV BUILDER KV STUDIO


(1) (5)
Installation Manual User's Manual
KV-1000 Series KV-1000 Series
(2) (6)
Introduction Manual Instruction Reference Manual
KV-1000 Series KV-1000 Series
(3) (7)
User's Manual System Macro Manual
KV-1000 Series KV-1000 Series
(4) (8)
Programming Manual Script Programming Manual
KV-1000 Series
(9)
Script Function Reference Manual

●What is a "PLC?" ●Specifications and how to use CPU internal functions


(2) "Chapter 1 ABOUT THE KV-1000" such as positioning and frequency counters
(3) "Chapter 5 HIGH-SPEED COUNTERS"
(3) "Chapter 6 FREQUENCY COUNTERS"
●Capabilities of the access window (3) "Chapter 7 CAM SWITCHES"
●To check device values on the access (3) "Chapter 8 MOTOR CONTROL (POSITIONING CONTROL)"
window (3) "Chapter 10 VARIOUS FUNCTIONS"
(3) "Chapter 2 ACCESS WINDOW"

●Specifications of I/O terminals


and interrupt processing
(3) "1-3 CPU Unit"
(3) "Chapter 4 INTERRUPTS"

●Specifications of Expansion I/O Units


(3) "1-5 Expansion Input Unit"
(3) "1-6 Expansion Output Unit"

●Specifications and how to use


KV-AD40 and other Expansion
Special Units
●Memory Card capabilities? User's Manual of respective unit
●About logging functions
(3) "Chapter 3 MEMORY CARD"

●To perform communications with external


devices on the RS-232C interface ●How to connect the PC to KV-1000
(3) "Chapter 9 SERIAL COMMUNICATIONS" (5) "1-3 Connecting Devices"

2
●To re-use KV-700 data
(4) "5-6 Fully Utilizing KV-700 Data"

●What is an (extended) ladder ●Specifications and how to use instructions


(4) "1-2 Programming Language" (6) (Instruction Reference Manual)

●To make ladder programs ●To program macros (original instructions)


(2) "Chapter 2 MAKING LADDER PROGRAMS" ●To use system macros
(4) "Chapter 5 PROGRAMMING TIPS"
(2) "Chapter 3 REDUCING PROGRAMMING
●How to use modules MAN-HOURS - Creating Original Instructions (macros)"
(2) "Chapter 3 REDUCING PROGRAMMING (4) "Chapter 3 USING MACROS"
MAN-HOURS − Converting to parts for re-use (module)" (7) (System Macro Manual)
(4) "Chapter 2 USING MODULES"
●What is "KV script?
(8) "1-1 What Is KV Script?"
●What is a "local device?"
(2) "Chapter 3 REDUCING PROGRAMMING
MAN-HOURS - About Local Devices" ●Specifications and how to use script functions
(4) "Chapter 4 LOCAL DEVICES" (9) (Script Function Reference Manual)

● How to install KV STUDIO


(1) "Installing KV STUDIO"

KV S
TUDIO

● To check operation of ladder programs


on only a PC (simulator function)
(2) "Chapter 2 MAKING LADDER PROGRAMS
● How to operate KV STUDIO
−Checking Program Operation without a PLC"
(5) "KV STUDIO User's Manual"
(4) "5-5 How to Proceed with Debugging"

● How to install the USB driver


● To check operation of ladder programs (1) "Installing the USB Driver"
(monitor function) (5) "1-5 Installing the USB Driver"
(2) "Chapter 2 MAKING LADDER PROGRAMS
−Checking Operation of the Ladder Program"
(4) "5-5 How to Proceed with Debugging"

3
For safe usage
■ This manual's format
This manual uses the following symbols to alert you to important information.

DANGER Failure to follow these instructions may lead to death or serious injury.

WARNING Failure to follow these instructions may lead to injury.

CAUTION Failure to follow these instructions may lead to physical damage (product
malfunction, etc.).

Important
This heading is used to indicate precautions and restrictions that must be fol-
lowed when operating the product.

Note
This heading is used to indicate cautions relating to device operation where
operator error is likely.

Tip Indicates useful information or information that aids understanding of text descriptions.

Indicates a reference item or page to be referred to in this manual and a separate manual.

■ General Precautions
• Verify that this device is operating normally in terms of functionality and performance before the
start of work and when operating the device.
• Provide a safety circuit that does not pass via the programmable controller to enable failsafe
operation of the entire system in the event that the programmable controller fails.
• Output circuit or internal circuit malfunctions sometimes prevent control from being performed
normally. Be sure to provide a safety circuit in control systems where circuit malfunction may
lead to fire or other serious accidents.
• Proceed with care when modifying the KV-1000/700 Series, or when using it in a manner that
falls outside of the ranges indicated in its specifications, since KEYENCE is unable to guaran-
tee device functionality or performance in such situations.
• Use this product in combination with other devices only after careful consideration, since the
KV-1000/700 Series may fail to satisfy its functionality and performance capabilities as a result
of the conditions and environment in which it is used.
• Do not use the KV-1000/700 Series with the purpose of protecting human beings.
• Verify that the KV-1000 is operating normally when operating the KV STUDIO.

4
Conventions Used In This Manual
The following shows how pages in this manual are configured, and the symbols and terminology
used in this manual.

Page Configuration and Symbols

Setting up Units (Unit Editor)


Mid-heading
Indicates the content that
follows after a section is Setting up Units (Unit Editor) Headline
broken down into smaller Before a ladder program is executed, the units to add on to the KV-1000 must be registered. Indicates the
units. main content
Initial setup of the unit configuration
of the chapter.
Thumbnail index 2
Indicates the chapter. 1 Display the Unit Editor screen.
Select {Tool(T)}→ {Unit Editor(U)} from the menu. Operational step
MAKING A LADDER PROGRAM

Different Procedure Click the icon on the tool bar.


Chapter title

Different procedure
Important information
This is used to indicate
Screen precautions and restrictions
Important
that must be followed when
Before you start this operation, connect the PC to the KV-1000 and enable
operating the product.
communications.
Be sure to read these.
Name of product
Note
First set the unit configuration. Error may occur when you transfer the program Notes:
to PLC if you do not set the unit configuration.
Indicates the page or Describes cautions for
manual to refer to. Tip When you connect by USB for the first time, the USB driver must be installed on the PC.
easily mistaken operations.
The page or manual "KV-1000 Device Configuration" (page 1-14) Be sure to read these.
containing the related Column
information is indicated Deleting units
here. Click to select the unit to delete. Tip
A selected unit is displayed surrounded by a red frame. Press to delete the unit.
Delete
Indicates useful information
Column for reading
or information that aids
at your leisure. Introduces May be deleted
by right-clicking.
understanding
information worth
of text descriptions.
knowing. Also contains
information hints.

2-16

* This page was made for the purpose of explaining page components, and differs from an actual page.

Terminology

This manual uses the following terminology excluding some instances.


Term Explanation
KV-1000 Programmable Controller made by Keyence Corporation
CPU Unit Programmable Controller KV-1000 Series made by Keyence Corporation
This refers to the Expansion Input Unit, Expansion Output Unit, and Expansion
Expansion Unit
Special Unit other than the CPU Unit in the KV-1000 Series.
This refers to the software that supports the creation of the programs of the KV-
KV STUDIO
1000 Series.
Ladder program Program made by using the KV STUDIO
Overall term for a programmable controller system configured by attaching
PLC
respective units to the CPU Unit. Indicates the overall system.
Stands for personal computer. Generally, this refers to an IBM PC or a PC/AT
PC
compatible machine (DOS/V).

5
Contents
Preface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
Brief description of the reference manuals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
For safe usage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
Conventions Used In This Manual . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
Contents . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

Chapter 1 ABOUT THE KV-1000

About the KV-1000. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-2


What Is a Programmable Controller? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1-2
PLC functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1-4
Making a program on a PLC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1-6
Advantages of PLCs. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1-7
KV-1000 Functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-8
Programming using ladder language . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1-9
Amazing real-time operation can be achieved by a newly developed high-speed CPU. . 1-10
Memory equivalent to an ultra-large capacity of 160 k steps mounted as standard. .1-10
Multi-function I/O 24 (16 inputs/8 outputs) provided as standard . . . . . . . . . . . . . . . . 1-11
Memory Card slot (MMC/SD Memory Card) provided as standard . . . . . . . . . . . . . . 1-11
Split programming (modules) supported . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1-12
Making original instructions (macros). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1-12
Typical examples of KV-1000 Series functions and expandability . . . . . . . . . . . . . . .1-13
KV-1000 Device Configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-14
Bit devices . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1-14
Word devices . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1-15

Chapter 2 MAKING A LADDER PROGRAM

What Is a Ladder Program? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-2


KV STUDIO Functions. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-6
Flow of Work for Making a Program . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-7
Making Projects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-12
Starting up KV STUDIO . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2-12
Making projects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2-13
Setting up Units (Unit Editor) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-16
Initial setup of the unit configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2-16
Other functions of Unit Editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2-21
Making a Ladder Program (Ladder Editor) . . . . . . . . . . . . . . . . . . . . . . . . . 2-22
Checking Operation of the Ladder Program (monitor) . . . . . . . . . . . . . . . 2-38
Before writing ladder programs to a PLC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2-38
Writing programs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2-39
Monitoring programs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2-43
Turning bit devices ON/OFF. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2-45
Registration Monitor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2-46
About the [Change device values] window. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2-52

6
Checking Program Operation without a PLC (simulator) . . . . . . . . . . . . . 2-53
Starting up Simulator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2-53
How to use Simulator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2-54
Setting break conditions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2-56

Chapter 3 REDUCING PROGRAMMING MAN-HOURS

Turning Specific Sections of Programs into Parts for Re-use (modules) . . . 3-2
Types of modules on KV STUDIO . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-6
Making a project using an every-scan module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-7
Making a project by using standby modules together with every-scan modules . . . . .3-8
Procedure for Using Modules . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-10
Sample program using modules. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-25
About Local Devices . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-26
How to use local devices . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-26
Reasons for using local devices. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-28
Making Original Instructions (macros) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-30
When macros are used . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-32
Macros use arguments. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-34
Types of macros . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-35
Procedure for Using Macros . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-38

APPENDICES

1 KV-1000 Error Message Lists . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . A-2


PLC Unit Errors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . A-2
2 Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . A-5

7
Introducing the Characters

Mr. I, relatively new


8 months in the company
A complete beginner when it
comes to PLCs
This time, he is to make a
program for the KV-1000 with
Mr. T's guidance.

Mr. T, experienced engineer


9 years in the company
Reliable coach and adviser for
Mr. I
Knows all there is to know
about the KV-1000.

Ms. Y of Engineering Sales


5 years in the company
Quite knowledgeable about
programmable controllers

8
1 ABOUT THE KV-1000
About the KV-1000. . . . . . . . . . . . . . . . . . . . . . 1-2
KV-1000 Functions . . . . . . . . . . . . . . . . . . . . . 1-8
KV-1000 Device Configuration. . . . . . . . . . . . 1-14

1-1
About the KV-1000

About the KV-1000


1
What Is a Programmable Controller?
●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●
ABOUT THE KV-1000

Conventional sequence programs comprise control circuits by combining relays, timers, and other
parts.
For this reason, when complex control is performed, the number of required parts increases, and
a large amount of space is required.
Programmable controllers have a built-in microcomputer that runs at high-speed in place of
numerous relays and timers, and are devices dedicated to sequence control that have been
developed for the purpose of reducing the space occupied by control devices.
Programmable controllers, as typified by the KV-1000, are called PLCs (an abbreviation of
Programmable Logic Controllers).

KV-1000

Sequence control without a PLC Sequence control with a PLC

· Enormous amount of part · Fewer part


· Bulky, complicated wiring · Clean wiring layouts
· Delayed operation caused by relay · High-speed operation
operation time · Greatly reduced frequency of
· Periodic maintenance inside control maintenance in control panels
panel caused by deterioration of · Compact control panel
parts
· Enormous control panel that takes
up unnecessary installation space

1-2
About the KV-1000

Column 1

ABOUT THE KV-1000


What is "sequence control?"

Successively proceeding with various operations in accordance with a predetermined


order is called "sequence control."
With sequence control, the various operations when machines and devices are used, and
their order of operation and execution conditions are stored in advance to the control
device (controller). By doing this, the series of target operations such as "start" ←→ "stop" or
"open" ←→ "close" can be performed according to the state or condition of the machine or
device to be controlled.

Let's take a look at an actual example of sequence control of how a fully automatic
washing machine works.

Actual example of sequence control

(1) Switch ON (2) Water supply (3) Wash (4) Drain (5) Spin

End

(6) Water supply (7) Rinse (8) Drain (9) Spin (10) Notification

In this way, if you follow operation of the washing machine in order,


you can tell that it is automatically controlled according to a
predetermined order.
The KV-1000 is used as the controller for performing sequence
control.

1-3
About the KV-1000

PLC functions
●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●
1 PLCs can be downsized, something which was not possible with conventional relay sequence
control.
ABOUT THE KV-1000

Moreover, logical operation processing, communications control, motor control, temperature


control, and other functions, that were not possible up till now without the aid of a PC or a
dedicated device, can now be batch-controlled on just a PLC.
Dedicated tools and instructions are provided on the KV-1000 so that these various functions can
be easily programmed.
Without a PLC

· Exclusive control devices


are required for each unit.
· Batch-management of data is
difficult.

When using a KV-1000

· Batch control by KV-1000


· Batch management of data
possible

KV-1000

1-4
About the KV-1000

Column
1

ABOUT THE KV-1000


Types of sequence control

Basic sequence control is divided mainly into three types: "sequence control," "condition
control" and "time limit control." Design the target control circuit by a combination of these
control types.

● Sequence control
Sequence control is the most basic of control types. With sequence control, the following
operation is started in a predetermined order when the previous fixed operation ends.

Supply predetermined Start washing when water


amount of water. supply ends.

● Condition control
With condition control, an operation is performed when specific conditions are satisfied by
combining various information and signals.

"Click"

Spin started if lid is closed Spin stopped when lid is opened

● Time limit control


With time limit control, timers or similar counting devices are used, and the next operation
is performed when a fixed time has elapsed.

Spin for fixed period of time Spin time end, spin stopped

1-5
About the KV-1000

Making a program on a PLC


●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●
1 Up till now, sequence control involved making a control circuit by drawing a sequence control
circuit diagram and actually wiring relays and timers. Though complicated operation is possible
ABOUT THE KV-1000

with sequence control using relays and timers, the only means for changing operation was to add
parts or re-wire.

With a PLC, however, you can create the ladder program on a PC instead of having to actually
draw a sequence control circuit diagram. As PLCs run according to this ladder program, the
intended operation can be achieved merely by rewriting the ladder program, and physically
adding on parts or rewiring in a control panel is not required.

Easy programming
on KV STUDIO

Change in operation when you do Change in operation when you have


not have a PLC a PLC

· Correct the sequence control · Correct ladder program


circuit diagram · Check operation
· Study layout of additional parts
(relays, timers, etc.)
and purchase parts
· Change wiring
· Check operation

1-6
About the KV-1000

Advantages of PLCs
●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●

Item Relay Control PLC (KV-1000) based Control


1
Details of Basically, this is only ON/OFF control. Details Not only ON/OFF control but also more
Control of control are restricted by the number of complicated control such as operations on

ABOUT THE KV-1000


relays used. analog data and positioning control using
motors are possible.
Control panel Lots of installation space is required as the Only several relays are required as a
size number of relays that are used increases microcomputer is used. A compact control
proportionately to the scale of control. panel is sufficient as the enclosure also is
ultra-compact.
Cost Cost increases proportionately to the No extra costs are incurred even with complex
complexity of control. Works expenses are control as long as control is within the program
also incurred due to periodic maintenance. size. Periodic maintenance is required about
once every five years when run under normal
room temperature conditions.
Design/ Both many drawings and assembly man- Setup is completed by programming and
manufacturer hours are required. The required number of transfer of the ladder program to the PLC.
man-hours man-hours also increases due to operation Man-hours required for testing can be
tests. drastically reduced by using the Simulator
function.
Expandability Relays must be added on to expand the scope The scope of control can be expanded
of control. Control can be expanded only merely by correcting the program as long as
within a predetermined scope as relays control is within the program size. Also,
beyond the limited space inside the control merely by adding on one ultra-compact PLC
panel cannot be added on. has the same effect as adding on several
10,000s of relays.
Applicability Relay control cannot be used (re-used) for Ladder programs can be re-used for all kinds
other devices as the control panel is of devices by reworking the ladder program.
(basically) for exclusive use.
Reliability/life The life of contacts must be taken into Long-life as semiconductor devices are
consideration when contact relays are used. used. Highly reliable.
Reliability is not very high (compared with
semiconductor devices) as the structure is
mechanically based.
Maintainability Periodic replacement of relays and serviced parts For periodic maintenance, only replacement
cannot be avoided. of the backup battery about once every five
years is required when run under normal
room temperature conditions.

1-7
KV-1000 Functions

KV-1000 Functions
1 The KV-1000 is a high-performance, advanced and highly expandable PLC.
If you further your understanding of the KV-1000, you will find that you can use it efficiently for
ABOUT THE KV-1000

control in a wide number of situations.

Speed Programming language Internal memory


Exclusive ultra high-speed Expanded ladder that allows Large capacity
chip newly developed! multiple instructions Approx. 160k steps can
Capable of processing 30k-step to be programmed in one rung. be mounted as standard.
ladder programs *in about 1 ms.
* Differs according to conditions.

State display
Access window
allows you to
immediately
tell the state of I/O
units and devices.
Multi-function
(16 inputs, 8 outputs)

Memory Card
MMC/SD Memory
Card supported

RS-232C port USB-based Expandability


handy for connecting high-speed Extensive line-up of
a touch panel communications Expansion Units
that enable various control.
Communications interface

1-8
KV-1000 Functions

Programming using ladder language


●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●

With PLCs, sequence circuits that control output of lamps, etc. can be replaced with a ladder
1
program.

ABOUT THE KV-1000


You want to turn a lamp ON a fixed time after the switch turns ON...

OFF ON

Then, you want to also turn the lamp


OFF a short while after
the switch is turned OFF!
Also, you want to...

But, then, it's tough wiring


all those relays.
What's more, you'll need a bigger box
for housing all those relay circuits.

With switches and lamps


you can achieve
various operations
on the KV-1000
merely by programming.

1-9
KV-1000 Functions

Amazing real-time operation can be achieved by a newly developed


high-speed CPU.
1 ●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●

The KV-1000 incorporates a newly developed dedicated high-speed chip that optimizes data
ABOUT THE KV-1000

processing on the PLC.


This enables even ladder programs of about 30k steps to be executed in only 1 ms*.

Conventional PLC

KV-1000

* Differs according to conditions.

Memory equivalent to an ultra-large capacity of 160 k steps mounted


as standard
●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●

Large-capacity, high-speed memory used as standard on PCs is used to achieve a standard


program capacity of about 160 k steps.

Program

Program
Conventional PLC KV-1000

1-10
KV-1000 Functions

Multi-function I/O 24 (16 inputs/8 outputs) provided as standard


●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●

The KV-1000 is provided with regular I/O devices as standard.


1
Multi-function I/O can be used as interrupt input, high-speed counters, and pulse oscillation to

ABOUT THE KV-1000


enable a variety of control such as motor control on just the KV-1000.

Multi-function I/O

KV-1000 Series User's Manual

Memory Card slot (MMC/SD Memory Card) provided as standard


●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●

The KV-1000 is provided with a Memory Card slot as standard. Use of the MMC and SD Memory
Card slot expands the number of applications of the PLC as indicated below.

• Saving/reading of ladder programs


• Reading/writing of data by dedicated instructions
• Large-capacity logging function

KV-1000 Series User's Manual

1-11
KV-1000 Functions

Split programming (modules) supported


●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●
1 On the KV-1000, "split programming" that allows control programs to be split up and programs
designed by individual process or function is possible.
ABOUT THE KV-1000

By splitting up programs and turning split up programs into independent sections (modules),
programming can be distributed between two or more programmers, and programs turned into
modules on other projects can be re-used. This frees you from the conventional "1 project, 1
programmer, 1 program" approach.

[abnormality processing]

[automatic operation]
[manual operation]

[automatic operation]

[manual operation]
[initialization processing]

Conventional program Program using KV-1000

For details on modules, "Turning Specific Sections of Programs into Parts for Re-use (modules)" (page 3-2).

Making original instructions (macros)


●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●

On the KV-1000, frequently used ladder network blocks can be registered as macros. Registers
macros can be used countless times like instructions.
If you register networks that are frequently used repeatedly as macros, debugging can be made
easier as the man-hours required for programming reduced, and ladder programs can be made
as visually easy to understand.

[module A]

[module A]

[macro 1]
Macro 1

Macro 1

Registering frequently
used ladders
Program using macros

Conventional program

For details on macros, "Making Original Instructions (macros)" (page 3-30).

1-12
KV-1000 Functions

Typical examples of KV-1000 Series functions and expandability


●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●
1

ABOUT THE KV-1000


Functions achieved by adding
Functions built into the CPU Unit
on Expansion Units
zMotor control functions zAnalog control function
Pulse motors on 2 axes can be controlled. Measurement data from displacement sensors,
etc. can be captured in real time by maximum
speed 80 µs analog control.

KV-AD40
Displacement sensor

zLogging function Pressure sensor


The Memory Card slot built into the CPU Flow meter
Unit can be used to log data to Memory Card.

zSerial communications function


Devices (e.g. image sensors) that support a
serial communications interface can be
connected to a touch panel.
zCam switch function KV-L20R
Connecting an encoder allows the
CPU Unit to be used as a cam switch.

1-13
KV-1000 Device Configuration

KV-1000 Device Configuration


1 A "device" is memory that runs on the program instead of actual relays, timers, etc. internally on
KV-1000. Devices are distinguished by several functions and size.
ABOUT THE KV-1000

Bit devices
●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●

Bit devices can express two states, for example, "switch ON"←→"switch OFF", or "condition
established (TRUE)"←→"condition not established (FALSE)."
So that actual switches are individually distinguished, respective bit devices on the PLC are
assigned individually different Nos. and are handled as independent devices.

Timer has not


The switch reached the preset time (OFF)
is ON or
or has reached the preset time (ON).
not ON (OFF).
OFF ON
The lamp
is lit (ON)
or
is out (OFF).

● Types of bit devices


Device Name Main Functions Number of Points Range
Device for capturing information from
Input relays Total of 9536
switches or sensors
input and output R00000 to R59915
Device for exporting information to lamps, relays
Output relays
buzzers, etc.
Internal
Devices that function only on the program 16000 MR00000 to MR99915
auxiliary relays
Devices that memorize ON/OFF states
Latch relays when the power is turned OFF or when the 16000 LR00000 to LR99915
operation mode is switched
Devices whose timer contact is
Timers
decremented from the preset value and T0000 to T3999
(contacts)
that turn ON when they reach "0" Total of 4000
Devices whose counter contact is timers/counters
Counters
incremented from "0" and that turn ON C0000 to C3999
(contacts)
when they reach the preset value
High-speed
counters Devices that turn ON when the value of the
4 CTC0 to CTC3
Comparators high-speed counter matches a preset value
(contact)
Control Devices for controlling PLC functions and
640 CR0000 to CR3915
relays for learning states

For details on bit devices, KV-1000 Series Programming Manual "1-4 Devices and Constants".

1-14
KV-1000 Device Configuration

Word devices
●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●●

Whereas bit devices can only express ON and OFF states, word devices can handle numerical
1
values (constants) and text strings as data.

ABOUT THE KV-1000


By handling numerical values (constants), various numerical value operations and timer/counter
setting values can be controlled.
Word devices can be broadly classified into 16-bit device types and 32-bit types, each with a
differing range of values that can be handled.

T/C/CTH/CTC

DM/EM/FM/TM/Z/CM

32 bits
16 bits

Range of values Range of values that can be handled


that can be handled
· 0 to 4294967295
· 0 to 65535 · -2147483648 to +2147483647
· -32768 to +32767 · Floating real number

● Types of word devices


Device Name Main Functions Number of Points Range
Device that can store number data internally
Data memory 65535 DM00000 to DM65534
on the PLC (processing in 16-bit units)
Devices that can be handled in the same 65535 EM00000 to EM65534
Expanded
way as data memories (processing in 16-bit
data memory 32767 FM00000 to FM32766
units)
Temporary Devices that are used for temporarily storing
512 TM000 to TM511
data memory operation results, etc.
Timers Current value/setting value of subtraction
(current value/ timers and up/down timers (processing in T0000 to T3999
setting value) 32-bit units) Total of 4000
Counters Current value/setting value of addition timers timers/counters
(current value/ and up/down counters (processing in 32-bit C0000 to C3999
setting value) units)
High-speed
counter Current value of high-speed counter 2 CTH0 to CTH1
comparators
Index register Devices used in index modify 12 Z01 to Z12
Control Devices for controlling PLC functions and for
11999 CM00000 to CM11998
memory learning states

For details on word devices, KV-1000 Series Programming Manual "1-4 Devices and Constants."

1-15
KV-1000 Device Configuration

1
ABOUT THE KV-1000

1-16
2 MAKING A LADDER PROGRAM
What Is a Ladder Program?. . . . . . . . . . . . . . . 2-2
KV STUDIO Functions . . . . . . . . . . . . . . . . . . . 2-6
Flow of Work for Making a Program . . . . . . . . 2-7
Making Projects . . . . . . . . . . . . . . . . . . . . . . . 2-12
Setting up Units (Unit Editor) . . . . . . . . . . . . . 2-16
Making a Ladder Program (Ladder Editor) . . 2-22
Checking Operation of the Ladder Program (monitor) 2-38
Checking Program Operation without a PLC (simulator) 2-53

2-1
What Is a Ladder Program?

What Is a Ladder Program?


A "ladder network" is a graphical representation of an actual wiring diagram, and ladder networks
drawn in KV STUDIO are called "ladder programs."

Batteries, switches and lamps are drawn in actual wiring diagrams. Simple wiring diagrams are also
2 easy-to-understand.

Actual wiring diagram


MAKING A LADDER PROGRAM

OFF ON

When the number of parts increases in easy-to-understand actual wiring diagrams with few parts,
these parts are left on the drawing, and make the wiring diagram more difficult to understand. It is
really hard to draw actual diagrams with complex parts.

Actual wiring diagram

Power supply

OFF ON
The circuit of an actual
wiring diagram is easy
Lamp A
to understand, but it's
Switch 1
difficult to make the
drawing.
OFF ON

Switch 2

OFF ON

Switch 3 Buzzer

In actual fact, switches can include sensors and limit switches, and lamps can include solenoid
valves and motors.
2-2
What Is a Ladder Program?

This is why sequence diagrams with symbolical representations of lamps and switches were
conceived. A sequence diagram that expresses parts using symbols is called a "ladder network."

Sequence diagram

This section is omitted.

In this diagram,
2
parts are turned
into symbols,

MAKING A LADDER PROGRAM


so the circuit is the
same whoever
looks at it.
Switch Lamp

On KV STUDIO, the symbols that are used in ladder networks that are created are referred to
simply as "symbols." Switch, lamps, etc. are called "devices." Also, the entire ladder network that
is created is called a "ladder program."
Ladder program

So ladder networks
MR01000 MR02500 drawn on KV STUDIO
are "ladder
MR01001 programs!"

MR01002 MR02501

END

ENDH

MR01000 and MR02501 in the illustration are devices (parts) that are expressed on the PLC.
"KV-1000 Device Configuration" (page 1-14)

2-3
What Is a Ladder Program?

● Scanning ladder programs


KV-1000 repeatedly executes created ladder programs as follows.

The ON/OFF states of all input terminals are


Input processing
read before the program is executed.

2
Scan
MAKING A LADDER PROGRAM

Various processing and calculations are performed


Program execution
according to the details written to the program.

The results of program execution


Output processing are output from the output
terminals.

The flow of operations from input processing through to output processing is called a "scan."
This scan is repeatedly executed on ladder programs.

● Scan time
The time required to perform a single scan (execution of the string of processes from input
processing through to output processing) is called the "scan time."
Output processing

Input processing

Program execution

Output processing

Input processing

Program execution

Output processing

Input processing

Program execution

Output processing

Input processing

Scan time Scan time Scan time

Though the scan time changes according to the size of the program and type of instructions used
in the program, you should bear in mind that the longer (more complex) a ladder program is, the
longer the scan time will become.

Note
When a ladder program contains lots of programmed instructions that take time
to process, the scan time sometimes exceeds the allowable range of the KV-
1000. In this case, the "Scan time over" error is generated, and the ladder
program can no longer be executed.
KV-1000 Series Programming Manual "1-3 Projects"

2-4
What Is a Ladder Program?

Column

Why is a short scan time better?


Ladder programs process input processing at the beginning of a scan and output processing
at the end of a scan. For this reason, when the scan time becomes longer, it takes more time
to process the data (ON/OFF states of sensors and switches, numerical values such as 2
pressure or temperature) obtained by input processing and output the result.
The shorter the scan time becomes, the more accurate processing becomes possible as

MAKING A LADDER PROGRAM


the PLC's response (processing time from input through to output) improves.
When scan time = 100 ms When scan time = 10 ms
Value Value
100 times measurement 1000 times measurement

0 0
10 Secs 10 Secs

In the case of programs that capture data once per scan:


When analog data, etc. is measured for ten seconds,
data can be measured only 100 times
when the scan time is 100 ms.
Setting a short scan time allows data to be measured closer
to real time.

To shorten the scan time


In the series of processes included in a single scan, the processing time can be shortened
only in "program execution" sections of the ladder programs. The response time in input
processing and output processing is determined by the number and type of add-on units.
Let's shorten the processing time of ladder programs by the following procedure.
• Set so that only the required programs are executed at all times by a program
using modules/macros.
• Try to use only exclusive commands to make the entire program compact.
• Try not to use instructions such as FOR to NEXT that are processed countless
times in a scan.
Cannot be shorted. Cannot be shorted.
(dependent on system configuration) (dependent on system configuration)
Can be shortened.

Out- In- Out- In-


Program put put Program put put Program
execution proc- proc- execution proc- proc- execution
ssing ssing ssing ssing

Scan time Scan time Scan time

2-5
KV STUDIO Functions

KV STUDIO Functions
KV STUDIO is software for making ladder programs.
KV STUDIO is very user-friendly and is provided with outstanding programming capabilities.

● Simple mouse operation improves programming efficiency


2 KV STUDIO can be easily operated using a mouse. Highly efficient programming is possible as
various functions can be called from the tool bar by simple one-touch operation.
MAKING A LADDER PROGRAM

Tool bar

Work
space

Ladder edit window

● All functions (editing, setup, monitoring debugging, creation of spec sheets,


etc.) integrated
All kinds of software tools are integrated into KV STUDIO to help you build your PLC system.
All of these software tools can be started up from within KV STUDIO, which improves
programming efficiency.
KV STUDIO User's Manual "1-2 Outline of KV STUDIO"

Tip • In the workspace, you can manage modules/


macros and set up units to be used in projects. Oh, I see...
"Turning Specific Sections of Programs into Parts for
Re-use (modules)" (page 3-2)
"Making Original Instructions (macros)" (page 3-30)

2-6
Flow of Work for Making a Program

Flow of Work for Making a Program


KV STUDIO has four main functions: Unit Editor, Ladder Editor, Monitor and Simulator.
• Unit Editor
Sets the unit configuration.

MAKING A LADDER PROGRAM


• Ladder Editor
Makes ladder programs.

• Monitor
Connects to KV-1000 to allow to you to monitor the operating state of ladder programs.

Debugging in progress

• Simulator
Allows to you to simulate the operating state of ladder programs without actually connecting to KV-
1000.

Debugging in progress
Not needed
KV-1000

2-7
Flow of Work for Making a Program

The following describes the procedure for making a new project on KV


STUDIO.

Start up KV
STUDIO. 1 Start up KV STUDIO.

Double-click the icon on desktop.


2
Tip • If the icon is not on the desktop, install KV STUDIO.
KV STUDIO/KV BUILDER Installation Manual
MAKING A LADDER PROGRAM

Create a project.
2 Make a new project. (* For details, see "Making Projects" (page 2-
12).)
• Click the icon on the tool bar.

Click

Set the unit


configuration?

Set the unit


configuration on
Unit Editor.

• Select {File(F)}→{New project(N)} from the menu.

3 Enter the required information in the [New project] dialog box.


Make a (1) Enter the project name. (mandatory)
program on (2) Enter the comment for the project. (not mandatory)
Ladder Editor.

(1)

Check operation
of the program using
Monitor functions. (2)

(3)

Check operation (3) When you have finished entering the items, click the "OK" button.
of the program
using Simulator
functions. Tip • Limit the project name to 32 1-byte characters (or 16 2-byte
characters). For details of characters that cannot be used and
other restrictions, refer to KV STUDIO User's Manual "2-1
Managing Projects."

2-8
Flow of Work for Making a Program

4 Proceed to the unit confirmation setup screen (Unit Editor).


The unit configuration setup confirmation window is displayed. Click the
"Yes" button.
Start up KV
STUDIO.

MAKING A LADDER PROGRAM


Create a project.
Tip • If you select the "No" button at this time, the screen does not
advance to Unit Editor, and the [Ladder edit] window stays
displayed as it is.
• The unit configuration can also be set later. Set the unit
configuration after specifications are finally determined, for
example, when the units to be used are not yet decided upon,
Set the unit
or when units are to be added on. configuration?

5 Change the unit configuration setup. (* For details, see "Setting up


Units (Unit Editor)" (page 2-16).)
Select the [Unit selection] tab on the right of the screen, and drag-and-
drop the units to be used to link them to the CPU (KV-1000) on screen. Set the unit
configuration on
Unit selection tab Unit Editor.

Make a
program on
Ladder Editor.

Check operation
of the program using
Monitor functions.

In the default state, CPU


(KV-1000) and end unit only

Check operation
of the program
using Simulator
functions.

2-9
Flow of Work for Making a Program

Start up KV
STUDIO.

2
MAKING A LADDER PROGRAM

Create a project.

Drag the unit, and drop it


at the location to couple.
Set the unit
configuration?

• When you have finished setting up the units, select {File(F)}→{Save(S)}.

Set the unit


configuration on
Unit Editor. Saves the unit setup
before the program is
exited.

Make a 6 Make the program. (* For details, see "Making a Ladder Program
program on (Ladder Editor)" (page 2-22).)
Ladder Editor.
After exiting Unit Editor, the following screen will be displayed.
Write the ladder program in the [Ladder edit] window.

Check operation
of the program using
Monitor functions.

Check operation
of the program Ladder edit window
using Simulator
functions.

2-10
Flow of Work for Making a Program

7 Use Monitor functions to confirm program operation. (* For details,


see "Checking Operation of the Ladder Program (monitor)" (page 2-
38).)
Start up KV
When you have finished making the ladder program, transfer it to KV- STUDIO.
1000.

MAKING A LADDER PROGRAM


Create a project.

Set the unit


Note configuration?
When the Monitor function is used for the first time, the PC
must be correctly connected to the KV-1000. For details,
refer to the KV STUDIO/KV BUILDER Installation Manual.

Set the unit


The Monitor screen is displayed when the program has been successfully
configuration on
converted and transferred to the KV-1000. Confirm operation of the ladder Unit Editor.
program.

8 Use Simulator functions to confirm program operation. (* For details,


see "Checking Program Operation without a PLC (simulator)" (page 2-
53).)
If you use Simulator functions, you can confirm operation of the ladder Make a
program on
program even if the PC is not connected to the KV-1000. Ladder Editor.

Check operation
of the program using
Monitor functions.

Check operation
of the program
using Simulator
functions.

The Simulator screen is displayed when the program is successfully


converted. Confirm operation of the ladder program.
2-11
Making Projects

Making Projects
The ladder integration software KV STUDIO is used on the KV-1000 Series. Let's start up KV
STUDIO and try making a project.

Starting up KV STUDIO
2
1 Double-click the icon on the desktop to start up KV STUDIO.
MAKING A LADDER PROGRAM

Startup
title screen

2 The startup title screen is displayed, followed by the initial screen.

Initial screen

2-12
Making Projects

Making projects

A "project" is a unit for managing a ladder program, unit setup information, comments, and other
information as a single entity.

1 Click the icon on the tool bar in the initial screen.


2

MAKING A LADDER PROGRAM


Different Procedure Select {File(F)}→{New project(N)} from the menu to make a new project.

Select from the menu bar.

Tip • You can also open already made projects.


• Either click the icon on the tool bar, or select {File(F)}→{Open project(O)} from the
menu.

2-13
Making Projects

2 The [New project] dialog box is displayed. Enter the information of the project to be made.

Enter the name of the project to save.


Can be written using either of 1-byte or 2-byte characters.
Be sure to enter.

2
MAKING A LADDER PROGRAM

Determine the directory


where the project is to be
stored.
Change the directory if you
want to save to a directory
other than the default
directory.
A folder of the same name
as the project is created
at the specified directory.

Write comments to the project you are to create.


No problem if not entered

3 When you have finished all of the information, click the "OK" button.
The following window is displayed.

• When the units to add on to the PLC to be used are already decided
upon, click the "Yes" button.
When Unit Editor is started up, set up the unit confirmation to be used.
(* For details, see "Setting up Units (Unit Editor)" (page 2-16).)
• When the units to add on to the PLC to be used are not yet decided
upon, click the "No" button. (The unit confirmation can be set up later.)

Tip • Try to set up the unit configuration in advance as device Nos.


may be duplicated.
• If the unit confirmation is not set up, an error will occur when the program is transferred
to the PLC.

2-14
Making Projects

4 The new project is made.


The ladder can now be programmed when this screen appears.

MAKING A LADDER PROGRAM


Column

Saving projects
Save the project you have made or edited.
Click the icon on the tool bar.

2-15
Setting up Units (Unit Editor)

Setting up Units (Unit Editor)


Before a ladder program is executed, the units to add on to the KV-1000 must be registered.
Units can be easily set up by using Unit Editor on KV STUDIO. After you have configured your
system, you can change settings without having to remove units.

2 Initial setup of the unit configuration


MAKING A LADDER PROGRAM

1 Display the Unit Editor screen.


Select {Tool(T)}→{Unit Editor(U)} from the menu.

Different Procedure Click the icon on the tool bar.

Unit Editor opens. [Unit configuration] tab


[Unit selection] tab
[Unit setup] tab

Unit placement area

Message area

2-16
Setting up Units (Unit Editor)

2 Adding units
Arrange the units that are to be actually used in a project.
Select the [Unit selection] tab, and drag-and-drop the required units to link them to the CPU.

Different Procedure Double-click the required units.

Unit selection tab 2

MAKING A LADDER PROGRAM


Drag-and-drop

Column
Deleting units
Click to select the unit to delete.
A selected unit is displayed surrounded by a red frame. Press Delete to delete the unit.

May be deleted
by right-clicking.

Press Delete .

2-17
Setting up Units (Unit Editor)

3 Set relay/DM assignments.


● When assigning relays/DMs automatically
When you have determined which units are to be registered, assign relay/DM Nos.
Select {Conv(P)}→{Auto relay/DM(A)} from the menu.

2
MAKING A LADDER PROGRAM

Different Procedure Click the icon on the tool bar.

The auto-assign confirmation message box is displayed. Click the "OK" button.

The relay/DM No. is automatically assigned, and the result is displayed in the message area.

Relay/DM Nos. are


no assigned.

Auto-assign relay/DM

R30000 to R30315
were assigned to the
Input Unit, and
R30400 to R30715
were assigned to the
Output Unit.

2-18
Setting up Units (Unit Editor)

● When assigning relays/DMs manually


Double-click the unit to set assignments to on the unit placement area. The [Unit setup] tab
automatically opens.

Double-click the unit to set up. Unit setup tab

MAKING A LADDER PROGRAM


Click the letters [Need set], and enter the leading No. to assign in individual channels. (In this
example, enter "200".)
After entering, the display for the unit in the unit placement area changes from [Need set - Need
set] to [20000-20315].

Before setting After setting

2-19
Setting up Units (Unit Editor)

4 Save the unit setup before exiting the program.


When you have finished assigning relays/DMs, save the settings, and exit Unit Editor.
Select {File(F)}→{Save(S)} from the menu.

Different Procedure Click the icon on the tool bar.

2
MAKING A LADDER PROGRAM

Saves the unit setup information you have


made and returns to the main window.

The items set up


on Unit Editor are
displayed.

Column
I/O relay Nos. can be set within the range R01000 to R59915, and data memory Nos. can be
set within the range DM00000 to DM65534.
In the default setting, relay Nos. are batch-assigned in order from R30000(300ch), and DM
Nos. are batch-assigned in order from DM10000. You can also divide up relay Nos. for
input, output and special units, and assign Nos. individually to each of them.

Setting can be changed to


relay No. R10000 to R10115.

2-20
Setting up Units (Unit Editor)

Other functions of Unit Editor

The following describes functions other than unit configuration and unit setup.

● Building/setting up a KL system
KL Link Systems using the KL Master Unit "KL-N20V" for the KV-1000 can be set on Unit Editor.
2

MAKING A LADDER PROGRAM


Switch setup used to be difficult. The settings on the Master Unit side
can be transferred as they are on Unit Editor.

● Printing system configuration diagrams


Printed out system configuration diagrams are useful for making spec sheets as all of the system
information (e.g. connected unit configuration diagrams, unit setups, relay assignments by
individual unit) set on Unit Editor can be printed.
The following details can be printed out.

• Connected unit configuration diagrams


Illustrations of units and relay assignments can be printed.

• Connected unit details setup lists


The setups of each unit can be printed in tabular format.

• KL system configurations print


Illustrations of KL system configurations, and relay/address assignment tables for each unit can
be printed.

2-21
Making a Ladder Program (Ladder Editor)

Making a Ladder Program (Ladder Editor)


KV STUDIO is software for making ladder programs. KV STUDIO is highly user-friendly, and
provides an amenable environment for programming. Let's actually try making a program.

2 1 Before starting programming


When you make a new project and determine the unit configuration in Unit Editor, the [Ladder
edit] window will be opened.
MAKING A LADDER PROGRAM

First of all, let's try writing a program in this [Ladder edit] window.

Ladder edit
window

Oh, I see.
You write the ladder
network here.

2-22
Making a Ladder Program (Ladder Editor)

A white framed area in the [Ladder edit] window is called a "cell." Program instructions and
connection lines in this area to build the entire ladder network.
The green border is called the "cursor." When you move the cursor, editing content can move to
the required cell.

Enter ladder symbols (instructions) in the cell indicated this green cursor.
2
Cell indicated by cursor

MAKING A LADDER PROGRAM


Column

Moving the cursor


Various keys can be used for moving the cursor. Learning these key combinations will
come in very handy.

, , , The cursor moves.


Page
Up , Page
Down The cursor moves in pages (screens).
Ctrl + , The cursor moves by blocks.
Shift + Tab The cursor moves to the previous symbol.
Tab The cursor moves to the next symbol.
Home The cursor moves to the start of the rung.
End The cursor moves to the end of the rung.
Shift + , , , Selects multiple cursors.
Ctrl + Selects a rung.
Shift + Ctrl + Selects from the current cursor position to the end of the
rung.

2-23
Making a Ladder Program (Ladder Editor)

2 Enter an input relay ladder symbol.


First of all, let's make the simplest of programs, a circuit based on a single normally open contact
and a single output.
Enter the NO contact of input relay MR01000 at the start of the rung.
Move the cursor to the cell that you want to enter the NO contact, and click the icon on the
tool bar.
2 Different Procedure Press F5 on the keyboard.
MAKING A LADDER PROGRAM

Click here.

The [Operand edit] dialog box is displayed.

Enter the device No.


here.

Operand edit dialog box

Tip • A "NO (normally open)" contact is a "contact that turns ON when a switch or other input
device turns ON."
• NO (NO (Normally Open)) contacts are also called "make contacts."

2-24
Making a Ladder Program (Ladder Editor)

Column
Various ways of entering instructions
●Entering directly using mnemonics

MAKING A LADDER PROGRAM


Select the cell and enter directly enter
the mnemonic on the keyboard.

●By entering on the [Instruction/macro palette]


Double-click the selected cell. The [Instruction/macro palette] opens.
Select the required instruction from the [Instruction/macro palette] that is displayed, and
enter the name of the device.
When you have finished entering everything, click the "Overwrite" button.

Select the
instruction.

Enter the
name of the
device
to be used.

Click the
"Overwrite"
button to write
the symbol.

2-25
Making a Ladder Program (Ladder Editor)

Enter "MR1000" to , and click the "OK" button.

Enter "MR1000"
here.

2
MAKING A LADDER PROGRAM

After entering, click the


"OK" button.

The cursor moves to the


NO contact MR01000 next cell to the right.
was entered.

2-26
Making a Ladder Program (Ladder Editor)

3 Enter an output relay ladder symbol.


Next, let's try entering output relay MR05000.
Move the cursor to the 10th cell.

Move the cursor. 2

MAKING A LADDER PROGRAM


Move the cursor, and then click the icon on the tool bar.

Different Procedure Press F7 on the keyboard.

The [Operand edit] dialog box is displayed. Let's enter "MR5000" to .

Enter "MR5000"
here.

After entering, click the


"OK" button.

When you have finished entering, click the "OK" button.


MR05000 is entered.

2-27
Making a Ladder Program (Ladder Editor)

4 Enter connection lines.


In the ladder program below, the 1st cell and the 10th cell are not connected as a network.
To establish the network, output MR05000 must be connected to NO contact MR01000.

It must be
2 connected.
MAKING A LADDER PROGRAM

Move the cursor to the 2nd cell, and click the icon on the tool bar.

Different Procedure Press F9 (or ) on the keyboard.

A connection line was added.

2-28
Making a Ladder Program (Ladder Editor)

Enter connection lines to all blank cells. Output MR05000 is connected to the NO contact
MR01000 to complete one network.

MAKING A LADDER PROGRAM


Column

"Undo" and "Redo"


If you overwrite a network that you require by a connection line, you can undo the mistake.

I've
overwritten it!

Click (undo) on the tool bar. Press the Ctrl + Z keys.

It can also
be undone by
right-clicking with
the mouse.

The mistake was undone.


If you undo too far, click (Redo) on the tool bar (or Ctrl + Y ). Operations can be
redone.

2-29
Making a Ladder Program (Ladder Editor)

5 Convert the ladder program.


The ladder network is finished. However, you have only just written the ladder network.
Next, convert the ladder program.
Select {Convert(A)}→{Convert(C)} from the menu.

2
MAKING A LADDER PROGRAM

When conversion is successful, the [Conversion result] dialog box is displayed.

If the [Conversion failed] dialog box is displayed, verify the ladder network again referring to the
message that is displayed in the output window.

Displays the error details.

Output window

Tip • Ladder networks are expressed using symbols so that the operator or other personnel
can understand the content of programs, and cannot be directly interpreted by PLCs.
• The conversion described above must be performed so that the ladder network can be
interpreted by the PLC.

2-30
Making a Ladder Program (Ladder Editor)

Column
Other basic ladder networks
●NC contact networks
A "NC (normally closed)" contact is a "contact that turns OFF when a switch or other
input device turns ON." Output turns OFF when the contact turns ON. Output turns ON
when the contact turns OFF.
2

MAKING A LADDER PROGRAM


MR01001 MR05001

Tip • NC (NC (Normally Closed) ) contacts are also called "break contacts."
●AND networks
AND networks comprise contacts connected in series. The network is not established
unless both contacts turn ON.

MR01002 MR01003 MR05002

●OR networks
OR networks comprise contacts connected in parallel. The network is established when
one of the contacts turns ON.

MR01004 MR05003

MR01005

●Self-hold networks
Self-hold networks hold their own network state. When output MR05004 turns ON,
contact MR05004 turns ON and the network is established to hold the state.

MR01006 MR05004

MR05004

●Canceling self-hold networks


Once a self-hold network is established, it continues to hold its own state. Conditions for
canceling the self-hold are required.

MR01007 MR01008 MR05005

MR05005
NC contact for canceling self-hold of MR05005

2-31
Making a Ladder Program (Ladder Editor)

6 Enter the device comment.


The following actual wiring diagram shows a circuit in which "the buzzer switch is pressed
followed by the sounding of the buzzer."

● Actual wiring for an entrance call buzzer

2
Buzzer switch Buzzer
MAKING A LADDER PROGRAM

I understand the circuit.


But what does the symbol
MR01000 indicate?
A switch?
Let's try writing a ladder circuit that operates in the same way as the A lamp?or A buzzer?
actual wiring diagram.
Turn MR05000 ON when MR01000 turns ON.

● Ladder program (without comment)

MR01000 MR05000

The fact that MR01000 means a "buzzer switch" and MR05000 means a "buzzer" is not apparent
unless you look at the actual wiring diagram or you are the programmer.

This is why comments should be attached to devices used in ladder networks.


Comments are attached to devices in KV STUDIO. These comments are called "device
comments."

● Ladder program (with comment)

MR01000 MR05000

Buzzer switch Buzzer

Attaching a comment allows you to


understand the meaning of comments.

2-32
Making a Ladder Program (Ladder Editor)

Let's attach a device comment to device MR01000.


Move the cursor to the cell for MR01000, and press Ctrl + M . The [Operand edit] dialog box is
displayed with the comment field selected.

Select the device to


enter the comment to,
and press Ctrl + M .
2

MAKING A LADDER PROGRAM


You can now enter
a comment.

Enter "Buzzer switch" in the commend field.


When you have finished entering, click the "OK" button.

The device comment "Buzzer switch" is displayed.


Let's try entering the comment "Buzzer" for the MR05000 device, too.

Kanji characters
(2-byte characters)
can also be entered.

2-33
Making a Ladder Program (Ladder Editor)

Adding comments makes it easier to tell the meaning and purpose of networks.

2
MAKING A LADDER PROGRAM

Column

Other methods of entering comments


Double-click the cell to enter the comment to. The [Instruction/macro palette] opens.
Double-click the comment field and enter the comment.
After entering the comment, click the "Overwrite" button to complete entry.

Instructions can also be selected.

Enter the comment.

Also select other


instructions on the
instruction palette.
Used for entering
instructions.

Different Procedure • Select {View(V)}→{Instruction/macro palette(I)} from the menu.


• Click the icon on the tool bar.

2-34
Making a Ladder Program (Ladder Editor)

7 Enter the rung comment.


When you add a comment to a device, the operation of the network and the role of the device are
easier to tell. However, lots of information cannot be written as the number of characters that can
be written is restricted.
To write an explanation of the entire network or write various information, use "rung comments"
that handle the entire rung as a comment.

So, let's try writing a rung comment.


2
Move the cursor to the rung where the comment is to be inserted.

MAKING A LADDER PROGRAM


Next, select {Edit(E)}→{Insert(W)}→{Rung comment(H)} from the menu.

Comments can be entered


to the entire rung.*

(actual wiring for an


entrance call buzzer)
Buzzer switch Buzzer

Programming of rung comments is not


subject to any special restrictions.

* To exit the rung comment entry mode, enter either


Ctrl + Enter or Esc on the keyboard.

You can also enter the mode by clicking on screen


at a location other than the rung comment entry position
with the mouse.

2-35
Making a Ladder Program (Ladder Editor)

Column
About self-hold circuits: No.1 (set priority type self-hold network)

2
MAKING A LADDER PROGRAM

Explanation of network operation


(1) The buzzer (MR05000) sounds (outputs) when the buzzer switch (MR01000) is pressed (turned ON).
(2) The timer starts to operate at the same time that the buzzer starts to sound. Timer operation is
completed (turns ON) after five seconds.
(3) The buzzer continues to sound even if the buzzer switch is released (turned OFF). (self-hold)
(4) The buzzer stops sounding five seconds after (when the timer turns ON) the buzzer switch is
pressed. (self-hold cancel)
(5) The buzzer does not stop sounding if the buzzer switch is held down.

With this self-hold network, output (MR05000) continues to stay ON when the execution
condition (in this case, MR01000) turns ON.

For details on the timer


instructions, refer to the KV-1000
Series Instruction Reference
Manual.

Tip • The above self-hold network is called a "set priority type self-hold network."
• This type of network is used, for example, in cases where turning OFF of alarm
output (alarm or alarm lamp) is to be prevented unless the cause of the alarm is
removed when the cause of the alarm (generation of some kind of trouble or
malfunction, etc.) is the execution condition.

2-36
Making a Ladder Program (Ladder Editor)

Column
About self-hold circuits: No.2 (reset priority type self-hold network)

MAKING A LADDER PROGRAM


Explanation of network operation
(1) MR01001 is turned ON for the duration that the buzzer switch (MR01000) is held down once it is
pressed (turned ON).
(2) The buzzer (MR05000) sounds (outputs) when MR01001 turns ON.
(3) The timer starts to operate at the same time that the buzzer starts to sound. Timer operation is
completed (turns ON) after five seconds.
(4) The buzzer continues to sound even if the buzzer switch is released (turned OFF). (self-hold)
(5) The buzzer stops sounding five seconds after (when the timer turns ON) the buzzer switch is
pressed. (self-hold cancel)
(6) The buzzer will stop sounding without fail (timer operation is completed) five seconds later even if the
buzzer switch is held down.
(7) If the buzzer switch is pressed again when the buzzer has stopped sounding, the buzzer will
continue to sound again for five seconds.

With this network, output (MR05000) is


For details on differential
turned ON for the timer preset time when
detection (DIFU instruction),
the execution condition (here, MR01000) refer to KV-1000 Series
turns ON, and the self-hold is always Programming
Manual.
reset after timer operation is completed.

Tip • The above self-hold network is called a "reset priority type self-hold network."
• This network is used, for example, when devices that have started operating by
execution conditions must be stopped after a preset time has elapsed (or by
detection of a limit switch).

2-37
Checking Operation of the Ladder Program (monitor)

Checking Operation of the Ladder Program (monitor)


The following describes how to transfer programs made on Ladder Editor to the PLC to be
monitored (operation confirmed).

Before writing ladder programs to a PLC


2
Before you start this operation, connect the PC to the KV-1000 and enable communications.
MAKING A LADDER PROGRAM

● When connecting by the USB interface


When connecting the PC to the KV-1000 by a USB cable, select {Monitor/
Simulator(N)}→{Communication settings(T)}→{USB port} from the menu.

Different Procedure Click the icon on the tool bar.

When selected, the


checkbox is marked.

● When connecting by a different communications method


When connecting the PC to the KV-1000 by a communication method other than the USB
interface, the communications must be set up.
For details on setup, refer to KV STUDIO User's Manual "9-1 About Monitor/Simulator Functions."

Tip • When you connect by USB for the first time, the USB driver must be installed on the PC.
KV STUDIO User's Manual "1-5 Installing the USB Driver"

2-38
Checking Operation of the Ladder Program (monitor)

Writing programs

Write the ladder program you have made to the KV-1000 connected to the PC.
Make sure that the "operation selector switch" on the KV-1000 is set to the Run mode.

Operation selector switch


2
RUN
Set to the

MAKING A LADDER PROGRAM


RUN side.
PROG

Tip • when the "operation selector switch" is set to the PROG mode, the switch must be set
to the Run mode after the ladder program is transferred to the KV-1000 from the PC.
The ladder on the KV-1000 cannot be run if the "operation selector switch" is set to the
Prog mode.

Select {Monitor/Simulator(N)}{Convert→Transfer→Monitor(C)} from the menu.

2-39
Checking Operation of the Ladder Program (monitor)

● When the ladder program you have made does not contain an error
The following dialog box is displayed when the program you have made has been correctly
programmed.

Connection processing in progress


dialog box:
Convert the ladder program and
2 check communications.
MAKING A LADDER PROGRAM

[Transfer Program] dialog box:


This is displayed only when the
connection has ended successfully.

Select the information to write


to the PLC.

Select the state of the PLC


during writing.

When the [Transfer program] dialog box is displayed, this means that the program is ready to be
written.

Tip • By default, all of the checkboxes for the "Trnsfr itms" (information to write to the PLC)
are marked. To disable writing of information, unmark the checkbox.
• For the state of the PLC during writing, select either of "Pause PLC before writing
program" or "Write program with PLC in Run mode".

2-40
Checking Operation of the Ladder Program (monitor)

● When the ladder program you have made contains an error


The ladder program is not converted successfully when it is incorrectly programmed. The
following dialog box is displayed.

Click OK.
2

MAKING A LADDER PROGRAM


Click OK to return to the
Ladder edit window.

The details of the program error are displayed in the [Output window]. Refer to this for correcting
the program.

Displays the following


for the error that has
occurred:
· Module name
· Rung No.
· Column No.
· Error details

Also, if you double-click the error message in the [Output window], the cursor in the [Ladder edit]
window moves to the start of the rung in question.

Double-click the error


message of the output
window.

The cursor moves to the


ladder rung that indicates
the error message.

Tip • When the program contains multiple errors, or when each module contains an error, all
of the error locations are displayed in the [Output window]. This makes it easier to
reach the error locations more quickly.

2-41
Checking Operation of the Ladder Program (monitor)

● Transferring programs to the PLC


Select "Transfer in PROGRAM mode" (default setting), and click the "Execute" button.
The following dialog box is displayed when the PLC is in the Run mode.

2
MAKING A LADDER PROGRAM

When the "Yes" button is clicked, the PLC is switched to the Prog mode, and transfer of the ladder
program is started.

Tip • When "Transfer in PROGRAM mode" is selected, the PLC is paused during transfer of
the ladder program, and so devices currently controlled by the PLC stop until the PLC
returns the Run mode.
• To prevent other controlled devices from being stopped, select "Transfer program in
RUN mode".
KV STUDIO User's Manual "9-1 About Monitor/Simulator Functions"

● When transfer of the program ends


The following dialog box is displayed when program transfer ends successfully. Click the "Yes"
button to set the PLC to the Run mode.

When "No" is selected, the PLC stays switched


to the Prog mode.
The PLC will not start running unless the mode
is changed to the Run mode.

The following message is displayed in the [Output window].

Successful write message

This completes writing of the ladder program to the PLC.

2-42
Checking Operation of the Ladder Program (monitor)

Monitoring programs

When writing of the ladder program is completed, various information (e.g. contact states and
timer current values) can be confirmed.

● Confirming the operation state of the PLC


When the PC and PLC are being monitored, you can toggle between the Run mode ←→ and the 2
Prog mode on KV STUDIO.

MAKING A LADDER PROGRAM


: (red) Stop Monitor .................. Stops the Monitor.

: (green) Start Monitor .............. Starts the Monitor.

: Execution run
/continuous scan..................... Sets the PLC to the Run mode.

: Program/pause ....................... Sets the PLC to the Prog mode.

· Monitor screen

Displays the operating mode, scan time and the


communications procedure with the PLC.

2-43
Checking Operation of the Ladder Program (monitor)

● Ladder Monitor
Confirm the states of contacts and outputs.

2 NO contact MR01000
is in an OFF state.
MAKING A LADDER PROGRAM

NC contact T0100
is in an ON state.
The timer turns
OFF when it reaches
the preset time.

The PLC is in the Output MR05001 is in an


Run mode. OFF state.

The following shows the differences in display by state.

Timer, etc.
Input Output
Instructions

ON state

OFF state

2-44
Checking Operation of the Ladder Program (monitor)

Turning bit devices ON/OFF

The state of bit devices can be inverted (ON to OFF, OFF to ON) by simple operation.

● Turning bit devices ON/OFF using the mouse


Move the mouse cursor to the device to turn ON/OFF and double-click.
2

MAKING A LADDER PROGRAM


Double-click
MR01000.

The MR01000
turned ON.

When the circuit is established, the


current value of the timer is updated.

● Turning bit devices ON/OFF using the keyboard


Move the mouse cursor to the device to turn ON/OFF and press Space .

Note
• Timer/counter contacts and external I/O relays cannot be turned ON/OFF.
• To turn external I/O relays ON/OFF, inhibit input refreshing.
KV STUDIO User's Manual "9-2 Monitor Functions"

2-45
Checking Operation of the Ladder Program (monitor)

Registration Monitor

When Registration Monitor is used, the required devices can be selected and monitored.
Registration Monitor can also display time charts which is handy, for example, for monitoring
networks that do not fit in a single screen.

2 ● Calling the Registration Monitor window


Select {View(V)}→{Registration Monitor window(B)} from the menu.
MAKING A LADDER PROGRAM

What is
Registration
Monitor capable of?

(1) (2) (3) (4) (5) (6)

(1) Device : Register the device to monitor.


(2) Current value : Displays the current values of all devices. The values can also be changed.
Bit devices are displayed as * when ON and — when OFF.
(3) Display format : Displays the display format of the current value and setting value.
(4) Setting value : Displays the setting values of timers and counters. The values can also be
changed.
(5) Contact : Displays the contact states of timers and counters.
Contacts are displayed as * when ON and — when OFF.
(6) Time charts : Time charts display device ON/OFF state together with the time.
This allows the state of devices in a series of operations to be easily
understood.

2-46
Checking Operation of the Ladder Program (monitor)

Let's try using the Registration Monitor.

MAKING A LADDER PROGRAM


Immediately after the [Registration Monitor] window is called up, nothing is displayed as devices
are not registered.
Device are registered and monitored either by directly entering the device No. in the device field,
or by dragging-and-dropping from the [Ladder edit] window.

● Directly entering device Nos.


Double-click the device field in the [Registration Monitor] window.

Double-click
and then enter
the device No.

Enter the device No. to monitor.

Then, press Enter . The state of the registered device


(MR01000) can be monitored.

2-47
Checking Operation of the Ladder Program (monitor)

● Dragging-and-dropping devices
The devices to monitor can be registered simply by mouse operation.

Click the device to be registered, and align the


mouse cursor with the edge of the cell.

2 *Anywhere on the border line is OK.


MAKING A LADDER PROGRAM

The mouse cursor changes shape to ,


and can be dragged.

When you drag a device, the mouse cursor changes to . Drop the device in this state onto
the [Registration Monitor].

Drag-and-drop
*Anwhere in the Registration
Monitor window is OK

It is now registered.

2-48
Checking Operation of the Ladder Program (monitor)

● Batch-registering multiple devices


Multiple devices in the [Ladder edit] window can be batch-registered.

Select the multiple devices to be registered,


and align the mouse cursor with the frame
of the cell.
2

MAKING A LADDER PROGRAM


The mouse cursor changes shape to ,
and can be dragged.

When you drag a selected range, the mouse cursor changes to . Drop the selected range in
this state onto the [Registration Monitor].

Drag-and-drop
*Anwhere in the Registration Monitor
window is OK

The multiple devices


are batch-registered.

2-49
Checking Operation of the Ladder Program (monitor)

● Typical example of how to use the Registration Monitor window


The registered state of the bit devices or the setting value/current value can be changed forcibly.
• Changing the setting value/current value of timers and counters

2
Directly rewrite the
numerical value here.
MAKING A LADDER PROGRAM

Rewrite the setting value


on Registration Monitor.

The setting value was


changed (25030).

* The current value also can be rewritten in the same way.

• Changing the state (current value) of bit devices

Double-click the
current value
column of the
bit device.

Double-clicking changes
the bit state.

(OFF) was changed to


(ON).

2-50
Checking Operation of the Ladder Program (monitor)

● About time charts


When time charts are used, you can check the operating status of the ladder program as the
timing that the ON/OFF state of the device contacts is switched is displayed in real time.
• About bit devices
When the bit device state is ON (1: TRUE), the time chart indicates " ", and when it is OFF
(0: FALSE), the time chart indicates " ".
2

MAKING A LADDER PROGRAM


The state of the bit device
is 0 (OFF). The state of the bit device
is 1 (ON).

• About word devices


When the state of a word device does not change, the time chart indicates " ". When the
currently stored value changes, the time chart indicates " ".

The state of the word


device does not change. The state of the word
device changed.

Note
The scale of the time chart is the scale of the timing that individual
communication is performed on the Monitor, and is not the scan time.
To display a more accurate time chart marked for each scan, use the High-speed
Time Chart Monitor.
KV STUDIO User's Manual "High-speed Time Chart Monitor"

2-51
Checking Operation of the Ladder Program (monitor)

About the [Change device values] window

When the [Change device values] window is used, the values of devices can be changed during Monitor
or Simulator operation.
The functions and appearance of the [Change device values] window resemble the [Registration
Monitor] window, though it can be used with greater ease.
2
● Calling the [Change device values] window
Select the desired device in the [Ladder edit] window during Monitor (or Simulator) operation and
MAKING A LADDER PROGRAM

press F2 . The [Change device values] window is displayed.

Multiple devices and devices in individual rung units can be specified.

Select in rung units


and enter F2 .

Operations in the [Change device values] window are the same as in the [Registration Monitor]
window. (* For details, see "Registration Monitor" (page 2-46).)
To change the device display order, drag the device No. in the window, and drop the device at the
new desired display position.

Move by dragging-
and-dropping. Moved.

2-52
Checking Program Operation without a PLC (simulator)

Checking Program Operation without a PLC (simulator)


When the Simulator functions are used, you can check the operating state of the ladder program
even without a KV-1000 connected to the PC.

Starting up Simulator
2
To start up Simulator, select {Monitor/Simulator(N)}→{Simulator(L)} from the menu.

MAKING A LADDER PROGRAM


Different Procedure Click the icon on the tool bar.

Icon for operating Simulator functions

· Simulator screen

Displays the step No. currently executing


on Simulator · operation state · and scan time.

Tip • With Monitor functions, where the KV-1000 is connected to the PC, transient changes
such as processing of continuous complicated operations can not be grasped midway.
With Simulator, however, debugging becomes easier to perform as operation results
can be checked at each step.

2-53
Checking Program Operation without a PLC (simulator)

How to use Simulator

Simulator is provided with various functions such as 1-scan execution and 1-step execution in
addition to continuous scan execution.

Tip • A "step" is a the minimum unit of program execution performed by the PLC, and is
2 used in "mnemonic language" that can be understood by the PLC.

● Execute 1 step:
MAKING A LADDER PROGRAM

Click the icon on the tool bar. The arrow in the [Mnemonic list] window currently
displayed on the right side of the main window moves one unit down (to the next step).

Different Procedure Select {Debug(D)}→{Execute 1 step(W)} from menu.

Value of internal register at current point and


state of operation judgment flag (CR2009)

Arrow indicates execution stop position.


(Execution of the instruction on the rung
indicated by the arrow has completed.)

Each click of the icon on the menu advances program execution one step at a time, and
when the ENDH instruction is executed, program execution returns to the initial step.
Also, the cursor in the [Ladder edit] window moves to the top of the network block that contains
the currently executing mnemonic.

2-54
Checking Program Operation without a PLC (simulator)

● Continuous step execution:


Click the icon on the tool bar.
The ladder program is executed (simulated) continuously up to a step programmed with a break
condition. (For details on break conditions, see "Setting break conditions" (page 2-56).)

Different Procedure Select {Debug(D)}→{Execute continuous step(S)} from menu.


2

MAKING A LADDER PROGRAM


● mark indicates break set point.
The arrow will stop at this point after continuous
execution.

● Execute 1 scan:
Click the icon on the tool bar.
When the ladder program is executed (simulated) up to the step programmed with the ENDH
instruction, program execution returns and stops at the 0th step.

Different Procedure Select {Debug(D)}→{Execute 1 scan(T)} from menu.

Each step is simulated once from step 000000


up to the step programmed with the ENDH
instruction as one step.

● Continuous scan execution:


Click the icon on the tool bar.
When a break condition is not set, the ladder program is executed (simulated) continuously until
you click the icon on the tool bar.

Different Procedure Select {Debug(D)}→{Execute run/continuous scan(R)} from menu.

2-55
Checking Program Operation without a PLC (simulator)

Setting break conditions

A "break condition" is a condition that causes execution of the ladder program to stop at a specific
step during continuous scan execution or continuous step execution.
Though program execution is advanced up to the desired step if 1-step operation is repeated, this
becomes a difficult task when the ladder program increases in size. This function allows you to
2 check operation more efficiently.

● Rung breaks:
MAKING A LADDER PROGRAM

Rung breaks are used to stop program execution at a specified step (mnemonic).

Rung breaks can be set by double-clicking the mnemonic to stop program execution at in the
Mnemonic list.
If continuous step execution is performed at this time, execution of the ladder program is paused
at the preset break point (rung).

Continuous step execution:


Click the icon on the tool bar.

Different Procedure Select {Debug(D)}→{Execute continuous step(S)} from menu.

Continuous step
execution

Break condition Double-click Execution is paused at the


setting mark mnemonic. break point (rung).

Output window

2-56
Checking Program Operation without a PLC (simulator)

● Device breaks:
Device breaks are used to stop program execution by the state of a specified device.

The change in bit device state (ON ←→ OFF) or the numerical values of a word device can also be
specified as the break condition.

Set device break: 2


Click the icon on the tool bar.

MAKING A LADDER PROGRAM


Different Procedure Select {Debug(D)}→{Set device break(B)} from the menu.

To set a bit device state as the break condition

Click the "Add conds" button


to add the device to the list.

· Selection of module
/macro to set
· Entry of device No.
· Selection of stop condition

Selection of device type

Unmarked devices
are ignored.

Conditions when multiple


devices are selected

To set a word device state as the break condition

Click the "Add conds" button


to add the device to the list.

· Selection of module
/macro to set
· Entry of device No.
· Selection of stop condition

Selection of device type

Unmarked devices
are ignored.

Conditions when multiple


devices are selected

2-57
Checking Program Operation without a PLC (simulator)

Column

If you attempt to set a break condition to an extremely long ladder program, it will become
more difficult to find the corresponding mnemonic, making it more difficult to set the device
break.
2 In this case, double-click the desired rung No. of the ladder to set the break condition to.
The mnemonic corresponding to the rung No. will automatically be displayed.
MAKING A LADDER PROGRAM

Double-click the
rung No.

The corresponding
mnemonic is displayed.

Tip • Mnemonics indicate the start of the network block. In the above example ladder, double-
clicking the 7th rung will result in the same mnemonic being displayed.

2-58
3 REDUCING PROGRAMMING
MAN-HOURS

Turning Specific Sections of Programs into Parts


for Re-use (modules) . . . . . . . . . . . . . . . . . . . . 3-2
Procedure for Using Modules . . . . . . . . . . . . 3-10
About Local Devices . . . . . . . . . . . . . . . . . . . 3-26
Making Original Instructions (macros) . . . . . . 3-30
Procedure for Using Macros . . . . . . . . . . . . . 3-38

head!
Let's get a

3-1
Turning Specific Sections of Programs into Parts for Re-use (modules)

Turning Specific Sections of Programs into Parts for Re-use (modules)


General ladder programs for controlling devices contain various processes such as initialization
processing, automatic operation, manual operation, and error processing. Up till now, these
multiple processes were managed as a single continuous ladder program.

Assembly on line A

3 Initialization of line A

I want to review just


REDUCING PROGRAMMING MAN-HOURS

the zero return section.


But it's going to take

.....
ages to review the
whole thing.
*** Zero return ***
With conventional ladder
programs, you have to take
into consideration the fact
that a partial correction will
affect the entire program.
.....

So, you have to have an


understanding of how the
entire program will operate.
*** Manual operation ***
.....

*** Automatic operation A ***


.....

Conventional ladder program

3-2
Turning Specific Sections of Programs into Parts for Re-use (modules)

On KV STUDIO, programs are made individually for each process, factory process, function, and
other elements, and each of these is managed as independent parts or "modules" in a single
project.

Project name:
Assembly on line A
Zero return

Manual operation

Abnormality processing
3
Automatic operation

REDUCING PROGRAMMING MAN-HOURS


Initialization of line A
....

Ladder program comprising modules

If individual
processing or
So, you don't have to
functions are turned
review the entire
into modules, all you
have to do is to just program when
correct the correcting it!
It won't take long to
desired module.
debug a program of
this size.

<Up till now> <On KV STUDIO>

· With large (long) programs, it was ·You can tell at a glance where a
hard work finding where the required
particular process is programmed.
programmed script was located. ·The entire program can be debugged
· Debugging was also hard work since
simply as corrections to the program
a partial correction affected the entire
hardly affect other modules.
program.

3-3
Turning Specific Sections of Programs into Parts for Re-use (modules)

If parts of programs are managed individually at separate modules for functions and processes,
you can adapt to additional processes or changes to parts, or delete unwanted functions with
more ease.

Project name: Project name:


Assembly on line A Assembly on line A
(1 product type (2 product types
supported) supported)
** Zero return **
** Zero return **

** Manual operation **
** Manual operation **

3 ** Automatic operation **
** Automatic operation **
REDUCING PROGRAMMING MAN-HOURS

** Abnormality processing **
** Abnormality processing **
Program
changed
* Inspection process (2 product types) *
* Printing process (1 product type) *

Module deleted
Functions (or processes)
Module added
can be simply added or
deleted if they are turned
into modules.
* Printing process (1 product type) *

3-4
Turning Specific Sections of Programs into Parts for Re-use (modules)

Column

Module library
Modules you have made can also be used in other projects if they are registered to the
module library.
If you put all of the required modules in the module library, you can build the base program
of the project merely by re-using these modules.

Module library
3
Automatic operation

REDUCING PROGRAMMING MAN-HOURS


Zero return

Abnormality processing

Printing process
Manual operation
Assembly process A

Project name:
Machine A assembly line

Zero return

Manual operation

Abnormality processing

Automatic operation

You can build a program that


forms the base of a project by
merely collecting modules
together in a library.

3-5
Turning Specific Sections of Programs into Parts for Re-use (modules)

Types of modules on KV STUDIO

As displayed in [Workspace], there are three types of KV STUDIO modules: "every-scan


modules" • "initialization module" • "standby module".

(1)
3
(2)
REDUCING PROGRAMMING MAN-HOURS

(3)

(1) Every-scan module


Every-scan modules are executed at every scan when the KV-1000 is in the Run mode.
• One of these modules is automatically created when a new project is made.
• Just like standby modules, execute/stop of every-scan modules can also be controlled using
module exclusive instructions.
"Column: About module exclusive instructions" (page 3-9)

(2) Initialization module


The initialization module is executed only at the initial scan when operation of KV-1000 is started
(when the power is turned ON, or the Prog mode is switched to the Run mode).
• This module is used, for example, for initially setting up each unit or functions.
• Execution/stop of the initialization module cannot be controlled using module exclusive instructions.

(3) Standby module


The standby module does not operate until the startup instruction (MDSTRT module start
instruction) from another module is executed.
• After the module is started up (the MDSTRT module start instruction is executed), it is executed
at every scan in the same way as an every-scan module, and the module continues to operate
until the end instruction (MDSTOP module stop instruction) is executed.

Projects are configured by making modules of type matched to the target operation.

Tip • Module types can also be changed later.

3-6
Turning Specific Sections of Programs into Parts for Re-use (modules)

Making a project using an every-scan module

With conventional ladder programs, programs were divided into sections by inserting a rung
comment. However, by turning functions or processes into modules, programs can be divided up
more clearly to make the program easier to understand.
Ladder programs divided up into modules have the advantages of being easier to understand,
easier to re-use and easier to debug than conventional ladder programs.

[manual operation]

[manual operation]
3
Zero return module

REDUCING PROGRAMMING MAN-HOURS


END
ENDH
Manual operation module
[automatic operation]
Automatic operation module
[automatic operation]

Abnormality processing module


[abnormality processing]

END
ENDH

Conventional ladder program Ladder program


not comprising modules comprising modules

Compared with conventional


long ladder programs, turning
processes or functions into
modules makes programming
that much easier!

Column

Dividing ladder programs up into modules


When you divide up the program to create modules, the modules can
be made more re-usable if you use local devices for the program in
each individual module.
A "local device" is a device that can be used independently in each
module. Local devices can be used without the programmer having to
be aware of duplicated device Nos. between modules.
"About Local Devices" (page 3-26)

3-7
Turning Specific Sections of Programs into Parts for Re-use (modules)

Making a project by using standby modules together with every-scan modules

The advantages of dividing ladder programs up into modules can be more fully taken advantage
of by selectively using "every-scan modules" that must be executed when the KV-1000 is in the
Run mode, and "standby modules" that are executed when the execution state is switched by
preset execution conditions.
In this case, it is handier if you program a main module for controlling start/stop of the standby
module.

3 Let's create a main


module (every-scan type)
for controlling start/stop
REDUCING PROGRAMMING MAN-HOURS

of the standby module.

When every-scan modules only are used When the standby module is controlled
by the main module
* *
Zero return module Zero return module
Main module
Manual operation module Manual operation module

Automatic operation module Automatic operation module

Abnormality processing module Abnormality processing module


. . .

. . .

· Modified version of a conventional ladder · A more advanced application of modular


program programming
· Advantages include easier debugging, · Start/stop of various function modules is
easier-to-understand programs, and easier controlled from the main module.
re-use individual module units. · Suspension of unwanted modules
leads to a shorter scan time.

*Legend

Module ...Every-scan module


Creating a main
Module ...Standby modul module makes
programming easier!
Module ...Initialization modul

3-8
Turning Specific Sections of Programs into Parts for Re-use (modules)

Column

About module exclusive instructions


Execution/stop of modules can be controlled from the ladder program by using module
exclusive instructions.

● Module start (call): MDSTRT module start instruction

· Ladder program · Input method 3


Execution condition MDSTRT

REDUCING PROGRAMMING MAN-HOURS


Module name M D S T R T Module name Enter

• Explanation of operation
When the execution condition turns ON, the specified module is started up. The
specified module starts operating from the next scan.
The specified module continues to operate without any need to hold the execution
condition until the MDSTOP module stop instruction is executed.

Note
When this instruction is executed on the initialization module, an error
occurs at ladder program conversion.

● Module stop (end): MDSTOP module stop instruction

· Ladder program · Input method

Execution condition MDSTOP


Module name M D S T O P Module name Enter

• Explanation of operation
When the execution condition turns ON, the specified module is stopped. When stop is
instructed for a module, OFF processing* is executed for only one scan at the next scan
to stop operation of that module.
When stop is instructed for a module, there is no need to hold the execution condition,
and the module will not operate until the MDSTRT module start instruction is next
executed.
* For details on execution of OFF processing, see "Column: Executing modules by
OFF conditions" (page 3-24).

Note
When this instruction is executed on the initialization module, an error
occurs at ladder program conversion.

KV-1000 Series Programming Manual "2-7 Module Instructions"

3-9
Procedure for Using Modules

Procedure for Using Modules


The following describes a procedure for writing a modular program for an assembly line having
zero return and abnormality processing functions for when an abnormality occurs on the line in
addition to automatic operation and manual operation functions.

STEP1 Study the configuration of the overall program.

Study which functions (operations) are to be provided taking the entire device to be
programmed into consideration.

3
STEP2 Generally categorize the program by function.
REDUCING PROGRAMMING MAN-HOURS

Generally categorize the functions (operations) required for controlling the device.
At this time, each categorized function (operation) is called a "module."

STEP3 Study other categories.

· Initialization function: Study whether the PLC needs to be initialized.


· Categorize: Further categorize program functions if necessary.

STEP4 Create modules for each individually categorized function.

Categorize each of the program functions.


"Types of modules on KV STUDIO" (page 3-6)
At this time, set all of the modules except the initialization module to "standby module."

STEP5 Create the main module.

Create the "main module" for controlling modules that are created.
Switch multiple standby modules by the main module.

STEP6 Change the execution order of the modules.

Change the execution order of the required modules as required when multiple modules are to
be executed.

Completion of module setup

3-10
Procedure for Using Modules

STEP1 Study the configuration of the overall program.


Study the operation and functions of the devices for which the ladder
program must be written. STEP1
When doing this, do not forget mandatory functions such as automatic
Study the configuration
operation and manual operation. of the overall program.

STEP2 Generally categorize the program by function.


Categorize the program by function.
At first, do not categorize the ladder program into detailed sections; divide
it up into about four to six sections. What is important is that you create
clear boundaries between each of the functions. STEP2 3
Functions divided up and categorized in this way are managed as Broadly categorize
the program by function.
"modules" on KV-STUDIO.

REDUCING PROGRAMMING MAN-HOURS


Project 1

Module A Module B
*** Zero return *** *** Manual operation *** STEP3
Zero return operation of device Manual operation of device
Study other
categories.
Module C Module D
*** Zero return *** *** Automatic operation ***
Processing when trouble occurs Automatic operation of device
during automatic operation

STEP4
Create modules for
Categorize the individual program each individually
functions as modules. categorized function.
The trick is to categorize each of the
modules so that they are independent
of each other as possible.

STEP5
Create the main
module.

STEP6
Change the execution
order of the modules.

3-11
Procedure for Using Modules

STEP3 Study other categories.


Study whether or not individual processes of the program categorized in
STEP1 STEP2 must be categorized or individual functions must be categorized
as functions to be initialized.
Study the configuration
of the overall program. ● Initialization function (initialization module)
If you make an initialization module in advance, device values or bit states
can be cleared (or set) when the PLC is turned ON or when the operating
mode is switched (Prog→Run).

Tip • The initialization module can be executed only once at the


3 STEP2 initial scan when PLC operation is started (power turned ON, or
the Prog mode is switched to the Run mode), and so cannot be
Broadly categorize
the program by function. started up from the second scan onwards.
REDUCING PROGRAMMING MAN-HOURS

● Further categorization of functions


When function categories are clear, functions and processes may be
divided up and categorized further.
Note, however, that if functions and processes are divided up and
STEP3 categorized in too much detail, alternatively you might find it more difficult
Study other to get an overall grasp of how the program flows. For this reason, you
categories.
should determine categorization guidelines such as function units or
process units beforehand.

The device initialization


module was added.

STEP4
Create modules for
each individually
Device initialization module
categorized function.

Zero return module Zero return module

Manual operation module Manual operation module

STEP5
Create the main Abnormality processing module Abnormality processing module
module.

Automatic operation module A


Automatic operation module

Automatic operation module B

Automatic operation module C

STEP6
Change the execution
order of the modules.

Example of automatic operation module


further categorized into three modules

3-12
Procedure for Using Modules

Column

Examples of how to make modules


When making programs using modules, the flow of the overall program will become clearer
if you make one main module that is executed at all times, and then control operation of
each of the standby modules as shown in the following examples.

● Modules created by individual function ● Modules created by individual product type


3
Zero return module Product type A module
Main module Main module

REDUCING PROGRAMMING MAN-HOURS


Manual operation module Product type B module

Automatic operation module Product type C module

...
Abnormality processing module
...

Additional product types can be simply


adapted to by adding on modules.

● Modules created by multiple engineers

(name of engineer A) module Engineer A: In charge of programming


Main module assembly/fabrication processes
(name of engineer B) module Engineer B: In charge of programming
conveying/inspection processes
(name of engineer C) module Engineer C: In charge of programming
box filling/discharge from factory processes

Tip • If you set the program as "main module + multiple standby modules," only the
program that must be processed at all times will be executed as the ladder
program as standby modules will not be called.
For this reason, the scan time will be shorter than that of ladder programs that
do not comprise modules.

Making programs without being conscious of modules


Of course, you can make a conventional ladder program that is not divided up into
modules.

Main module:
Zero return • Manual operation • Automatic operation
At least one
Abnormality processing • Communications module is required
processing... for a project.

3-13
Procedure for Using Modules

STEP4 Create modules for each individually categorized function.


Create four standby modules and one initialization module.
STEP1
Select {Modules/macros(M)}→{New module(G)} from the menu.
Study the configuration
of the overall program.
Different Procedure

Click the icon on the


tool bar.

3 STEP2
Broadly categorize
the program by function.
The [New module] dialog box is displayed.
REDUCING PROGRAMMING MAN-HOURS

Enter the module name.

Enter the module name.

STEP3
Study other
categories.

Next, select the type of module.

STEP4
Create modules for
each individually
categorized function. Select the type of
module.

STEP5
Create the main
module.

Click the "OK" button.

STEP6
Change the execution
order of the modules.

3-14
Procedure for Using Modules

STEP1
Study the configuration
of the overall program.

STEP2 3
Broadly categorize
the program by function.

REDUCING PROGRAMMING MAN-HOURS


STEP3
A new standby module Study other
named "Zero_Return" categories.
has been made.

Let's make the remaining three standby modules and initialization module
in the same way.
If [Workspace] is displayed as shown below, this step is completed.
STEP4
Create modules for
each individually
categorized function.

STEP5
Create the main
module.

STEP6
Change the execution
order of the modules.

3-15
Procedure for Using Modules

STEP5 Create the main module.


When a new project is made, an every-scan module having the same
STEP1 name as the project is automatically created.
This every-scan module is used to control start/stop of each standby
Study the configuration
of the overall program. module.

● Renaming modules

3 STEP2 Project name


Broadly categorize
the program by function.
REDUCING PROGRAMMING MAN-HOURS

Every-scan module created


automatically by the
same name as the project

STEP3
Study other
categories.
In this example, let's rename the every-scan module "main"* for use.
* Any other name is acceptable.

Right-click the desired module in [Workspace]. Click the right mouse


button, and select {Rename(N)} from the pop-up menu.
Different Procedure Select {Modules/macros(M)}→{Module/macro properties(H)} from
STEP4
Create modules for
the menu.
each individually
categorized function. Call up the menu
by right-clicking.

STEP5
Right-click.
Create the main
module.

STEP6
Change the execution
order of the modules. Select.

3-16
Procedure for Using Modules

The [Module/macro properties] dialog box opens. Rename the module.

STEP1
Change the module Study the configuration
name from "Project 1" to of the overall program.
"Main".

STEP2 3
Broadly categorize
Click the "OK" button the program by function.
after changes are completed.

REDUCING PROGRAMMING MAN-HOURS


When you have finished renaming the module, check whether or not the
name of the module has changed.
STEP3
Before renaming the module
Study other
categories.

After renaming the module STEP4


Create modules for
each individually
categorized function.

Tip • When making a new main module, refer to the procedure in


STEP3. STEP5
• Any name other than "main" is acceptable. Though the initially Create the main
given name (same as the name of the project) can also be module.
used as it is, we recommend renaming the module to an easier-
to-understand name.

STEP6
Change the execution
order of the modules.

3-17
Procedure for Using Modules

Column
About module/macro properties
Various information is contained in the [Module/macro properties] dialog box.

The name and type of the


module can be changed.

Displays the dates that


the module was newly

3 created and updated.

Displays the date that


the module was
REDUCING PROGRAMMING MAN-HOURS

transferred to the PLC.

Displays the date that the


data was saved.

Module functions and


specifications can be
programmed here.

Mark this checkbox to disable the module.


When this checkbox is unmarked, disabling is undone and the module operates as programmed.

Tip • A conversion error occurs when the ladder program contains an instruction to start
up a disabled module.
KV-1000 Series Programming Manual "2-4 Editing Modules"

About switching the Editor screens


To switch between modules, double-click the desired module name on [Workspace]. To
switch an already open module, select {Window(W)}→{"desired module to edit"} from the
menu.
· From the workspace · From the menu

Double-click the desired


module to edit.

Select the desired module


to edit.

3-18
Procedure for Using Modules

STEP6 Change the execution order of the modules.


The module execution order can also be changed if it appears that it is
already determined for each of the module functions. Swap the execution STEP1
order by the following procedure.
Study the configuration
of the overall program.
Tip • The execution order need not be changed if there is no
particular need to change the order.

Click the [Execution order] tab in [Workspace], and select the module
whose order is to be changed.
STEP2 3
Broadly categorize
the program by function.

REDUCING PROGRAMMING MAN-HOURS


STEP3
Study other
categories.

Click the
[Execution order] tab.

STEP4
Create modules for
each individually
categorized function.
Changes the order of
the selected modules.

Displays the execution


order (ascending order)
of the modules. STEP5
Create the main
module.

STEP6
Change the execution
order of the modules.

3-19
Procedure for Using Modules

When you have select the module, click to change the module
order.

STEP1
Different Procedure • Right-click the module whose order is to be changed, and
Study the configuration
of the overall program. select {Move up(U)} or {Move down(D)}.
• Drag-and-drop modules to change their execution order.

Click here.

3 STEP2
Broadly categorize
the program by function.
REDUCING PROGRAMMING MAN-HOURS

STEP3
Study other
categories.

STEP4
Create modules for
each individually
categorized function.
The execution order of
the automatic operation
modules was changed.

STEP5
Create the main
module.
Tip • The initialization module is always executed at the top of the
execution order, and so cannot be placed in descending order
past the second module onwards.
• When the execution order must be set in more detail by
individual modules, we recommend not dividing up the ladder
program and handling the entire ladder program as a single
STEP6 module.
Change the execution
order of the modules.

3-20
Procedure for Using Modules

● About the execution order of modules


The execution/stop timing of each of the initialization module, every-scan modules and standby
modules is different. Understand the characteristics of each of the modules before selecting the
appropriate module.

Device initialization Device initialization


Executed at module module
1st scan only

Executed at
Main
module 1
Main
module 1
3
every scan

REDUCING PROGRAMMING MAN-HOURS


Standb
Standby Standb
Standby
module A module A

Standb
Standby Standb
Standby
module B Scan module B Scan

This section is
Standb
Standby Standb
Standby
not executed
module C module C
until the PLC is
started up.

Standb
Standby Standb
Standby
module D module D

1st scan 2nd scan

State of modules immediately after State of modules immediately after a device


a device is started up (at 1st scan) is started up (from 2nd scan onwards)

Number of scans

Module name
1st scan 2nd scan From 3rd scan onwards
Device initialization Stop Stop
Execute
module (Cannot be started up.) (Cannot be started up.)
Main
Execute Execute Execute
module 1
Execution order

Standby Stops Stops


Always stops
module A (until PLC is started) (until PLC is started)
Standby Stops Stops
Always stops
module B (until PLC is started) (until PLC is started)
Standby Stops Stops
Always stops
module C (until PLC is started) (until PLC is started)
Standby Stops Stops
Always stops
module D (until PLC is started) (until PLC is started)

3-21
Procedure for Using Modules

● Starting up modules
To start up a standby module, use the module exclusive instruction (MDSTRT module start
instruction).
After the start instruction is executed, standby modules start to be executed from the scan
following the scan in which the start instruction was executed.

Device initialization Device initialization


module module

Module A and
module C startup
3 instructions are
executed. Main Main
module 1 module 1
REDUCING PROGRAMMING MAN-HOURS

Standb
Standby Standby
module A module A

Standb
Standby Standb
Standby
Scan module B Scan module B Scan

Standb
Standby Standby
module C module C

Standb
Standby Standb
Standby
module D module D

nth scan (n+1)th scan

Module A and C startup instructions State of modules after modules


are executed by the main module. A and C are started up

Number of scans

Module name
nth scan (n+1)th scan (n+1)th scan onwards

Device initialization Stop Stop Stop


module (Cannot be started up.) (Cannot be started up.) (Cannot be started up.)
Main Executed Executed Execute
module 1 (execution of MDSTRT instruction)
Execution order

Standby Stops Executed Executed


module A (until PLC is started) (until PLC is stopped) (until PLC is stopped)
Standby Stops Stops Stops
module B (until PLC is started) (until PLC is started) (until PLC is started)
Standby Stops Executed Executed
module C (until PLC is started) (until PLC is stopped) (until PLC is stopped)
Standby Stops Stops Stops
module D (until PLC is started) (until PLC is started) (until PLC is started)

The execution order of the module start instruction (MDSTRT module start instruction) is not
affected as each module is executed in the pre-determined order.
3-22
Procedure for Using Modules

● Stopping modules
To stop execution of a standby module that is started up, use the module exclusive instruction
(MDSTOP module stop instruction).
After the stop instruction is executed, standby modules programmed with the stop instruction
return to a standby state after "OFF processing"* is executed at the following scan.

Device initialization Device initialization Device initialization


Stop instruction module module module
programmed to
module A.

Main Main Main


3
module 1 module 1 module 1

REDUCING PROGRAMMING MAN-HOURS


OFF
processing
Standby Standby Stand
Standby
module A module A module
odul A

Standby
Standb
tand Stand
Standby Stand
Standby
Scan module
odule B Scan module
odule B Scan module
odul B Scan

Standby Standby Standby


module C module C module C

Standby
Stand
tand Stand
Standby Stand
Standby
module
odule D module
odule D module
odul D

mth scan (m+1)th scan (m+2)th scan

Module A stop instruction Module A executes


Module A stops from
(MDSTOP) executed by "OFF processing"*for
here on.
main module one scan only.

Number of scans

Module name
mth scan (m+1)th scan (m+1)th scan onwards

Device initialization Stop Stop Stop


module (Cannot be started up.) (Cannot be started up.) (Cannot be started up.)
Main Executed Executed Executed
module 1 (execution of MDSTOP instruction)
Execution order

Standby Executed Stops


Execution of OFF processing
module A (until PLC is stopped) (until PLC is started)
Standby Stops Stops Stops
module B (until PLC is started) (until PLC is started) (until PLC is started)
Standby Executed Executed Executed
module C (until PLC is stopped) (until PLC is stopped) (until PLC is stopped)
Standby Stops Stops Stops
module D (until PLC is started) (until PLC is started) (until PLC is started)

* For details on OFF processing, see "Column: Executing modules by OFF conditions" (page 3-24).

3-23
Procedure for Using Modules

Column

Executing modules by OFF conditions


When a module is stopped by the MDSTOP module stop instruction, OFF processing of all
instructions is automatically executed to clear all of the device states in the module before
modules programmed with the stop instruction return to a stop state.
The module stops at the scan following the scan in which OFF processing was executed.
· Module executing

3 State immediately before


module stop: MR1000 is
always ON in a self-hold
network.
REDUCING PROGRAMMING MAN-HOURS

· Execution at OFF condition


Executed in OFF state:
Each instruction in the stop
module is executed at OFF
conditions.

The module entered the standby state.

Tip • "Execution by OFF conditions" is the same operation as when the MC master
control instruction turns OFF.
KV-1000 Series Instruction Reference Manual "MC Master Control (MCR) Instruction"

Calling the Module Monitor window


The [Module Monitor] window is useful, for example, for narrowing down debugging
locations as it allows you to monitor the operating status of modules.
Tip • The [Monitor Window] window can be displayed only during execution of Monitor or
Simulator. Select {View(V)}→{Module Monitor window(X)} from the menu.

Indicates
that the
"main" module
is currently
executing.

Indicates
that the
"zero return"
module
is currently
standing by.

3-24
Procedure for Using Modules

Sample program using modules

In this sample program, execution/stop of the four standby modules (zero return module, manual
operation module, automatic operation module, and abnormality processing module) is controlled by
one every-scan module (main module).

● Description of operation

From the moment (detection of up edge)


MDSTRT that input relay R00000 (operation start
R00000 R00004 R00015 R00001
00001
Operation
start button
Emergency Program
stop stop button
Origin selection
Zero return

MDSTRT
button) turns ON, the module
(processing function) currently selected 3
R00002
Manual
by mode switching selection (R00001 to
00002 operation R00003) starts to be executed.
Manual selection

REDUCING PROGRAMMING MAN-HOURS


MDSTRT
R00003 Automatic When R00001 (origin selection) is
00003 operation
Automatic
selected, the zero return module is
selection MDSTRT executed, and when R00002 (manual
Abnormality selection) is selected, the manual
00004 processing
operation module is executed.
R00001 MDSTOP When R00003 (automatic selection)
00005 Zero return
is selected, both of the automatic
Origin selection
operation modules and abnormality
R00015
processing modules are executed.
00006
Program
stop button
R00004
00007
Emergency stop When input relay R00015 (program
R00002 MDSTOP stop button) turns ON, execution
Manual
00008 operation of all modules is stopped.
Manual selection When the mode is switched, the
R00015 currently executing module stops.
00009
Program
stop button
R00004
00010
Emergency stop
R00003 MDSTOP
Automatic
00011 operation
Automatic selection
R00015
00012
Program
stop button
MR1000
00013
Abnormality occurs during When MR1000 (abnormality occurred
automatic operation
R00004
during automatic operation) turns ON,
00014 only automatic operation modules are
Emergency stop stopped, and the abnormality processing
R00003 MDSTOP module continues to execute.
Abnormality
00015 processing
Automatic selection
R00015
00016
Program
stop button
R00004
00017
Emergency stop
END
Execution of all standby modules
00018 stops unconditionally when the
emergency stop button is pressed.
ENDH
00019

3-25
About Local Devices

About Local Devices


A "local device" is a device that can be used in individual module and macro units. As the same
device No. can be used in multiple modules and macros, there is no need to assign device Nos. to
each module or macro and manage devices in a list, for example.

How to use local devices

Local devices are useful, for example, when making a ladder program divided up into multiple
modules for a single project, or when re-using modules in other projects.
3
Every-scan module Standby module
REDUCING PROGRAMMING MAN-HOURS

Zero return module


Main module
Manual operation module

Automatic operation module

Abnormality processing module

Divided up into multiple modules

When a program is made


without using local devices ...

** Zero return **
MR00014
** Main **
MR00010
** Manual operation **

MR00014
MR00010

** Automatic operation **
MR00014
The same device No.
already exists.
The device No. must
MR00010 be changed.

???
What's this? MR00010
** **
** Abnormality processing
and MR00014 are used MR00014
in various modules.

3-26
About Local Devices

** Zero return**
@MR00014

** Manual operation**
** Main **
@MR00010

@MR00010
@MR00014
**Automatic operation**
@MR00014

When local devices


are used, devices are
@MR00010 not duplicated even if
the same device No.
3
is used.
**Abnormality processing**

REDUCING PROGRAMMING MAN-HOURS


@MR00014

If you use local devices,


you can program without
worrying about duplication
of device Nos.

Oh, I see. Devices


are handled as local
devices just by prefixing
them with "@".

Column

Local devices and global devices


Whereas a local device is a device that can be used in individual modules, a global device
is a device that is handled in the same way as in conventional ladder programs.

Local Devices Global Devices


Annota- @MR00100, @DM00005, @T0021, etc. (Device MR00100, DM0005, T0021, etc.
tion No. is prefixed with "@".) (Device No. is not prefixed with "@".)
Number The output instruction (OUT, OUB, etc.) of the same If the output instruction (OUT, OUB) of
of uses device No. can be used independently for each the same device No. is used two or
individual module/macro. more times even if the module/macro
is different, this will result in a
duplicated coil and operation becomes
complex.
Other Local devices cannot be used in some cases. –

Use global devices, for example, when a common device No. is to be used between
modules, or when actual I/O is to be handled.

3-27
About Local Devices

Reasons for using local devices

Local devices not only avoid duplicate use of device Nos. between modules, but also provide the
following advantages.

● Modules can be easily re-used


Modules that have been made can be re-used often by setting devices in modules as local
devices.
Project 1 Project 2
Register Re-use

3 ** Zero return **
@MR00014
**Zero return **
@MR00014
REDUCING PROGRAMMING MAN-HOURS

** Manual operation**
** Manual operation**

@MR00010
@MR00010
**Automatic operation**
@MR00014

**Automatic operation**

@MR00010
Module library
**Abnormality processing **
@MR00014
Zero return module

Manual operation module ** Communications control A **

Automatic operation module

Inspection process module A @MR00014

Box filling process module 3

Conveyance process module 4 ** Robot control **

@MR00014

* Double coils are not programmed


even with output instructions using
the same device No. (@MR00014)
as local devices are used.

● Programs can be developed jointly by two or more engineers


By using local devices, there is no need for each software developer to assign or manage device
Nos.
Device Nos. can be used freely in individual module/macro units.

Project Z

(engineer A) module
Main module
(engineer B) module

(engineer C) module
Joint development

3-28
About Local Devices

Column
How local devices work
Local devices are automatically assigned to part of the device area when the ladder
program is converted.

Start

Project 1
Conversion

Global devices Project 1


global device
Global
Device area 3
Main module

REDUCING PROGRAMMING MAN-HOURS


Program Local
device

Module A System devices in main module


Local Local devices in
Program
device main module
Module A system device
Macro A Module A Local
Local local device Device reserved area
Program
device Macro A system device
Macro A
local device
Free area
End

Device area of project 1

System devices
When modules/macros are used, part of the local device area is always secured.
The part of the local device area that is secured is automatically assigned for system devices.

The following types of system devices are provided:


@CR2008 : Bit that turns ON for one scan only at the start of module/macro execution
@CR2007 : Bit that turns OFF for one scan only at the start of module/macro execution
_module name: Bit that turns ON during module execution

Tip • System devices are assigned also when no local devices at


all are used in modules/macros.

Note
Try to program Nos. used in local devices packed, for
example, starting from the leading No. (0). If an
unnecessarily large No. is specified, a large part of the
device area will be secured, and a large load will be
placed on the device area.

3-29
Making Original Instructions (macros)

Making Original Instructions (macros)


The KV-1000 is provided with many exclusive instructions. However, as all of these instructions
are highly applicable, similar ladder networks sometimes appear many times depending on the
device or the system.

• Ladder program before application of macros

Project 1

3 <Inspection processing>

<Abnormality processing>
REDUCING PROGRAMMING MAN-HOURS

<Zero return>

<Manual operation>

<Communications control A>

<Robot control>

<Automatic operation A>

<Automatic box filling>

If you look at a finished


program, there are lots
of similar ladder networks,
aren't there.

3-30
Making Original Instructions (macros)

With KV-1000, ladder networks that are frequently used in a project can be given any name and
registered as macros.
Registering macros facilities programming as user ladder programs can be used as original
instructions.

Call Module 1

Macro A call instruction


Macro A

Module 2
Call
Macro A call instruction
3
Register
Module 3

REDUCING PROGRAMMING MAN-HOURS


Call Macro A call instruction

If you register frequently


used networks in advance
as macros, they can be
used countless times in
Oh, I see...
the same way as other
ladder instructions.

• Ladder program after application of macros

Project 1
<Inspection processing>
<Abnormality processing>
<Zero return>
<Manual operation>

Macro A

<Communications control A>


<Robot control>
<Automatic operation A>
<Automatic box filling>
Macro A

Macro A

Macro A

Macro A

Macro A

3-31
Making Original Instructions (macros)

When macros are used

● The number of man-hours required for entering ladder programs can be reduced
If you register a ladder network that is frequently used in a project as a macro, the registered
ladder network can be used by simply calling up the macro.

3
REDUCING PROGRAMMING MAN-HOURS

Drag-and-drop

The macro call instruction can be programmed by simply dragging-and-dropping the macro in the
[macro palette].

● Networks can be easily corrected


In conventional programming, correcting a frequently used ladder network is extremely troublesome
as all modules that use that network must be corrected.

<Manual operation>
I've got to correct this ...

Corrected

Though making the changes itself is not that difficult a task,

3-32
Making Original Instructions (macros)

the same correction is required on all networks if the same network is used a lot.

<Manual operation> <Robot control> <Automatic box filling> <Automatic operation A>

REDUCING PROGRAMMING MAN-HOURS


What!
I have to correct
all of this?

If the ladder network is registered as a macro, all networks will be corrected by merely correcting
that macro ladder network.
Macro A Macro A

Corrected

All you have to do is to correct the macro network. You do not have to correct the ladder network of the called module.

<Manual operation> <Robot control> <Automatic box filling> <Automatic operation A>

Macro A

Macro A Macro A
Macro A

Macro A

3-33
Making Original Instructions (macros)

Macros use arguments

When you call a macro, specify the name of the macro and the numerical values or device Nos. to be
processed in that macro at the same time.
The numerical values or device Nos. to be handed over to this macro are called "arguments".
The provision of arguments increases the applicability and re-usability of the macro.

Module 1
...

MCALL Macro A
Call
3 Execution condition
#50 DM01000
...
REDUCING PROGRAMMING MAN-HOURS

Argument 1 Argument 2

Macro A
When you call a macro,

...
use the specified devices #50
and values in the ladder
program in the macro. @CR2008 MOV
Argument 1 @DM00000

DM01000

CR2002 @DM00000 Argument 2 @DM00004


LDA ADD STA
...

Column
Up to ten arguments can be specified.
Arguments can be specified when the macro is used. Though the number of arguments is
determined by the ladder in the macro, up to ten can be specified.

When calling a macro having ten arguments

MCALL Macro B When calling a macro


that does not use
Argument 1 Argument 2 Argument 3 arguments, there is no
#10 #20 #30
need to specify the
Argument 4 Argument 5 Argument 6 arguments.
#40 #50 #60

Argument 7 Argument 8 Argument 9


#70 #80 #90

Argument 10
#100

KV-1000 Series Programming Manual "3-2 Before You Start Using Macros"

3-34
Making Original Instructions (macros)

Types of macros

There are two types of macros: "sub-routine type macros" and "self-hold type macros."

● Sub-routine type macro


"Sub-routine type macros" are called by the MCALL macro call instruction and are executed for
the duration that the execution condition of the MCALL macro call instruction is ON.
Module 1

Macro A #1
Execution condition:
ON state 3
MCALL Macro A

REDUCING PROGRAMMING MAN-HOURS


Execution condition:
OFF state
MCALL Macro A

Macro A #2

The above ladder diagram is an example of calling the same sub-routine type macro twice in a
single module.
"Macro A #1" is executed as the execution condition is ON and continues to be executed until the
execution condition turns OFF.
"Macro A #2" is not executed as the execution condition is OFF. The macro stands by to be
executed until the execution condition turns ON.

● Operation when execution of sub-routine type macros is stopped


All ladder networks in the macro are executed* by OFF conditions for one scan only in which the
execution condition of the MCALL macro call instruction turned OFF. They are no longer executed
from the following scan.
* "Execution by OFF conditions" is the same operation as when the MC master control instruction
turns OFF.
KV-1000 Series Instruction Reference Manual "MC Master Control (MCR) Instruction"
<Illustration of how sub-routine type macros are executed>

1 scan 1 scan 1 scan 1 scan 1 scan

Execution condition
OFF ON ON OFF OFF
for calling macro A

Macro A Stop Executed Executed Execution at OFF condition Stop

3-35
Making Original Instructions (macros)

● Self-hold type macro


With "self-hold type macros," the MSTRT master start instruction is used for calling the macro,
and the MEND macro end instruction is used for stopping the macro.
Once the MSTRT master start instruction turns ON, execution of the called macro is started, and
operation is continued until the MEND macro end instruction is executed regardless of the state
(ON/OFF) of the subsequent macro start instruction.
Module 1

Macro A #1
Execution condition:
ON state
3 MSTRT Macro A

MEND
REDUCING PROGRAMMING MAN-HOURS

Execution condition:
OFF state
MSTRT Macro A
Macro A #2

MEND

The above ladder diagram is an example of calling the same macro twice in a single module.
"MacroA #1" monitors the moment that the execution conditions turns ON and then starts
operating. Though operation is continued even if the execution condition turns OFF, the macro is
no longer executed when the MEND macro end instruction in "macroA #1" is executed.
"MacroA #2" is not executed as the execution condition is OFF. The macro stands by to be
executed until the execution condition turns ON.

● Operation when execution of self-hold type macros is stopped


All ladder networks in macros are executed* by OFF conditions at the scan following the scan in
which the execution condition of the MEND macro end instruction turned ON, and are no longer
executed from the next scan onwards.
The MEND macro end instruction is ignored and the macro continues to be executed if the MSTRT macro
start instruction was being when the MEND macro end instruction was executed.
* "Execution by OFF conditions" is the same operation as when the MC master control instruction turns OFF.
KV-1000 Series Instruction Reference Manual "MC Master Control (MCR) Instruction"

1 scan 1 scan 1 scan 1 scan 1 scan 1 scan

Execution condition *2 *3
OFF ON *1 *1 OFF OFF
for calling macro A

Execution condition
of MEND instruction - OFF OFF ON *1 -
in macro A

Macro A Stop Executed Executed Executed Execution at OFF condition Stop

*1: Operation is not affected in either of the ON/OFF states.


*2: Be sure to set to OFF. Program execution is continued with the MEND instruction ignored until the state changes to OFF.
*3: Execution of the macro is started if the state is ON.
3-36
Making Original Instructions (macros)

Column
About macro exclusive instructions
When macro exclusive instructions are used, call (execution)/stop of macros can be
controlled from the ladder program.
● Call sub-routine type macro: MCALL macro call instruction
Ladder program
Execution condition MCALL Macro name

Argument 1 Argument 2 Argument 3

Input method
M C A L L Macro name Argument 1 Argument 2 ... Enter 3
• Description of operation

REDUCING PROGRAMMING MAN-HOURS


The specified macro is called only for the duration that the execution condition is ON.
Execution of the called macro is started immediately from the scan in which it was called.
When the execution condition turns OFF, the program in the macro is executed by OFF
conditions at the scan in which the execution condition turned OFF, and execution is stopped
from the next scan onwards.
• Precautions
Only sub-routine type macros are called by the MCALL macro call instruction.
● Self-hold type macro call: MSTRT macro start instruction
Ladder program
Execution condition MSTRT Macro name

Argument 1 Argument 2 Argument 3

Input method
M S T R T Macro name Argument 1 Argument 2 ... Enter

• Description of operation
The specified macro is called when the execution condition turns ON. Execution of the
called macro is started immediately from the scan in which it was called.
The called macro continues to execute without any need to hold the execution condition
until the MEND macro end instruction is executed.
• Precautions
Only self-hold type macros are called by the MSTRT macro start instruction.
● Self-hold type macro stop: MEND macro end instruction
Ladder program Input method
Execution condition MEND
M E N D Enter

• Description of operation
The MEND (macro end) instruction is programmed in self-hold type macros. When the
MEND macro end instruction programmed in a macro is executed, the macro is executed by
the OFF condition for the next scan only, and the execution of the macro is stopped.
• Precautions
Execution of the macro does not stop if the MSTRT macro start instruction is in an ON
state when the MEND macro end instruction is executed.
KV-1000 Series Instruction Reference Manual

3-37
Procedure for Using Macros

Procedure for Using Macros


The following describes the procedure for using macros.

STEP1 Extract frequently used (scheduled to be used) processing and functions in the program.

Study which processing or functions are considered to be frequently used. Also study factors such
as the applicability of the macro and whether or not the same program has been written in the past.

3 STTEP2 Determine the type of macro.

Determine the type of macro to set, sub-routine type or self-hold type, from the operation and processing content.
The type of macro may be provisionally determined as it can be changed later.
REDUCING PROGRAMMING MAN-HOURS

STEP3 Create the macro.

Create the macro. At this time, enter the macro name and macro type.

STEP4 Write the program.

Write the ladder program to the macro you have made. At this time, determine the number of
arguments.

STEP5 Register the arguments.

Register the type and name of the arguments written in the ladder program.

STEP6 To call a macro you have made

The macro can now be used. Use the macro call instruction to call the macro.

Completion of macro setup

3-38
Procedure for Using Macros

STEP1 Extract frequently used processes and functions in the program.


Study whether or not programs for functions or processes, that are to be
frequently used in the program you are to make from here on, must be
STEP1
turned into macros. Extract frequently
Also study this for programs for functions or processes that are likely to be used processes and
functions in the program.
utilized in other project, etc. in the future.

STEP2 Determine the type of macro.


Determine which type of macro is to be adopted for the processes or
functions that you have extracted according the details of operation.
Refer to the table below. (The macro type can also be changed later.) STEP2 3
Determine the
Sub-routine type macro Self-hold type macro
type of macro.

REDUCING PROGRAMMING MAN-HOURS


• When the result of having processed in • When the result of having processed in
a macro is required immediately by the a macro is not required immediately by
call side program (to end processing at the call side program (when multiple
the scan in which the macro is called) scans are required until completion of
• To execute the macro only for the macro processing)
duration that the macro is being called • To perform processing automatically
• To complete processing (e.g. operation after the macro is called
processing) within a single scan • To execute processing over multiple
scans by using timer or other STEP3
processing Make the macro.

Imagine a "sub-routine type macro" to be like a crane.


The crane moves for the duration that the buttons in the crane's
control box are held down (i.e. execution condition turns ON).

Imagine a self-hold type macro to be like the shutte


STEP4
in a warehouse. Once the "Open" button is pressed (i.e. execution
condition turns ON), the shutter operates until it is fully opened. Make the
There is no need to keep the button held down. program.

STEP5

Register the arguments.

STEP6
To call a macro
you have made

3-39
Procedure for Using Macros

STEP3 Create the macro.


Select {Modules/macros(M)}→{New macro(M)} from the menu.
Different Procedure • Select {Edit macro(M)}→{New macro(N)} from the menu that
STEP1
Extract frequently appears by right-clicking in the [Ladder edit] window.
used processes and
functions in the program.
• Click the icon on the tool bar.

3 STEP2
Determine the
type of macro.
REDUCING PROGRAMMING MAN-HOURS

The [New macro] dialog box is displayed. Enter the macro name.

STEP3
Make the macro.
Enter the macro name here.

STEP4
Make the Next, select the type of macro.
program.

STEP5 Select the type of macro.

Register the arguments.

STEP6
To call a macro
you have made When you have finished
entering,click the "OK" button.

3-40
Procedure for Using Macros

STEP1
Extract frequently
used processes and
functions in the program.

STEP2
3
Determine the
type of macro.

REDUCING PROGRAMMING MAN-HOURS


STEP3
A new sub-routine type
macro* named "MACRO_A" Make the macro.
is made.

* Self-hold type macros also can be created in the same way.

Column STEP4
Make the
About renaming macros program.

Macros can be easily renamed in the [Module/macro properties]


dialog box. Let's give macros a name that allows their content to
be easily recognized so that they can be easily used in other
projects.
The macro type can also be changed between sub-routine type ←→
self-hold type. STEP5

Register the arguments.


How to change
the macro is the same
as that for modules.
Let's try this
referring to
"Renaming Modules"
(page 3-16).

STEP6
To call a macro
you have made

Tip • Write macro names using up to 12 1-byte characters (six


2-byte characters).

3-41
Procedure for Using Macros

STEP4 Create the macro program.


STEP1 When you have created the macro, write the ladder program for processing
Extract frequently
used processes and that macro.
functions in the program.

● When making new programs


The programming method is the same as that for regular ladder programs.
Let's try creating the following ladder program using a sub-routine type macro.
Example Argument 1 is multiplied (MUL instruction) by 16 (constant),
and 12 is subtracted (SUB instruction), and the result is stored
3 STEP2
to argument 2.
Determine the
Formula: (argument1) x16-12=(argument2)
type of macro.
REDUCING PROGRAMMING MAN-HOURS

· Example of a ladder program (sub-routine type)

Argument 1 Argument 2
@CR2008 V0 #00016 #00012 P0
LDA MUL SUB STA

STEP3
P0 and V0 can be
Make the macro. entered in the same way as
regular devices.

· Direct entry

STEP4
Write V0 and P0 instead of writing device Nos.
Make the
program.
· By entering in the [Operand edit] dialog box
Press Alt + F11 on the keyboard.

STEP5

Register the arguments.

* This can be programmed in the same way by other input methods.

Important
STEP6 In ladder programs, arguments are annotated by a method different
To call a macro from regular devices to distinguish them from other devices.
you have made Arguments for handling constants (numerical values) are annotated
as "V0", and arguments for handling devices are annotated as "P0".

3-42
Procedure for Using Macros

● When using already created ladder programs


When there is a section of the program (same process or function) similar
to a completed program that contains a ladder program that was made
STEP1
without studying macros, let's turn that section into a macro to make the Extract frequently
program easier to understand. used processes and
functions in the program.

Select the ladder program to register as a macro.


@MR00000 @MR00001@MR00002 @R00000

MOV
#00100 @DM00000 STEP2 3
Determine the
#100 type of macro.

REDUCING PROGRAMMING MAN-HOURS


T @0000

@MR00003 @DM00001 #00016 #00012 @DM00004


LDA MUL SUB STA

@R00000 @T0000 @R00001


SET STEP3

Select the ladder program to register Make the macro.


@R00001 as a macro.

Note
Be sure to select the program in rung units.
KV-1000 Series Programming Manual "3-3 Making Macros"

STEP4

Next, select {Modules/macros(M)}→{New macro(M)} from the menu. Make the


Different Procedure program.
• Select {Edit macro(M)}→{New macro(N)} from the menu that
appears by right-clicking in the [Ladder edit] window.
• Click the icon on the tool bar.

Enter the macro name here. STEP5

Register the arguments.

The [New macro] dialog box is displayed. When you have entered the
name of the macro, click the "OK" button.
STEP6
Note To call a macro
When creating self-hold type macros, be sure to program the MEND you have made
macro end instruction in the ladder program for the macro.

3-43
Procedure for Using Macros

STEP1
Extract frequently
used processes and
functions in the program.

3 STEP2
Determine the
type of macro.
REDUCING PROGRAMMING MAN-HOURS

A new sub-routine type


STEP3
macro named "MACRO_A"
Make the macro. is made.

Enter P and V as necessary.

STEP4 Column
Make the
program. About annotation of arguments
Arguments are annotated as "P0, P1, P2 ... P9" in the case of
devices, and
as "V0, V1, V2 ... V9" in the case of constants.
For details on arguments, KV-1000 Series Programming Manual "3-2 Before You
Start Using Macros"

STEP5
About @CR2008
Register the arguments.
"@CR2008" is a contact for modules/macros
that turns ON only for one scan when a
module/macro is executed.
Besides this contact, there is also "@CR2007"
that turns OFF only for one scan when a
module/macro is executed.
STEP6 For details, "System devices" (page 3-29)

To call a macro
you have made

3-44
Procedure for Using Macros

STEP5 Register the arguments.


The title or display order (entry order) setting of arguments programmed in
macros can be changed. STEP1
Let's set the arguments for the macros created in STEP4. Extract frequently
used processes and
functions in the program.
Select {Modules/macros(M)}→{Macro argument settings(Z)} from the
menu.
Different Procedure • Select {Edit macro(M)}→{Macro argument settings(Z)} from the
menu that appears by right-clicking in the [Ladder edit] window.
• Click the icon on the tool bar.
STEP2 3
Determine the
type of macro.

REDUCING PROGRAMMING MAN-HOURS


STEP3
Make the macro.

This is the display order of the arguments. Select the display format
Write arguments in this order when of the arguments to be
programming macro call instructions. displayed on Ladder Editor. STEP4
Make the
program.

STEP5

Register the arguments.

Displays the type of argument. Append the title of the argument.


P0 to P9: Set the device to an argument. The name entered here is
V0 to V9: Set the value to an argument. displayed when the macro call STEP6
instruction is programmed.
Set argument titles within 12 To call a macro
1-byte characters you have made
(6 2-byte characters).

3-45
Procedure for Using Macros

● Writing titles
Write titles for arguments P0 and V0. In this step, enter "argument 1
device" for P0 and "argument 2 constant" for V0.
STEP1
Extract frequently After you have entered these, make sure that the titles are displayed in the
used processes and [Macro preview] dialog box.
functions in the program.

3 STEP2
Determine the
type of macro.
REDUCING PROGRAMMING MAN-HOURS

STEP3
Make the macro. The argument title is displayed.

● Changing the order of arguments


Select the argument whose order is to be changed, and change the order
by the [Disp order] button.

STEP4
Make the
program.

Select the title of the argument,


then change the order.

The order is changed.

STEP5

Register the arguments.

When you have finished setting the argument, let's click the "Preview"
button to confirm display when the ladder is displayed.

STEP6
Tip • Macro arguments need not be set when the argument is not
To call a macro
given a title or the order is not changed.
you have made

3-46
Procedure for Using Macros

STEP6 To call a macro you have made


The macro is now completed.
If you call the macro from a module using the macro call instruction, the STEP1
macro can be used as many times you like under any conditions you like. Extract frequently
used processes and
functions in the program.
Let's call the macro you created in STEP5 from a module.

Program the macro execution


conditions.
As the macro you created is a
sub-routine type, you must
prevent the execution condition
STEP2
3
Determine the
from turning OFF until operation type of macro.

REDUCING PROGRAMMING MAN-HOURS


of the macro is completed.

Double-click on the [Ladder


edit] window. The [Instruction/macro palette] opens. Click the [Macro] tab.
STEP3

Click the Make the macro.


[Macro] tab.

Click the macro


to call.

STEP4
Make the
program.

The argument setting


is displayed.
To correct, open the
[Macro argument
settings] dialog box. STEP5

Register the arguments.

STEP6
To call a macro
you have made

3-47
Procedure for Using Macros

● Entering arguments
Specify the value or device to the argument.
Here, let's enter EM1000 to the "argument 1 device" and #30 to the
STEP1
Extract frequently "argument 2 device".
used processes and
functions in the program.

Enter the value


of the argument
referring to the
Attrib column.

3 STEP2
Determine the
type of macro.
REDUCING PROGRAMMING MAN-HOURS

STEP3
Make the macro. Tip • When a device is specified to an argument having a "value"
attribute, the argument becomes the value currently stored to
that device.

When you have entered the argument, drag-and-drop the macro in


[Instruction/macro palette] onto the [Ladder edit] window.

STEP4
Make the
program.

Drag-and-drop

STEP5

Register the arguments.

STEP6
To call a macro
you have made

3-48
Procedure for Using Macros

At this time, the macro call instruction (MCALL and MSTRT instructions)
are automatically selected according to the type of macro.
The MSTRT instruction is selected in the case of self-hold type macros.
STEP1
Extract frequently
used processes and
functions in the program.

STEP2 3
Determine the
type of macro.

REDUCING PROGRAMMING MAN-HOURS


The macro call instruction was entered.

This completes the macro call ladder program. STEP3


The macro operates for the duration that the execution condition Make the macro.
(MR01000) is ON.
Let's try confirming actual operation in Simulator or Monitor.

STEP4
The operation result is stored to EM01000
Make the
when the execution condition (MR01000) is ON.
program.

30 x 16 - 12 = 468.
STEP5
That's it Register the arguments.
The calculation's right.

STEP6
To call a macro
you have made

3-49
Procedure for Using Macros

Column

About macro passwords


Passwords can be set to prevent the details of macros from being changed by
unauthorized personnel.
When a password is set, personnel other than the administrator (i.e. those who do not
know the password) cannot display or edit macro programs.

● Setting the password


3 Display the properties of the macro to set the password to, and click the "Set password"
button.
REDUCING PROGRAMMING MAN-HOURS

Right-click to display Click the "Set password" button


the menu. in properties.

Set the password. Enter passwords using one to six 1-byte alphanumeric characters.

Enter within 6 1-byte alphanumeric characters.

When you have finished setting the password, click the "OK" button.
The password will be enabled the next time that KV STUDIO is started up.

KV-1000 Series Programming Manual "3-3 Making Macros"

3-50
APPENDICES

1 KV-1000 Error Message Lists . . . . . . . . . . . . . . . . . . . A-2


2 Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . A-5

A-1
1 KV-1000 Error Message Lists
The following describes error messages and remedies to take when an error message is dis-
played.
When the following errors occur, change the mode from the Run mode to the Prog mode, and
remedy the error.

PLC Unit Errors

These errors are displayed when an error occurs on the KV-1000 unit.
No. Message Cause Remedy
The number of nested sub-routines This error occurs during ladder execution. Review the
10 CALL Nest exceeds the limit. ladder paying attention to how sub-routines are used.
The number of nested FOR to This error occurs during ladder execution. Review the
11 FOR Nest NEXT instructions exceeds the ladder paying attention to how the FOR to NEXT
limit. instructions are used.
Interrupts exceeding the limit This error occurs during ladder execution. Review the
12 INT Nest occurred simultaneously. ladder paying attention to how the INT instruction is used.
This error occurs during ladder execution. Review the
The number of nested MPS to MPP
13 MPS Nest ladder paying attention to how the MPS to MPP instructions
instructions exceeds the limit.
are used.
This error occurs during conversion. Limit the number of
The number of BREAK instructions
14 BREAK BREAK instructions between FOR to NEXT to within the
exceeds the limit.
specified limit.
Clear the error, and turn the unit ON again. If this error
15 Convert A system error occurred.
occurs frequently, contact your agent.
The object size of the ladder is
19 Object Size exceeded. Reduce the size of the ladder program. The size of the
Code size of the ladder exceeded ladder program can be checked on KV STUDIO.
20 Code Size the capacity.
This error occurs during ladder execution. Review the
The number of macros exceeds the
22 MACRO Nest ladder paying attention to how the macro instruction is
nesting level.
used.
23 Illegal Int
24 Illegal Macro
• Clear the error, and turn the unit ON again. If this error
25 Illegal Pointer A system error occurred. occurs frequently, contact your agent.
26 Illegal Address
27 Illegal Object
Review the following to check that the scan time has not
been exceeded:
• Make sure that there are not too many repeated FOR to
NEST instructions, for example.
• Make sure that jump instructions such as CJ/NCJ to
LABEL instructions have been programmed correctly.
30 Scan Time Over Scan time is 300 ms or more.
• Make sure that program call instructions such as CALL
and MCALL have been programmed correctly.
• Make sure that long-processing time instructions such
as FMOV, WSR and MAX are programmed correctly.
• Make sure that interrupt programs are not being
executed at a high frequency.

Clear the error, and turn the unit ON again. If this error occurs
31 Ladder Stack Over A system error occurred.
frequently, contact your agent.
The ladder program is not Register the ladder program before operating the main
40 No Ladder registered. unit.
The settings of extension/special
50 Unit Checksum units is damaged. Use the Ladder Support software or Memory Card to
The unit setup information is not register unit setup information to the KV-1000 main unit.
51 Configure set.

A-2
1 KV-1000 Error Message Lists

No. Message Cause Remedy


Extension/special unit is not
actually set even though they are Turn the KV-1000 OFF, then connect the Expansion or
52 No Unit Connection set to ON in the unit setup Special Unit set in Unit Editor.
information.
Bus communications may be down Remove any sources of noise. If this error occurs
53 S-Unit BSI Timeout due to noise. frequently, contact your agent.
The actual number of connected
units differs from the number of
54 Unit Number expansion/special units set in Unit
Editor. Turn the KV-1000 OFF, then connect the Expansion or
Special Unit set in Unit Editor.
The actual unit type differs from the
55 Unit Type type of expansion/special units set in
Unit Editor.
Bus communications may be down Remove any sources of noise. If this error occurs
56 Extend BusComm Error due to noise. frequently, contact your agent.

57 No End Unit The End Unit is not connected. Turn the KV-1000 OFF, and connect the End Unit.

80 F-ROM Damaged Flash ROM abnormality


Contact your agent.
81 S-RAM Damaged Hardware malfunction
The voltage of the backup battery
83 Low Battery Replace the backup battery.
has dropped.
The content (CM, DM, EM, FM, R,
CR, LR, T, C, CTH, and CTC Replace the backup battery, and execute an SRAM clear.
84 S-RAM Backup current values) of RAM is corrupted Only the device values and alarm values are cleared. The
as the voltage of the backup ladder program is not cleared.
battery has dropped.
The clock value may be damaged
Replace the backup battery, check the clock value, and
85 RTC Low Voltage due to the drop in the backup
set the clock again as required.
battery voltage.
Check the file system of the Memory Card.
The Memory Card may be
Check the file system using the chkdsk at the Windows
damaged. communications may be
87 Memory Card Error command prompt.
down due to electromagnetism or
(Ex) When Memory Card is the E: drive
noise.
C: \WINDOWS>CHKDSK E:
Remove the Memory Card by the correct procedure.
The Memory Card was removed
88 Memory Card Removed KV-1000 Series User's Manual "Loading and
while it was being accessed.
Removing a Memory Card from the KV-1000"
Handle the Memory Card by the correct handling
The power was turned OFF during procedure.
89 Memory Card PowerOFF according of the Memory Card. KV-1000 Series User's Manual "Precautions When
Using a Memory Card"
Multiple operations were executed
90 Memory Card Busy before accessing of the Memory Wait until the Memory Card has finished being accessed.
Card was completed.
118 Illegal Data
120 Watch Dog Timer
121 Stack Overflow
A system error occurred.
122 System Error
Clear the error, and turn the unit ON again. If this error
123 Device Range occurs frequently, contact your agent.
124 Resource
The number of errors that occurred
125 Error Buffer Overflow in the system exceeded the limit.
126 Error Buffer Invalid A system error occurred.

A-3
1 KV-1000 Error Message Lists

No. Message Cause Remedy


Autoload from the Memory Card
failed for the following reasons:
• Write protect is set by the
• Cancel write protection, and transfer the autoload files
MEMSW instruction in the
to the KV-1000 main unit from the Memory Card.
127 AutoLoad program on the KV-1000 main
• Transfer files matched to the KV-1000 main unit's
unit.
configuration.
• There is a problem in the details
stored to files on the Memory
Card.
Clear the error, and turn the unit ON again. If this error
255 No Error Message A system error occurred.
occurs frequently, contact your agent.

A-4
2 Index
Ending the Monitor .............................................. 2-43
Symbols Entering arguments ............................................. 3-48
Error ...................................................................... A-2
@ (at mark) ......................................................... 3-27 Error messages ................................................... 2-41
@CR2007 ........................................................... 3-29 Every-scan module ........................................ 3-6, 3-7
@CR2008 .................................................. 3-29, 3-44 Examples of how to make modules .................... 3-13
Execute 1 scan ................................................... 2-55
Execute 1 step .................................................... 2-54
A Expanded data memory ...................................... 1-15
Expansion Unit functions .................................... 1-13
About the execution order of modules ................ 3-21
Actual wiring diagram ............................................ 2-2
Adding units ........................................................ 2-17 G
AND networks ..................................................... 2-31
Arguments .................................................. 3-34, 3-44 Global device area .............................................. 3-29
Auto-assign relay/DM .......................................... 2-18 Global devices .................................................... 3-27

B H
Basic ladder networks ......................................... 2-31 High-speed counter comparators ........................ 1-15
Batch-registering multiple devices ...................... 2-49 High-speed counter comparators (contacts) ....... 1-14
Bit devices ........................................................... 1-14 How local devices work ....................................... 3-29
Break conditions ................................................. 2-56 How to enter instructions .................................... 2-25
break contacts ..................................................... 2-31 How to register arguments .................................. 3-45
Building/setting up a KL system .......................... 2-21

I
C
Index register ...................................................... 1-15
Calling macros .................................................... 3-47 Initialization module ..................................... 3-6, 3-12
Canceling self-hold networks .............................. 2-31 Input relays ......................................................... 1-14
Cell ...................................................................... 2-23 Instruction/macro palette ..................................... 2-25
[Change device values] window .......................... 2-52 Internal auxiliary relays ....................................... 1-14
Changing the order of arguments ....................... 3-46
Changing the setting value/current value of
timers and counters ....................................... 2-50 J
Changing the state of bit devices ........................ 2-50
Communication method other than USB ............ 2-38 Joint development by two or more engineers ..... 3-28
Condition control ................................................... 1-5
Connection line ................................................... 2-28
Continuous scan execution ................................. 2-55 K
Continuous step execution ......................... 2-55, 2-56
Control memory .................................................. 1-15 KV STUDIO .................................................. 2-6, 2-12
Control relays ...................................................... 1-14 KV-1000 .........................................1-2, 1-4, 1-8, 1-10
Conversion .......................................................... 2-30
Counters (contacts) ............................................. 1-14
Counters (current value/setting value) ................ 1-15 L
CPU Unit internal functions ................................. 1-13
Creating macro programs ................................... 3-42 Ladder edit window ...................................... 2-6, 2-22
Cursor ................................................................. 2-23 Ladder Editor ............................................... 2-7, 2-10
Ladder Monitor .................................................... 2-44
Ladder program ...............................1-6, 1-9, 2-2, 2-3
D Latch relays ......................................................... 1-14
Local device reserved area ................................. 3-29
Data memory ...................................................... 1-15 Local devices ...................................................... 3-26
Deleting units ...................................................... 2-17
Device breaks ..................................................... 2-57
Device comment ................................................. 2-32 M
Macro ......................................................... 1-12, 3-30
E Macro exclusive instructions ............................... 3-37
Macro passwords ................................................ 3-50
End of program transfer ...................................... 2-42 Macro preview ..................................................... 3-46

A-5
2 Index

make contacts ..................................................... 2-24 Registration Monitor ............................................ 2-46


Making new macros ............................................ 3-40 Relay control ......................................................... 1-7
Making new modules .......................................... 3-14 Renaming macros ............................................... 3-41
Making new project ...................................... 2-8, 2-14 Renaming modules ............................................. 3-16
Manually assign relay/DM ................................... 2-19 Reset priority type self-hold network ................... 2-37
MCALL (macro call) instruction .................. 3-37, 3-49 Run mode ........................................................... 2-39
MDSTOP (module stop) instruction ............. 3-9, 3-23 Rung breaks ........................................................ 2-56
MDSTRT (module start) instruction ............. 3-9, 3-22 Rung comments .................................................. 2-35
Memory Card slot ................................................ 1-11
MEND (macro end) instruction ............................ 3-37
MMC (multi-media card) ..................................... 1-11 S
Mnemonic list ...................................................... 2-54
Module library ....................................................... 3-5 Sample program using modules ......................... 3-25
Module start (call) instruction ................................ 3-9 Saving projects ................................................... 2-15
Module stop (end) instruction ................................ 3-9 Scan ...................................................................... 2-4
Module/macro properties .................................... 3-18 Scan time ....................................................... 2-4, 2-5
Modules ....................................................... 1-12, 3-2 Scan time over ...................................................... 2-4
Monitor ......................................................... 2-7, 2-43 SD Memory Card ................................................ 1-11
Monitor functions ................................................. 2-11 Self-hold networks .............................................. 2-31
MSTRT (macro start) instruction ................ 3-37, 3-49 Self-hold type macro .................................. 3-36, 3-39
Sequence circuit ................................................... 1-9
Sequence control ........................................... 1-3, 1-5
N Sequence diagram ................................................ 2-3
"Set password" button ......................................... 3-50
NC (normally closed) contacts ............................ 2-31 Set priority type self-hold network ....................... 2-36
NO (normally open) contacts .............................. 2-24 Setting the module execution order .................... 3-19
Normally closed contact ...................................... 2-31 Simulator ...................................................... 2-7, 2-53
Normally open contact ........................................ 2-24 Simulator functions ............................................. 2-11
Split programming ............................................... 1-12
Standby module ............................................. 3-6, 3-8
O Starting the Monitor ............................................. 2-43
Starting up modules ............................................ 3-22
OFF processing of modules ................................ 3-24 Stopping modules ............................................... 3-23
Operand edit dialog box ...................................... 2-24 Sub-routine type macro .............................. 3-35, 3-39
Operation when execution of self-hold type Switching the Editor screens ............................... 3-18
macros is stopped .......................................... 3-36 System devices ................................................... 3-29
Operation when execution of sub-routine type
macros is stopped .......................................... 3-35
OR networks ....................................................... 2-31 T
Output relays ....................................................... 1-14
Output window ..................................2-30, 2-41, 2-42 Temporary data memory ..................................... 1-15
Time chart ........................................................... 2-51
Time limit control ................................................... 1-5
P Timers (contacts) ................................................ 1-14
Timers (current value/setting value) .................... 1-15
PLC ................................................................ 1-2, 1-4 [Transfer program] dialog box ............................. 2-40
PLC Unit Errors .....................................................A-2 Transferring programs ........................................ 2-42
PLC-based control ................................................ 1-7 Turning already created ladder programs into
Printing system configuration diagrams .............. 2-21 macros ........................................................... 3-43
Procedure for using macros ................................ 3-38 Turning bit devices ON/OFF ............................... 2-45
Procedure for using modules .............................. 3-10 Types of macros ................................................. 3-35
Prog mode .......................................................... 2-42 Types of module ................................................... 3-6
Program size ....................................................... 1-10 Types of sequence control .................................... 1-5
Programmable controller ....................................... 1-2
Programming without modules ........................... 3-13
Projects ............................................................... 2-13 U
Undo ................................................................... 2-29
R [Unit configuration] tab ........................................ 2-16
Unit Editor ............................................. 2-7, 2-9, 2-16
Reasons for using local devices ......................... 3-28 Unit error ............................................................... A-2
Redo ................................................................... 2-29 [Unit selection] tab .............................................. 2-16
Reducing man-hours required for entry .............. 3-32 [Unit setup] tab ........................................... 2-16, 2-19
Registering devices ............................................. 2-48 USB ..................................................................... 2-38
A-6
2 Index

W
Word devices ...................................................... 1-15
Workspace .......................................................... 3-15
Writing programs to the PLC ............................... 2-39

A-7
Revision History
Printing Date Version Details of Revision

February 2005 Initial version


WARRANTIES AND DISCLAIMERS:
(1) KEYENCE warrants the Products to be free of defects in materials and
workmanship for a period of one (1) year from the date of shipment. If
any models or samples were shown to Buyer, such models or samples
were used merely to illustrate the general type and quality of the
Products and not to represent that the Products would necessarily
conform to said models or samples. Any Products found to be defective
must be shipped to KEYENCE with all shipping costs paid by Buyer or
offered to KEYENCE for inspection and examination. Upon examination
by KEYENCE, KEYENCE, at its sole option, will refund the purchase
price of, or repair or replace at no charge any Products found to be
defective. This warranty does not apply to any defects resulting from any
action of Buyer, including but not limited to improper installation,
improper interfacing, improper repair, unauthorized modification,
misapplication and mishandling, such as exposure to excessive current,
heat, coldness, moisture, vibration or outdoors air. Components which
wear are not warranted.

(2) KEYENCE is pleased to offer suggestions on the use of its various


Products. They are only suggestions, and it is Buyer's responsibility to
ascertain the fitness of the Products for Buyer's intended use. KEYENCE
will not be responsible for any damages that may result from the use of
the Products.

(3) The Products and any samples ("Products/Samples") supplied to Buyer


are not to be used internally in humans, for human transportation, as
safety devices or failsafe systems, unless their written specifications
state otherwise. Should any Products/Samples be used in such a
manner or misused in any way, KEYENCE assumes no responsibility,
and additionally Buyer will indemnify KEYENCE and hold KEYENCE
harmless from any liability or damage whatsoever arising out of any
misuse of the Products/Samples.

(4) OTHER THAN AS STATED HEREIN, THE PRODUCTS/SAMPLES ARE


PROVIDED WITH NO OTHER WARRANTIES WHATSOEVER. ALL
EXPRESS, IMPLIED, AND STATUTORY WARRANTIES, INCLUDING,
WITHOUT LIMITATION, THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE, AND NON-INFRINGEMENT
OF PROPRIETARY RIGHTS, ARE EXPRESSLY DISCLAIMED. IN NO
EVENT SHALL KEYENCE AND ITS AFFILIATED ENTITIES BE LIABLE
TO ANY PERSON OR ENTITY FOR ANY DIRECT, INDIRECT, INCIDENTAL,
PUNITIVE, SPECIAL OR CONSEQUENTIAL DAMAGES (INCLUDING,
WITHOUT LIMITATION, ANY DAMAGES RESULTING FROM LOSS OF
USE, BUSINESS INTERRUPTION, LOSS OF INFORMATION, LOSS OR
INACCURACY OF DATA, LOSS OF PROFITS, LOSS OF SAVINGS,
THE COST OF PROCUREMENT OF SUBSTITUTED GOODS, SERVICES
OR TECHNOLOGIES, OR FOR ANY MATTER ARISING OUT OF OR IN
CONNECTION WITH THE USE OR INABILITY TO USE THE PRODUCTS,
EVEN IF KEYENCE OR ONE OF ITS AFFILIATED ENTITIES WAS
ADVISED OF A POSSIBLE THIRD PARTY'S CLAIM FOR DAMAGES
OR ANY OTHER CLAIM AGAINST BUYER. In some jurisdictions, some
of the foregoing warranty disclaimers or damage limitations may not
apply.

BUYER'S TRANSFER OBLIGATIONS:


If the Products/Samples purchased by Buyer are to be resold or
delivered to a third party, Buyer must provide such third party with a copy
of this document, all specifications, manuals, catalogs, leaflets and
written information provided to Buyer pertaining to the Products/Samples
©KEYENCE CORPORATION, 2005 KV-1000-NM 0014-1 Printed in Japan

You might also like