Question

A VGA screen buffer of 24 rows and 80 columns (3,840 bytes, including the attribute bytes)...

A VGA screen buffer of 24 rows and 80 columns (3,840 bytes, including the attribute bytes) is directly accessible starting at address 0xB8000. Discuss an approach (not code) that will allow multiple virtual terminals (full-screen display, not windowed) to be active within a system simultaneously. Terminals selection is via a keyboard combination.

0 0
Add a comment Improve this question Transcribed image text
Answer #1
  1. The implementation of computer monitor text mode on VGA-compatible hardware is quite complex. Its use on PC-compatible computers was widespread in 1980s–1990s (particularly under DOS systems), but persists today for some applications even on modern desktop computers.
  2. The main features of VGA text mode are colored (programmable 16 color palette) characters and their background, blinking, various shapes of the cursor (block/underline/hidden static/blinking), and loadable fonts (with various glyph sizes). The Linux consoletraditionally uses hardware VGA-compatible text modes, and the Win32 console environment has an ability to switch the screen to text mode for some text window sizes.

Text buffer

  1. Each screen character is actually represented by two bytes aligned as a 16-bit word accessible by the CPU in a single operation. The lower, or character, byte is the actual code point for the current character set, and the higher, or attribute, byte is a bit field used to select various video attributes such as color, blinking, character set, and so forth.
  2. This byte-pair scheme is among the features that the VGA inherited from the EGA, CGA, and ultimately from the MDA.
Attribute Character
7 6 5 4 3 2 1 0 7 6 5 4 3 2 1 0
Blink[n 1] Background color Foreground color[n. 2][n. 3] Code point
  1. ^ Depending on the mode setup, attribute bit 7 may be either the blink bit or the fourth background color bit (which allows all 16 colors to be used as background colours).
  2. ^ Attribute bit 3 (foreground intensity) also selects between fonts A and B (see below). Therefore, if these fonts are not the same, this bit is simultaneously an additional code point bit.
  3. ^ Attribute bit 0 also enables underline, if certain other attribute bits are set to zero (see below).
  • Colors are assigned in the same way as in 4-bit indexed color graphic modes (see VGA color palette). VGA modes have no need for the MDA's reverse and bright attributes because foreground and background colors can be set explicitly

Underline

  1. The VGA hardware has the ability to enable an underline on any character that has attribute bit 0 set.
  2. However, since this is an MDA-compatible feature,the attribute bits not used by the MDA must be set to zero or the underline will not be shown.
  3. This means that only bits 3 (intensity) and 7 (blink) can be set concurrently with bit 0 (underline). With the default VGA palette, setting bit 0 to enable underline will also change the text colour to blue.
  4. This means text in only two colors can be underlined (light blue and dark blue with the default palette).

Despite all this, the underline is not normally visible in color modes, as the location of the underline defaults to a scanline below the character glyph, rendering it invisible.[1] If the underline location is set to a visible scanline (as it is by default when switching to an MDA-compatible monochrome text mode), then the underline will appear.

Fonts

Norton Utilities 6.01, an example of advanced TUI which redefines the character set to show tiny graphical widgets, iconsand an arrow pointer in text mode.

VGA shows us the code page 737 with Greek letters

  1. Screen fonts used in EGA and VGA are monospace raster fonts containing 256 glyphs. All glyphs in a font are the same size, but this size can be changed. Typically, glyphs are 8 dots wide and 8–16 dots high, however the height can be any value up to a maximum of 32.
  2. Each row of a glyph is coded in an 8 bit byte, with high bits to the left of the glyph and low bits to the right. Along with several hardware-dependent fonts stored in the adapter's ROM, the text mode offers 8[1] loadable fonts. Two active font pointers (font A and font B) select two of the available fonts, although they usually point to the same font.
  3. When they each point to different fonts, attribute bit 3 (see above) acts as a font selection bit instead of as a foreground color bit. On real VGA hardware, this overrides the bit's use for color selection, but on many clones and emulators, the color selection remains — meaning one font is displayed as normal intensity, and the other as high-intensity. This error can be overcome by changing the palette registers to contain two copies of an 8-color palette.
  4. There are modes with a character box width of 9 dots (e.g. the default 80×25 mode), however the 9th column is used for spacing between characters, so the content cannot be changed. It is always blank, and drawn with the current background colour.
  5. An exception to this is in Line Graphics Enable mode, which causes code points 0xC0 to 0xDF inclusive[1] to have the 8th column repeated as the 9th. These code points cover those box drawing characters which must extend all the way to the right side of the glyph box. For this reason, placing letter-like characters in code points 0xC0–0xDF should be avoided. The box drawing characters from 0xB0 to 0xBF are not extended, as they do not point to the right and so do not require extending.
Add a comment
Know the answer?
Add Answer to:
A VGA screen buffer of 24 rows and 80 columns (3,840 bytes, including the attribute bytes)...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT