MAPCHAN(F) XENIX System V MAPCHAN(F)
Name
mapchan - Format of tty device mapping files.
Description
mapchan configures the mapping of information input and
output of .
Each unique channel map requires 1024 bytes (a 1K buffer)
for mapping the input and output of characters. No maps are
required if no channels are mapped.
A method of sharing maps is implemented for channels that
have the same map in place. Each additional, unique map
allocates an additional buffer. The maximum number of map
buffers available on a system is configured in the kernel,
and is adjustable via the link kit (see config(C) and
configure(C)). Buffers of maps no longer in use are
returned for use by other maps.
Example of a Map File
The internal character set used by is defined by the right
column of the input map, and the first column of the output
map in place on that line. By default, this is the 8-bit
ASCII character set which is also known as the dpANS X3.4.2
and ISO/TC97/SC2 or ISO 8859 Level I character sets. It
supports the Latin alphabet and can represent most European
languages.
Any character value not given is assumed to be a straight
mapping, only the differences are shown in the mapfile. The
left hand columns must be unique. More than one occurence
of any entry is an error. Right hand column characters can
appear more than once. This is ``many to one'' mapping.
Nulls can be produced with dead or compose sequences or as
part of an output string.
It is recommended that no mapping be enabled on the channel
used to create or modify the mapping files. This prevents
any confusion of the actual values being entered due to
mapping. It is also recommended that numeric rather than
character representations be used in most cases, as these
are not likely to be subject to mapping. Use comments to
identify the characters represented. Refer to the ascii(M)
manual page and the hardware reference manual for the device
being mapped for the values to assign.
Page 1 (printed 8/7/87)
MAPCHAN(F) XENIX System V MAPCHAN(F)
#
# sharp/pound/cross-hatch is the comment character
# however, a quoted # ('#') is 0x23, not a comment
#
# beep, input, output, dead and compose are special
# keywords and should appear as shown.
#
beep # sound the bell when errors occur
input
a b
c d
dead p
q r # p followed by q yields r.
s t # p followed by s yields t.
dead u
v w # u followed by v yields w.
compose x # x is the compose key (only one allowed).
y z A # x followed by y and z yields A.
B C D # x followed by B and C yields D.
output
e f # e is mapped to f.
g h i j # g is mapped to hij - one to many.
k l m n o # k is mapped to lmno.
All of the single letters above can be in one of these
formats:
56 # decimal
045 # octal
0xfa # hexadecimal
'b' # quoted char
'\076' # quoted octal
'\x4a' # quoted hex
All of the above formats are translated to single byte
values.
Diagnostics
mapchan performs these error checks when processing the
mapfile:
More than one compose key.
Characters mapped to more than one thing.
Syntax errors in the byte values.
Missing input or output keywords.
Dead or compose keys also occuring in the input section.
Extra information on a line.
Mapping a character to null.
Page 2 (printed 8/7/87)
MAPCHAN(F) XENIX System V MAPCHAN(F)
Characters are displayed as the 7-bit value instead of the
8-bit value. Use stty -a to verify that -istrip is set.
Make sure input is mapping to the 8859 character set, output
is mapping from the 8859 to the device display character
set. dead and compose sequences are input mapping and should
be going to 8859.
Files
/etc/default/mapchan
/usr/lib/mapchan/map.stdrom
/usr/lib/mapchan/map.*
See Also
ascii(M), keyboard(HW), lp(C), lpadmin(C), mapchan(M),
mapkey(M), parallel(HW), screen(HW), serial(HW), setkey(M),
tty(M)
Notes
Some foreign keyboards and display devices do not contain
characters commonly used by command shells and the C
programming language. Do not attempt to use such devices for
system administration tasks.
Not all terminals or printers can display all the characters
that can be represented using this utility. Refer to the
device's hardware manual for information on the capabilities
of the peripheral device.
WARNING: Use of mapping files that specify a different
``internal'' character set per-channel, or a set other than
the 8-bit ASCII set supplied by default can cause strange
side effects. It is especially important to retain the 7-bit
ASCII portion of the character set (see ascii(M)).
utilities and applications assume these values. Media
transported between machines with different internal code
set mappings may not be portable as no mapping is performed
on block devices, such as tape and floppy drives. mapchan
can be used to ``translate'' from one internal character set
to another.
Do not set ISTRIP (see stty(C)) on channels that have
mapping that includes eight bit characters.
Page 3 (printed 8/7/87)