118
•
Chapter 7 Application Programming
DMC-1500
MG "Interrupt occurred"
Display message
ST XY
Stops motion on X and Y axes
#LOOP
JP #LOOP,@IN[1]=0
Loop until Interrupt cleared
JG 15000,10000
Specify new speeds
WT 300
Wait 300 milliseconds
BG XY
Begin motion on X and Y axes
RI
Return from Interrupt subroutine
Analog Inputs
The DMC-1500 provides seven analog inputs. The value of these inputs in volts may be read using
the @AN[n] function where n is the analog input 1 through 7. The resolution of the Analog-to-Digital
conversion is 12 bits. This resolution can be increased to 16 bits by specifying the -16 option when
purchasing the DMC-1500 controller. Analog inputs are useful for reading special sensors such as
temperature, tension or pressure.
The following examples show programs which cause the motor to follow an analog signal. The first
example is a point-to-point move. The second example shows a continuous move.
Example - Position Follower (Point-to-Point)
Objective - The motor must follow an analog signal. When the analog signal varies by 10V, motor
must move 10000 counts.
Method: Read the analog input and command X to move to that point.
Instruction Interpretation
#Points Label
SP 7000
Speed
AC 80000;DC 80000
Acceleration
#Loop
VP=@AN[1]*1000
Read and analog input, compute position
PA VP
Command position
BGX Start
motion
AMX After
completion
JP #Loop
Repeat
EN
End
Example - Position Follower (Continuous Move)
Method: Read the analog input, compute the commanded position and the position error. Command
the motor to run at a speed in proportions to the position error.
Instruction Interpretation
#Cont Label
AC 80000;DC 80000
Acceleration rate
JG 0
Start job mode
BGX Start
motion
#Loop
VP=@AN[1]*1000
Compute desired position
Содержание DMC-1510
Страница 6: ......
Страница 18: ...6 Chapter 1 Overview DMC 1500 THIS PAGE LEFT BLANK INTENTIONALLY...
Страница 88: ...76 Chapter 6 Programming Motion DMC 1500 Figure 6 7 Motion intervals in the Home sequence...
Страница 90: ...78 Chapter 6 Programming Motion DMC 1500 THIS PAGE LEFT BLANK INTENTIONALLY...
Страница 137: ...DMC 1500 Chapter 7 Application Programming 125 THIS PAGE LEFT BLANK INTENTIONALLY...
Страница 157: ...DMC 1500 Chapter 10 Theory of Operation 145 THIS PAGE LEFT BLANK INTENTIONALLY...
Страница 160: ...148 Appendices DMC 1500 Card Level Layout...
Страница 178: ...166 Appendices DMC 1500 ICM 1100 Drawing 1 3 4 0 0 4 4 0 2 4 0 7 0 0 4 5 3 7 0 5 7 0 2 8 5 1 0 0 1 0 1 0 7 0 1 0 0...
Страница 180: ...168 Appendices DMC 1500...
Страница 198: ...186 Appendices DMC 1500 THIS PAGE LEFT BLANK INTENTIONALLY...