
SunOS 5.5 STREAMS Modules kb(7M)
PAD3 0x70E “3” key
PAD0 0x70F “0” key
PADDOT 0x710 “.” key
PADENTER 0x711 “Enter” key
In TR_ASCII mode, when a function key is pressed, the following escape sequence is sent:
ESC[0....9z
where ESC is a single escape character and “0...9” indicates the decimal representation of
the function-key value. For example, function key R1 sends the sequence:
ESC[208z
because the decimal value of RF(1) is 208. In TR_EVENT mode, if there is a VUID event
code for the function key in question, an event with that event code is generated; other-
wise, individual events for the characters of the escape sequence are generated.
Keyboard
Compatibility Mode
kb is in “compatibility mode” when it starts up. In this mode, when the keyboard is in
the TR_EVENT translation mode, ISO 8859/1 characters from the “upper half” of the char-
acter set (that is, characters with the 8th bit set) are presented as events with codes in the
ISO_FIRST range (as defined in <sys/vuid_event.h>). The event code is ISO_FIRST plus
the character value. This is for backwards compatibility with older versions of the key-
board driver. If compatibility mode is turned off, ISO 8859/1 characters are presented as
events with codes equal to the character code.
IOCTLS The following ioctl() requests set and retrieve the current translation mode of a key-
board:
KIOCTRANS The argument is a pointer to an int. The translation mode is set to the
value in the int pointed to by the argument.
KIOCGTRANS The argument is a pointer to an int. The current translation mode is
stored in the int pointed to by the argument.
ioctl() requests for changing and retrieving entries from the keyboard translation table
use the kiockeymap structure:
struct kiockeymap {
int kio_tablemask; /∗ Translation table (one of: 0, CAPSMASK,
∗ SHIFTMASK, CTRLMASK, UPMASK,
∗ ALTGRAPHMASK, NUMLOCKMASK)
∗/
#define KIOCABORT1−1/∗Special “mask”: abort1 keystation ∗/
#define KIOCABORT2−2/∗Special “mask”: abort2 keystation ∗/
u_char kio_station; /∗ Physical keyboard key station (0-127) ∗/
u_short kio_entry; /∗ Translation table station’s entry ∗/
char kio_string[10]; /∗ Value for STRING entries (null terminated) ∗/
};
KIOCSKEY The argument is a pointer to a kiockeymap structure. The translation
table entry referred to by the values in that structure is changed.
kio_tablemask specifies which of the five translation tables contains the
modified 27 Jan 1994 7M-175
Comentários a estes Manuais