![Galil Motion Control DMC-42 0 Series Скачать руководство пользователя страница 140](http://html1.mh-extra.com/html/galil-motion-control/dmc-42-0-series/dmc-42-0-series_user-manual_3267467140.webp)
Example- Output Bit
The Output Bit (OB) instruction is useful for setting or clearing outputs depending on the value of a variable, array,
input or expression. Any non-zero value results in a set bit.
Instruction
Interpretation
OB1, POS
Set Output 1 if the variable POS is non-zero. Clear Output 1 if POS equals 0.
OB 2, @IN [1]
Set Output 2 if Input 1 is high. If Input 1 is low, clear Output 2.
OB 3, @IN [1]&@IN [2]
Set Output 3 only if Input 1 and Input 2 are high.
OB 4, COUNT [1]
Set Output 4 if element 1 in the array COUNT is non-zero.
The output port can be set by specifying an 16-bit word using the instruction OP (Output Port). This instruction
allows a single command to define the state of the entire 16-bit output port, where bit 0 is output 1, bit1 is output2
and so on. A 1 designates that the output is on.
Example- Output Port
Instruction
Interpretation
OP6
Sets outputs 2 and 3 of output port to high. All other bits are 0. (21 + 22 = 6)
OP0
Clears all bits of output port to zero
OP 255
Sets all bits of output port to one.
(20 + 21 + 22 + 23 + 24 + 25 + 26 + 27)
The output port is useful for setting relays or controlling external switches and events during a motion sequence.
Example - Turn on output after move
Instruction
Interpretation
#OUTPUT
Label
PR 2000
Position Command
BG
Begin
AM
After move
SB1
Set Output 1
WT 1000
Wait 1000 msec
CB1
Clear Output 1
EN
End
Digital Inputs
The general digital inputs for are accessed by using the @IN[n] function or the TI command. The @IN[n] function
returns the logic level of the specified input, n, where n is a number 1 through 48.
Example - Using Inputs to control program flow
Instruction
Interpretation
JP #A,@IN[1]=0
Jump to A if input 1 is low
JP #B,@IN[2]=1
Jump to B if input 2 is high
AI 7
Wait until input 7 is high
AI -6
Wait until input 6 is low
Example - Start Motion on Switch
Motor A must turn at 4000 counts/sec when the user flips a panel switch to on. When panel switch is turned to off
position, motor A must stop turning.
Solution: Connect panel switch to input 1 of DMC-42x0. High on input 1 means switch is in on position.
Chapter 7 Application Programming ▫ 136
DMC-42x0 User Manual
Содержание DMC-42 0 Series
Страница 85: ...Chapter 6 Programming Motion 81 DMC 42x0 User Manual Figure 6 14 ECAM cycle with Z axis as master...
Страница 195: ...ICM 2900 PCB Layout Appendices 191 DMC 42x0 User Manual...
Страница 205: ...CB 50 100 Drawings Appendices 201 DMC 42x0 User Manual...
Страница 206: ...Appendices 202 DMC 42x0 User Manual...
Страница 207: ...Appendices 203 DMC 42x0 User Manual...
Страница 208: ...Appendices 204 DMC 42x0 User Manual...
Страница 209: ...Appendices 205 DMC 42x0 User Manual...
Страница 210: ...Appendices 206 DMC 42x0 User Manual...
Страница 211: ...Appendices 207 DMC 42x0 User Manual...
Страница 214: ...CB 50 80 Drawing Appendices 210 DMC 42x0 User Manual...
Страница 215: ...Appendices 211 DMC 42x0 User Manual...