beautypg.com

Delta Electronics Programmable Logic Controller DVP-PLC User Manual

Page 290

background image

7 Application Instructions API 50-99

D V P - P L C A P P L I C AT I O N M A N U A L

7-6

b) When the present value in C249 changes from 99 to 100, the drive contact of C249 will be On immediately. When

the execution arrives at SET Y17, Y17 will still be affected by the scan time and will output after END instruction.

M1000

DCNT

C249

K100

SET

Y17

C249

DHSCS

K100

C249

Y10

On immediately

Program Example 3:

1. High speed counter interruption:

a) Operand

D

of DHSCS instruction can designate I0□0, □ = 1 ~ 6, as the timing of interruption when the

counting reaches its target.

b) ES/EX/SS series MPU does not support high speed counter interruption.

c) SA/SX/SC series MPU supports high speed counter interruption. However, when DHSCS instruction

designates an I interruption, the designated high speed counter cannot be used in DHSCS, DHSCR, DHSZ

instructions. Misuse of high speed counter will result in error.

d) For SA/SX/SC series MPU, when the counting reaches the target, the interruption will occur. X0 is the

counter for counting input and the interruption No. is I010 (1 phase 2 inputs and A-B phase counter No. C246

~ C254 can only designate I010). X1 designates I020; X2 designates I030; X3 designates I040; X4

designates I050; X5 designates I060, totaling 6 points.

e) When the present value in C251 changes from 99 to 100 or 101 to 100, the program will jump to I010 and

execute the interruption service subroutine.

M1000

DCNT

C251

K1000

FEND

DHSCS

K100

C251

I010

M1000

Y1

IRET

END

I010

EI

2. In SA/SX/SC series MPU, M1059 is “I010 ~ I060 high speed counter interruption forbidden” flag.

3. In EH/EH2/SV series MPU, M1289 ~ M1294 are the respectively for I010 ~ I060 “high speed counter

interruption forbidden flags”, i.e. when M1294 = On, I060 interruption will be forbidden.

Interruption pointer I No. Interruption forbidden flag

Interruption pointer I No. Interruption forbidden flag

I010 M1289 I040 M1292

I020 M1290 I050 M1293

I030 M1291 I060 M1294