biosfont
—
retrieve font bitmaps from BIOS memory
The special file /dev/biosfont is an
interface to retrieve font bitmaps from the BIOS memory. The fonts
represented are the native system fonts. The complete ASCII set (256
characters) can be retrieved.
The characters can be retrieved using the
ioctl
()
call. The parameters are:
BIOSFONT_ASCII
- The call identifier for to use for
biosfont
calls.
&ch
- A reference to an instance of t_biosfont which is
defined in the header file. t_biosfont has two
fields:
- u_char bitmap[8]
- The output, contains the bitmap scanlines. The top scanline is stored
in bitmap[0], the bottom scanline is stored in bitmap[7]. The
scanlines themselves are stored little endian (MSB first).
- u_char nr
- ASCII code of character to retrieve, range is bound to 0 <= nr
<= 255
Due to a braindead endianness implementation the driver is only
guaranteed to work on i386 and amd64 architectures. These are also the only
architectures known to the author to actually have the bitmap fonts.
- /usr/local/include/biosfont.h
- The header file to include when accessing the driver.
- /dev/biosfont
- The device node for the driver.
- /boot/modules/biosfont.ko
- The kernel module to load when using the driver.
The biosfont
driver was first written in
August 2003, and rewritten in April 2006 when the original sources were lost
(oops). It was released to the public on May 7, 2006.