![Galil DMC-4040 Скачать руководство пользователя страница 177](http://html1.mh-extra.com/html/galil/dmc-4040/dmc-4040_user-manual_3282915177.webp)
vp=@AN[1]*1000
Compute desired position
ve=vp-_TPA
Find position error
vel=ve*20
Compute velocity
JG vel
Change velocity
JP #LOOP
Change velocity
EN
End
Extended I/O of the DMC-40x0 Controller
The DMC-40x0 controller offers 32 extended I/O points which can be configured as inputs or outputs in 8 bit
increments through software. The I/O points are accessed through 1 44 pin high density connector.
Configuring the I/O of the DMC-40x0
The 32 extended I/O points of the DMC-40x0 series controller can be configured in blocks of 8. The extended I/O
is denoted as blocks 2-5 or bits 17-48.
The command, CO, is used to configure the extended I/O as inputs or outputs. The CO command has one field:
CO n
where n is a decimal value which represents a binary number. Each bit of the binary number represents one block of
extended I/O. When set to 1, the corresponding block is configured as an output.
The least significant bit represents block 2 and the most significant bit represents block 5. The decimal value can be
calculated by the following formula. n = n2 + 2*n3 + 4*n4 + 5*n5 where nx represents the block. If the nx value is
a one, then the block of 8 I/O points is to be configured as an output. If the nx value is a zero, then the block of 8 I/
O points will be configured as an input. For example, if block 4 and 5 is to be configured as an output, CO 12 is
issued.
8-Bit I/O Block
Block
Binary Representation Decimal Value for
Block
17-24
2
2
0
1
25-32
3
2
1
2
33-40
4
2
2
4
41-48
5
2
3
8
The simplest method for determining n:
Step 1.
Determine which 8-bit I/O blocks to be configured as outputs.
Step 2.
From the table, determine the decimal value for each I/O block to be set as an output.
Step 3.
Add up all of the values determined in step 2. This is the value to be used for n.
For example, if blocks 2 and 3 are to be outputs, then n is 3 and the command, CO3, should be issued.
NOTE
: This calculation is identical to the formula: n = n2 + 2*n3 + 4*n4 + 5*n5 where nx represents the block.
Saving the State of the Outputs in Non-Volatile Memory
The configuration of the extended I/O and the state of the outputs can be stored in the non-volatile flash memory
with the BN command. If no value has been set, the default of CO 0 is used (all blocks are inputs).
DMC-40x0 User Manual
Chapter 7 Application Programming
•
168
Содержание 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...