![Galil DMC-4040 Скачать руководство пользователя страница 168](http://html1.mh-extra.com/html/galil/dmc-4040/dmc-4040_user-manual_3282915168.webp)
the program where it was called without re-enabling the interrupt. As with any automatic subroutine, a program
must be running in thread 0 at all times for it to be enabled.
Example
A DMC-40x0 is used to jog the A and B axis. This program automatically begins upon power-up and allows the
user to input values from the main serial port terminal. The speed of either axis may be changed during motion by
specifying the axis letter followed by the new speed value. An S stops motion on both axes.
Instruction
Interpretation
#AUTO
Label for Auto Execute
speedA=10000
Initial A speed
speedB=10000
Initial B speed
CI 2
Set Port 2 for Character Interrupt
JG speedA, speedB
Specify jog mode speed for A and B axis
BGXY
Begin motion
Routine to print message to terminal
MG{P2}"TO CHANGE SPEEDS"
Print message
MG{P2}"TYPE A OR B"
MG{P2}"TYPE S TO STOP"
#JOGLOOP
Loop to change Jog speeds
JG speedA, speedB
Set new jog speed
JP #JOGLOOP
EN
End of main program
#COMINT
Interrupt routine
JP #A,P2CH="A"
Check for A
JP #B,P2CH="B"
Check for B
JP #C,P2CH="S"
Check for S
ZS1;CI2;JP#JOGLOOP
Jump if not X,Y,S
#A;JS#NUM
speedX=val
New X speed
ZS1;CI2;JP#PRINT
Jump to Print
#B;JS#NUM
speedY=val
New Y speed
ZS1;CI2;JP#PRINT
Jump to Print
#C;ST;AMX;CI-1
Stop motion on S
MG{^8}, "THE END"
ZS;EN,1
End-Re-enable interrupt
#NUM
Routine for entering new jog speed
MG "ENTER",P2CH{S},"AXIS
SPEED" {N}
Prompt for value
#NUMLOOP; CI-1
Check for enter
#NMLP
Routine to check input from terminal
JP #NMLP,P2CD<2
Jump to error if string
JP #ERROR,P2CD=2
Read value
val=P2NM
EN
End subroutine
#ERROR;CI-1
Error Routine
MG "INVALID-TRY AGAIN"
Error message
JP #NMLP
EN
End
Chapter 7 Application Programming
•
159
DMC-40x0 User Manual
Содержание DMC-4040
Страница 17: ...DMC 4080 Layout Figure 2 2 Outline of the of the DMC 4080 DMC 40x0 User Manual Chapter 2 Getting Started 8...
Страница 19: ...DMC 4040 Dimensions Figure 2 5 Dimensions of DMC 4040 DMC 40x0 User Manual Chapter 2 Getting Started 10...
Страница 20: ...DMC 4080 Dimensions Figure 2 6 Dimensions of DMC 4080 Chapter 2 Getting Started 11 DMC 40x0 User Manual...
Страница 54: ...Chapter 3 Connecting Hardware 45 DMC 40x0 User Manual...
Страница 55: ...DMC 40x0 User Manual Chapter 3 Connecting Hardware 46...
Страница 56: ...Chapter 3 Connecting Hardware 47 DMC 40x0 User Manual...
Страница 73: ...Figure 4 1 GalilTools DMC 40x0 User Manual Chapter 4 Software Tools and Communication 64...
Страница 185: ...THIS PAGE LEFT BLANK INTENTIONALLY DMC 40x0 User Manual Chapter 7 Application Programming 176...
Страница 205: ...THIS PAGE LEFT BLANK INTENTIONALLY DMC 40x0 User Manual Chapter 10 Theory of Operation 196...
Страница 220: ...Step 2 Remove ICM For DMC 4040 Proceed to Step 3 Configure Circuit Appendices 211 DMC 40x0 User Manual...
Страница 222: ...Step 2 Remove ICM s Appendices 213 DMC 40x0 User Manual...
Страница 232: ...DMC 4080 Steps 4 and 5 Step 4 Replace ICM s Appendices 223 DMC 40x0 User Manual...