![Danfoss VLT5000 SyncPos Скачать руководство пользователя страница 120](http://html.mh-extra.com/html/danfoss/vlt5000-syncpos/vlt5000-syncpos_operating-instructions-manual_4121908120.webp)
119
MG.10.J8.02 – VLT is a registered Danfoss trade mark
Programmable SyncPos motion controller
Software Reference
■
■
■
■
■
INKEY
With the INKEY command it is possible to read a
key signal from the VLT keyboard. The parameter
entered with INKEY determines whether the program
waits unconditionally for a key signal, for a certain
period of time or not at all.
One key signal is read in per successful INKEY
command respectively. To input a string of charac-
ters it is necessary to repeat the INKEY command
(p<>0) in a loop until no further key signals exist.
Summary
Read in a key signal
Syntax
INKEY (p)
Parameter
p is the maximum waiting time, defined ...
p = 0 wait for key code
p > 0 wait of max. p milli-seconds
p < 0 no wait for key code
Return value
key code for the received character
resp –1 in case no character available
Following key codes are sent back, as long as the
key is pressed. If more than one key were pressed
simultaneously the corresponding sum of the
values will be sent back:
key:
value:
M E N U
1
QUI C K M E N U
2
DISPLAY / STATUS
8
O K
16
CANCE L
32
CHANGE DATA
128
-key
256
-key
512
-key
1024
-key
2048
START
4096
FWD. R EV.
8192
J O G
16384
STOP / RESET
32768
Combinations send the corresponding values:
OK and CANCEL
48
START and
-key
4608
NB!
The keys keep their VLT-functions, unless they
are disabled in Parameter 014–017.
A negative parameter must be given in brackets.
Command group
I / O
Cross Index
P R I NT
Chapter Fundamentals of the SyncPos program
Syntax-Example
input = INKEY 0
/* wait until key signal is read */
input = INKEY 5000
/* wait max. 5 seconds to input */
input = INKEY (-1)
/* do not wait for input */
Program sample
I NKEY_01.M
EXIT_01.M, WHILE_01.M