DMC-1500
Chapter 7 Application Programming
•
97
This simple program will issue the message “X fell short” if the X axis does not reach the commanded
position within 1 second of the end of the profiled move.
Example - Bad Command
Instruction Interpretation
#BEGIN
Begin main program
IN "ENTER SPEED", SPEED
Prompt for speed
JG SPEED;BGX;
Begin motion
JP #BEGIN
Repeat
EN
End main program
#CMDERR
Command error utility
JP#DONE,_ED<>2
Check if error on line 2
JP#DONE,_TC<>6
Check if out of range
MG "SPEED TOO HIGH"
Send message
MG "TRY AGAIN"
Send message
ZS1 Adjust
stack
JP #BEGIN
Return to main program
#DONE
End program if other error
ZS0 Zero
stack
EN1
End program and restore trippoint
The above program prompts the operator to enter a jog speed. If the operator enters a number out of
range (greater than 8 million), the #CMDERR routine will be executed prompting the operator to enter
a new number.
Example - Communication Interrupt
A DMC-1510 is used to move the X axis back and forth from 0 to 10000. This motion can be paused,
resumed and stopped via input from an auxiliary port terminal.
Instruction Interpretation
#BEGIN
Label for beginning of program
CC 9600,0,0,0
Setup communication configuration for auxiliary serial port
CI ,2
Setup communication interrupt for auxiliary serial port
MG {P2}"Type 0 to stop motion"
Message out of auxiliary port
MG {P2}"Type 1 to pause motion"
Message out of auxiliary port
MG {P2}"Type 2 to resume motion"
Message out of auxiliary port
RATE=2000
Variable to remember speed
SPX=RATE
Set speed of X axis motion
#LOOP
Label for Loop
PAX=10000
Move to absolute position 10000
BGX
Begin Motion on X axis
AMX
Wait for motion to be complete
PAX=0
Move to absolute position 0
BGX
Begin Motion on X axis
AMX
Wait for motion to be complete
Содержание 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...