Palette

The integrated palette contains 256 color entries. VGA ports and native I/O aliases address the same programming interface.

Operation VGA port Native I/O
Write index 0x3C8 +0xB0
Data 0x3C9 +0xB1
Pixel mask 0x3C6 +0xB2
Read index Write 0x3C7 +0xB3
DACState Read 0x3C7 —

Byte data accesses sequence through red, green and blue. A palette word write supplies red in bits 23:16, green in 15:8 and blue in 7:0, then increments to the next color triple. This permits 256 word writes for a full palette. Reads still use bytes.

Command0 selects six- or eight-bit palette output and power-down. Command1 selects 8/16/32-bit pixel mode and palette bypass. Command2 selects cursor mode and contiguous or sparse palette indexing. Cursor colors have their own read/write index and data ports.

The catalogue's palette entry diagrams describe these RGB component programming values. They do not establish the physical width of the internal palette RAM.

At I/O +0xBA, Table 7a describes Command4/signature analysis, while Table 7b describes Palette Status with different fields. The detailed Status table is used for the diagram; the conflicting description remains visible in PALETTE_BA.

All 256 palette entries · RGB word-write format · Cursor

Sources: Technical Spec, p.51, Technical Spec, p.52