(I don't know if my question ever made it to the sun-manager's mailing list,
but here's a summary anyway)
Some time ago, I asked:
>Is it possible to use /dev/ttya as console on a Sparcstation 1 (4.1.1) without
>making the framebuffer, keyboard and mouse unusable?
>We changed "input-device" and "output-device" to "ttya" in the PROM monitor
>but after reboot, accesses to /dev/kbd, /dev/mouse, and /dev/fb resulted
>in "No such device or address".
I got a few responses, ranging from "yes" to "no". The correct answer turned
out to be YES, it can be done. The solution, however, is not a standard,
supported one, but that's life.
Thanks to Gijs Mos, Kevin N. Hayes, Malcolm Caldwell, David DiGiacomo, and
Peter Lamb!
Proceed as follows:
1) Make new special files corresponding to the "raw" keyboard and mouse:
mknod /dev/zs2 c 12 2 # The keyboard
mknod /dev/zs3 c 12 3 # The mouse
These are just serial ports and will need some "special treatment"
in order to behave as /dev/kbd and /dev/mouse.
2) Shutdown your machine and tell the monitor to
setenv input-device ttya # Or perhaps ttyb
setenv output-device ttya
You can also use eeprom(8S).
3) Reset and reboot. /dev/fb, /dev/kbd and /dev/mouse are now useless.
In my case, /dev/bwtwo0 works as a substitute for /dev/fb.
Also /dev/ttya (ttyb) is useless - if you have an entry in ttytab
for it, comment it out.
4) If you want to run
Sunview: start with "-dev /dev/bwtwo0 -k /dev/zs2 -m /dev/zs3"
MIT X: patch the server to accept flags for non-default mouse and keyboard
devices. If you don't want to hack the R5 source yourself, you can
get patches by anonymous ftp from adagio.fy.chalmers.se
(129.16.117.10) in
/pub/MITXservernonstandarddevicepatches.tar.Z. NOTE: these
are somewhat Q&D and assume you have a TYPE-4 keyboard!
Sorry for that - see below.
Start your new server with
"-dev /dev/bwtwo0 -mousedev /dev/zs3 -kbddev /dev/zs2"
Openwindows: what? Ohh! :) You will have to
setenv MOUSE /dev/zs3
setenv KEYBOARD /dev/zs2
and tweak /usr/openwin/etc/NeWS/keybdinit.ps a little.
If you have a type-4 keyboard, replace
/Default {
false
}
with
/Default {
(NeWS/US4.ps) LoadFile
}
the file name depending on your hardware, nationality and personal
taste.
No warranties!
And now for a new question: Tha man page kbd(4S) states that /dev/kbd
is, essentially, a serial port with the "kb" and "ttcompat" stream
modules pushed onto it. But if I open /dev/zs2 (mknode:d as above and
with {in|out}put-device directed to ttya), push ttcompat and kb onto
it, a KIOCTYPE ioctl will return -1 (type unknown) instead of the
expected KB_SUN4. Why? All other KIOCxxxs work perfectly well. - As
you might have guessed, that's why the abovementioned patches assume a
type-4 keyboard. Mildly irritating.
-- Daniel Berglund db@fy.chalmers.se Chalmers Univ. of Technology, G|teborg, Sweden
This archive was generated by hypermail 2.1.2 : Fri Sep 28 2001 - 23:06:16 CDT