![Nova Electronics MCX514 Скачать руководство пользователя страница 87](http://html1.mh-extra.com/html/nova-electronics/mcx514/mcx514_user-manual_1710400087.webp)
NOVA electronics Inc. MCX514 -
74
-
74
-
■
Example 3
Calculates the time passing through from position A (10000) to position B (55000) during X axis driving.
passing through the position A
passing through the position B
T
(
μ
sec)
Internal Timer
Timer- start
Save the timer value
Action
Activation Factor
Activation Factor
Action
Fig. 2.6-9 Example 3: Synchronous Action
【
Program Example
】
// Drive setting (constant speed driving at 10K PPS)
WR6
←
1200h Write
// Initial speed 8M PPS (maximum in specification)
WR7
←
007Ah Write
WR0
←
0104h Write
WR6
←
2710h Write
// Drive speed 10K PPS
WR7
←
0000h Write
WR0
←
0105h Write
WR6
←
0000h Write
// Logical position counter 0
WR7
←
0000h Write
WR0
←
0109h Write
// Set a specified position to MRm register
// MR0 setting (specified position A
:
10000)
WR6
←
2710h Write
// MR0 10000
WR7
←
0000h Write
WR0
←
0110h Write
// MR1 setting (specified position B
:
55000)
WR6
←
D6D8h Write
// MR1 55000
WR7
←
0000h Write
WR0
←
0110h Write
// Timer value setting
WR6
←
FFFFh Write
// Timer value 2147483647 (maximum)
WR7
←
7FFFh Write
WR0
←
0116h Write
// Interrupt setting
WR0
←
011Fh Write
// Select X axis
WR1
←
2000h Write
// D13
1 SYNC1
:
When synchronous action SYNC1 is activated
// Multi-purpose register mode setting
WR6
←
0000h Write
// D1,D0 00 M0T1,0
:
MR0 Comparative object
Logical position counter
// D3,D2 00 M0C1,0
:
MR0 Comparison condition
≧
// D5,D4 00 M1T1,0
:
MR1 Comparative object
Logical position counter
// D7,D6 00 M1C1,0
:
MR1 Comparison condition
≧
WR0
←
0120h Write
// Synchronous action setting
// Synchronous action SYNC0 setting
WR6
←
0151h Write
// D3
~
D0 0001 PREV3
~
0
:
Activation factor MRm object changed to True
// D8
~
D4 10101 ACT4
~
0
:
Action Timer-start
WR0
←
0126h Write
// Synchronous action SYNC1 setting
WR6
←
0071h Write
// D3
~
D0 0001 PREV3
~
0
:
Activation factor MRm object changed to True
// D8
~
D4 00111 ACT4
~
0
:
Action Save CT
→
MRm
WR0
←
0127h Write