AH = 0Eh: Write Teletype Character
This function writes a character to the display at the current cursor position, using the specified color (if in graphics modes), then advances the cursor one location.
- Input: AH = 0Eh
AL = Character
BH = Page (where required)
BL = Foreground color (graphics modes only)
- Output: None
- Error conditions: None
- Registers modified: None
Notes:
- ASCII codes for four characters are treated as commands: LineFeed (0Ah), Carriage Return (0Dh), Backspace (08h), and Bell (07h).
- In video modes with multiple pages, characters may be written off screen.
- Line wrap and scrolling are active. If the cursor is at the end of a line, it is moved to the beginning of the next line. If the cursor reaches the end of the last line on the screen, the screen is scrolled up by one line and the cursor is placed at the beginning of a new blank line. The attribute for the entire new line is taken from the last character on the preceding line.
- This function cannot be used to specify the attribute of a character in Text Modes.
- In Mode 6 (Hi-Res B&W Graphics), the foreground color is resolved to 0 or 1.
- In Mode 4 (Lo-Res Color Graphics), the foreground color is resolved to 0-3.
- In Mode 5 (Lo-Res B&W Graphics), the foreground color is resolved to 0 or 1.