version 1, including all changes.
.
Rev |
Author |
# |
Line |
1 |
perry |
1 |
VCS |
|
|
2 |
!!!VCS |
|
|
3 |
NAME |
|
|
4 |
DESCRIPTION |
|
|
5 |
EXAMPLES |
|
|
6 |
FILES |
|
|
7 |
AUTHOR |
|
|
8 |
HISTORY |
|
|
9 |
SEE ALSO |
|
|
10 |
---- |
|
|
11 |
!!NAME |
|
|
12 |
|
|
|
13 |
|
|
|
14 |
vcs, vcsa - virtual console memory |
|
|
15 |
!!DESCRIPTION |
|
|
16 |
|
|
|
17 |
|
|
|
18 |
__/dev/vcs0__ is a character device with major number 7 |
|
|
19 |
and minor number 0, usually of mode 0644 and owner root.tty. |
|
|
20 |
It refers to the memory of the currently displayed virtual |
|
|
21 |
console terminal. |
|
|
22 |
|
|
|
23 |
|
|
|
24 |
__/dev/vcs[[1-63]__ are character devices for virtual |
|
|
25 |
console terminals, they have major number 7 and minor number |
|
|
26 |
1 to 63, usually mode 0644 and owner root.tty. |
|
|
27 |
__/dev/vcsa[[0-63]__ are the same, but including |
|
|
28 |
attributes, and prefixed with four bytes giving the screen |
|
|
29 |
dimensions and cursor position: ''lines'', |
|
|
30 |
''columns'', ''x'', ''y''. (''x'' = ''y'' = 0 |
|
|
31 |
at the top left corner of the screen.) |
|
|
32 |
|
|
|
33 |
|
|
|
34 |
These replace the screendump ''ioctl''s of |
|
|
35 |
console(4), so the system administrator can control |
|
|
36 |
access using file system permissions. |
|
|
37 |
|
|
|
38 |
|
|
|
39 |
The devices for the first eight virtual consoles may be |
|
|
40 |
created by: |
|
|
41 |
|
|
|
42 |
|
|
|
43 |
for x in 0 1 2 3 4 5 6 7 8; do |
|
|
44 |
mknod -m 644 /dev/vcs$x c 7 $x; |
|
|
45 |
mknod -m 644 /dev/vcsa$x c 7 $[[$x+128]; |
|
|
46 |
done |
|
|
47 |
chown root:tty /dev/vcs* |
|
|
48 |
No ''ioctl''() requests are supported. |
|
|
49 |
!!EXAMPLES |
|
|
50 |
|
|
|
51 |
|
|
|
52 |
You may do a screendump on vt3 by switching to vt1 and |
|
|
53 |
typing ''cat /dev/vcs3 ''. Note that the output |
|
|
54 |
does not contain newline characters, so some processing may |
|
|
55 |
be required, like in ''fold -w 81 /dev/vcs3 | lpr'' or |
|
|
56 |
(horrors) ''setterm -dump 3 -file |
|
|
57 |
/proc/self/fd/1''. |
|
|
58 |
|
|
|
59 |
|
|
|
60 |
The ''/dev/vcsa0'' device is used for Braille |
|
|
61 |
support. |
|
|
62 |
|
|
|
63 |
|
|
|
64 |
This program displays the character and screen attributes |
|
|
65 |
under the cursor of the second virtual console, then changes |
|
|
66 |
the background color there: |
|
|
67 |
|
|
|
68 |
|
|
|
69 |
#include |
|
|
70 |
!!FILES |
|
|
71 |
|
|
|
72 |
|
|
|
73 |
/dev/vcs[[0-63] |
|
|
74 |
/dev/vcsa[[0-63] |
|
|
75 |
!!AUTHOR |
|
|
76 |
|
|
|
77 |
|
|
|
78 |
Andries Brouwer |
|
|
79 |
!!HISTORY |
|
|
80 |
|
|
|
81 |
|
|
|
82 |
Introduced with version 1.1.92 of the Linux |
|
|
83 |
kernel. |
|
|
84 |
!!SEE ALSO |
|
|
85 |
|
|
|
86 |
|
|
|
87 |
console(4), tty(4), ttys(4), |
|
|
88 |
selection(1) |
|
|
89 |
---- |