SGDK
A free and open development kit for the Sega Mega Drive
|
TTY text console. More...
#include "config.h"
TTY text console.
This unit provides a simple TTY text console. Characters are written as a stream, where lines are automatically wrapped if the horizontal border of the screen is reached. When at the bottom of the screen window, the console content is moved up by one text line and a blank row is inserted.
Per default, the console occupies a standad screen of 40x28 tiles. All text attributes, such as font, palette, plane etc., are taken from SGDK text settings. Screen updates are done using DMA transfer mode (which can be changed with CON_setTransferMethod()).
One of the use cases are assert messages. To this end, the Genesis state can be automatically reset before text is displayed (see assert macro in console.h).