NOVA electronics Inc.
MCX514 -
36
-
36
-
2.4
Multi-Purpose Register
MCX514 has four signed 32-bit multi-purpose registers (MR3~0) per axis.
Multi-purpose register can be used to compare with the current position, speed and timer, and then can read out the status which
represents comparison result and can output as a signal. In addition, it can activate a synchronous action according to comparison
result and can generate an interrupt. As an action of a synchronous action, it can load the values pre-set in multi-purpose registers
as a new speed or drive pulse number, and can save the current position or speed in multi-purpose registers.
Multi-purpose registers can be written / read anytime, by using each multi-purpose register setting command (10h~13h) and
multi-purpose register reading command (34h~37h).
The values of multi-purpose registers are undefined at reset.
2.4.1
Comparative Object and Comparison Condition
As the comparative objects of multi-purpose registers (MR3~0), the values of the logical position counter, real position counter,
current drive speed and timer can be set. The comparison condition expression to the comparative object can be selected from
≧
,
>
,
=
,
<
.
Logical Position Counter
Real Position Counter
32bit
32bit
c
o
m
p
a
re
Multi- Purpose Register × 4
MR3
~
0 32bit
Current Speed
Current Timer
31bit
S
e
le
c
to
r
Use of comparison result
・
Comparison output signal
・
Synchronous action
・
Interrupt
Comparison condition
MRm register setting command (20h)
Comparison condition
MRm register setting command (20h)
Read / Write
Read / Write
Read / Write
Read
Read
Fig. 2.4-1 Multi-Purpose Registers and Compare Function
The user can set the comparative object and comparison condition to four multi-purpose registers individually by using
multi-purpose register mode setting command (20h). Set specified bits of WR6 data writing register and write multi-purpose
register mode setting command (20h) to WR0 register, and then they will be set.
Multi-purpose register mode setting can be read out by multi-purpose register mode setting reading command (40h).
Multi-purpose register mode setting command (20h)
WR6
D7
D6
D5
D4
H
L
D15
D14
D13
D12
D11
D10
D9
D8
D3
D2
D1
D0
M0T0
M0T1
M0C0
M0C1
M1T0
M1T1
M1C0
M2T0 M1C1
M2T1
M2C0
M2C1
M3T1 M3T0
M3C0
M3C1
MR0
comparative
object
MR0
comparison
condition
MR1
comparative
object
MR1
comparison
condition
MR2
comparative
object
MR2
comparison
condition
MR3
comparative
object
MR3
comparison
condition