delta dvp 14ss plc advanced commands
TRANSCRIPT
Delta DVP 14 SS
Advanced Commandswww.nfiautomation.org
nfi
BMOVUsed to move block of information between data registers.
In the following example:
D0 ~ D4 will move to D10 ~ D14 when M0 is TRUE
Command Syntax: BMOV
Exercise1. Device a ladder program that will continuously move Block of values
from D0 ~ D5 to D400 ~ D405 after every 15 minutes. This is similar to
back up of information for every 15 minutes in case of any data loss.
FMOVUsed to move information from one data register to the block of
data registers.
In the following example:
D0 will move to D10 ~ D14 when M0 is TRUE
Command Syntax: FMOV
CJ- Call JumpUsed to skip the ladder by calling the Pointer
In the following example:
When M2 is FALSE, program will behave normally.
When M2 is TRUE, the ladder from 6 to 11 will not be scanned by PLC
Command Syntax: CJ
ExerciseDevice a ladder program to skip the punching by Y0 if the object is
bigger. Use Call Jump command to skip the punching operation
ExerciseDevice a ladder program to skip the punching by Y0 if the object is
bigger. Use Call Jump command to skip the punching operation
INV- Inverse Used to invert the logic behind it
Command Syntax: INV
In ladder 0, if X0 is TRUE Y1 will be FALSE and vice versa
So ladder 2 represent NAND Gate where as ladder 7 and 11
represents NOR Gate
So basically INV is analogous NOT Gate in digital logics.
ExerciseDevice a ladder program for the following Boolean algebra: (^
represent bar (NOT) operation)
Y0 = (X0.X1)^ + (X2.X3)^
Ladder Program:
MC-MCRMaster Control – used to enable and disable the Zone of ladders
Command Syntax: MC N0
If X27 is TRUE, the zone from ladder 4 to ladder 14 will be enable and
instruction will work as per the logic
If X27 is FALSE, the zone from ladder 4 to ladder 14 will be disabled and all
OUT bits will get FALSE but the SET bit will retain it’s state.
ExerciseThere are 3 groups participating in the quiz game: pupils, high school students and professors. If
they want to get the chance of answering the question from the host, they must press the answer
button on their table first. Other groups’ pressing will be invalid if any group gets the chance
successfully
• There are 2 answer buttons for the
pupil group and professor group
and 1 answer button for the high
school student group. In order to
give preferential treatment to the
pupil group, Y0 will be ON if any
one of X0 or X1 is pressed.
However, in order to limit the
professor group,Y2 will be ON
when X3 and X4 are pressed at the
same time. For the high school
student group, Y1 will be ON when
X2 is pressed.
• If the host presses X5 (Reset NC
button), Y0, Y1 and Y2 will be OFF.
ExerciseLadder Program:
PWMUsed to generate train of Pulses
Command Syntax: PWM
When Y0 gets ON, Y1 will generate pulses with the ON time = 1 seconds
and OFF time = 0.5 sec. In other words duty cycle is 66% and cycle time is
1.5 seconds
ExerciseGenerate the train of 500 pulses for Y1. (On time 1 second
and Cycle time 1.5 seconds)
Ladder Program:
When X0 gets ON, Y1 will generate pulses with the ON time = 1
seconds and OFF time = 0.5 sec.
In ladder 9, the falling edge of Y1 will increment D1 everytime when
the pulse falling edge comes. When the number of pulses is
equivalent to 15, M0 gets TRUE and stops the train of pulses.
In ladder 21, falling edge of X0 is used to reset the M0
Retentive TimerWhich can hold the time on power failure
Command Syntax: TMR
Create a Timing application such that when X1 is pressed Y0 is ON for 10 seconds. In case
X1 is turned OFF in between or Power failure may occur. The timer should resume the time
from where it gets interrupted.
Exercise
SequencerUsed to make sequence of output by accessing word output
Command Syntax: MOV HXX K4Y0
Ladder Program:
In the ladder 0 & 6, using X0 we moved H5 and H10 to K4Y0., which
changes the states of output file and following table explains how:
Decimal Y3 Y2 Y1 Y0
5 0 1 0 1
10 1 0 1 0
SequencerUsed to make sequence of output by accessing word output
Command Syntax: MOV HXX K4Y0
Exercise 1Turn on the output in sequence
shown
Ladder Program:
SequencerUsed to make sequence of output by accessing word output
Command Syntax: MOV HXX K4Y0
Exercise 2Turn on the output in the
sequence shown
Ladder Program:
Step CommandUsed to perform the operation in a sequential way without
lose of steps even on power loss
Command Syntax: STL S0
ExerciseDesign a traffic light program for Y0 (Red- 5 Seconds), Y1 (Yellow- 2
seconds) and Y2 (Green- 10 seconds) using Step commands.
ExerciseDesign a traffic light program for Y0 (Red- 5 Seconds), Y1 (Yellow- 2
seconds) and Y2 (Green- 10 seconds) using Step commands.
Ladder Program:
Enabling the abnormal situation alarm and draining water from the reservoir when
the level is above the upper bound.
Enabling the abnormal situation alarm and pouring water into the reservoir when the
level is below the lower bound.
Enabling the mechanical failure alarm if the upper bound sensor X0 is still ON after
draining water for 10 minutes.
Enabling the mechanical failure alarm if the lower bound sensor X1 is still ON after
pouring water for 5 minutes.
Resetting all the alarms and valves when the level is in normal position.
Subroutine Used to perform a function multiple times by call instruction
Command Syntax: Call P0
Exercise
ExerciseLadder Program:
Compare
Command Syntax: CMP
Used to compare data (information) between two sources
First comparison value
Second comparison value
Comparison result
If K10 > D10 , Y0 = ON
If K10 = D10 , Y1 = ON
If K10 < D10 , Y2 = ON
You need to use ZRST command to reset the comparison result
When X1 is ON, CMP command is driven
and one of Y0, Y1 & Y2 is ON. When X1 is
OFF, Y0 ~ Y2 remain in previous state
Zone Compare
Command Syntax: ZCP
Used to compare data (information) between two sources
Minimum comparison
value
Max.
comparison valueComparison result
If C10 < K10 , M0 = ON
If K10 <= C10 <= K100 , M1 = ON
If C10 > K100 , M2 = ON
You need to use ZRST command to reset the comparison result
When X1 is ON, CMP command is driven
and one of Y0, Y1 & Y2 is ON. When X1 is
OFF, Y0 ~ Y2 remain in previous state
Comparison value
Exchange - XCH
Command Syntax: XCH
Used to exchange information between two data registers
When X0 is OFF--ON, content of D20 and
D40 exchange with each otherFirst Exchange data register
Second Exchange
data register
120
400
Before
Execution
D20
D40
After
Execution
120
400
Exchange - DXCH
Command Syntax: DXCH
Used to exchange double information between two data registers
When X0 is OFF--ON, content of D20 and
D40 exchange with each otherFirst Exchange data register
Second Exchange
data register
9
20
Before
Execution
D20
D21
After
Execution
8D40
4D41
8
4
9
20
Interrupts
Command Syntax: EI
Used to compare data register zone
Interrupt pointers I numbers for SS Models
External Interrupts:
I001 = X0
I101 = X1
I201 = X2
I301 = X3
Fire Alarm in the Office (Interruption Application)
Control Purpose:
Starting the alarm and sprayer when the temperature alarm
detects high temperature.
Stopping the alarm and sprayer when the alarm reset button
is pressed.
Exercise
Exercise
Exercise• In the program, the interruption pointers I001, I101 correspond to the external
input points X0, X1. When X0, X1 is ON, the subroutines corresponding to
I001, I101 will be executed.
• If the temperature in the office is normal, X0 = OFF. The temperature alarm will
not perform any action. No interruption signal is generated, and no
interruption subroutine will be executed in this case.
• If the temperature in the office is too high, X0 = ON, the temperature alarm
will be enabled. The PLC will stop the main program to execute the
interruption subroutine I001. In this case, sprayer valve Y0 and alarm Y1 will be
enabled. After the execution of I001, the program will return to the main
program and resume execution from the interruption point.
• Press the alarm reset button if the alarm situation is cleared. X1 = ON, the PLC
will stop the main program to execute the interruption subroutine I101. In this
case, sprayer Y0 and alarm Y1 will be shut down. After the execution of I101,
the program will return to the main program and resume execution from the
interruption point.
High Speed Counter Set
Command Syntax: DHSCS
Used to set the device by reading high speed input pulses typically from Encoder signal
Compare Value
High Speed Counter
NumberCompare result
When PLC RUNS, if M0 is ON, DHSCS command
starts to operate. Y0 will be ON immediately
when C235 present value stepped from 99 to 100
or 101 to 100 and be ON constantly
When C235 present value stepped from 999 to 1000, C235 will be active and Y1 will be SET.
In SS models, this instruction cannot be used more than 4 times.
Total counting frequency is 20 KHz.
High Speed Counter Set
Command Syntax: DHSCS
Used to read high speed input pulses typically from Encoder signal
U: Increasing Input
D: Decreasing Input
Memory Bit: M1235,
M1236…
In SS models, this instruction cannot be used more than 4 times.
Total counting frequency is 20 KHz.
Counting method is defined by D1022
Input
Type1- Phase 1 Input 1- Phase 2 Inputs 2- phase inputs
C235 C236 C237 C238 C241 C242 C244 C246 C247 C249 C251 C252 C254
X0 U/D U/D U/D U U U A A A
X1 U/D R R D D D B B B
X2 U/D U/D R R R R
X3 U/D R S S S
A: A phase Input
B: B phase Input
S: Start Input
R: Reset Input
Device No. Function
D1022 Use counting method of counter to
set double frequency
D1022= K1 Normal frequency mode
D1022= K2 Double frequency mode
D1022= K4 4 times frequency mode
High Speed Counter Reset
Command Syntax: DHSCR
Compare Value
High Speed Counter
NumberCompare result
When PLC RUNS, if M0 is ON, DHSCR command
starts to operate. Y0 will be OFF immediately
when C235 present value stepped from 99 to 100
or 101 to 100 and be ON constantly
When C235 present value stepped from 999 to 1000, C235 will be active and Y1 will be SET.
In SS models, this instruction cannot be used more than 4 times.
Total counting frequency is 20 KHz.
Used to reset the device by reading high speed input pulses typically from Encoder signal
Thanks
nfi
www.nfiautomation.org