3 pointers, 4 interrupt pointers – Delta DVP-ES2 User Manual

Page 128

Advertising
background image

D V P - E S 2 / S A 2 / S S 2 / S A2 / S X 2 / S E O p e r a t i o n M a n u a l - P r o g r a m m i n g

3 - 1 2

3.3 Pointers

Mnemonic Operands

Function Program

steps

P

P0~P255 Pointer

1

Controllers

ES2/EX2 SS2

SA2

SE

SX2

Explanation:

Pointer P is used with API 00 CJ and API 01 CALL instructions. The use of P does not need to start

from P0, and the No. of P cannot be repeated; otherwise, unexpected errors may occur. For other

information on P pointers, please refer to section 2.12 in this manual

Program example 1:

Ladder Diagram:

Y1

X1

P10

X0

CJ

P10

Instruction: Operation:

LD

X0

Load NO contact X0

CJ

P10

Jump to P10

:

P10

Pointer P10

LD

X1

Load NO contact X1

OUT

Y1

Drive coil Y1

3.4 Interrupt Pointers

Mnemonic Function Program

steps

I

Interrupt program pointer

1

Controllers

ES2/EX2 SS2

SA2

SE

SX2

Explanations:

A interruption program has to start with a interruption pointer (I□□□) and ends with API 03 IRET.

I instruction has to be used with API 03 IRET, API 04 EI, and API 05 DI. For detailed information on

interrupt pointes, please refer to section 2.12 in this manual

Program example:

Ladder diagram:

Instruction

code:

Operation:

EI

Enable

interruption

LD

X1 Load NO contact X1

OUT Y1 Drive

Y1

coil

:

DI

Disable

interruption

:

FEND

Main program ends

I001

Interruption pointer

LD

X2 Load NO contact X2

Y1

EI

X1

I 001

DI

FEND

Y2

X2

IRET

Allowable range
for interruption

Interruption
subroutine

Pointer of
interruption
program

OUT Y2 Drive

Y2

coil

Advertising
This manual is related to the following products: