19
Color RAM
The color palette used by sprites and backgrounds is arranged as two 16-color palettes.
Background patterns can use either palette, while sprite patterns can only use the second
one. These color palettes do not apply to the MSX compatible display modes.
The palette is defined by 32 bytes of color RAM (CRAM). This memory is internal to the
VDP, and is write-only. Each byte has the following format:
- = Unused
R = Red component
G = Green component
B = Blue component
Up to 64 possible colors can be used, and up to 32 can be displayed on screen at any
given time.
Example: Set color 4 to red:
Display modes
The TMS9918 has three bits which select different display modes called M1, M2, and M3.
However, only four combinations of these bits are documented in the TMS9918 manual:
The other four undocumented modes are simply variations of the above, they are no
unique. The SMS VDP added another mode select bit that enabled mode 4, which is
specific to the SMS. The 5246 changed the function of the TMS9918 mode select bits to
pick different resolutions for a standard mode 4 screen.
MSB LSB
--BBGGRR
A07 A06 A05 A04 A03 A02 A01 A00 First byte written
1 1 A13 A12 A11 A10 A09 A08 Second byte written
OUT &H89,4:OUT &H89,&HC0
OUT &H88,&B00000011
Mode 0 - Graphics I
Mode 1 - Text
Mode 2 - Graphics II
Mode 3 - Multicolor
Summary of Contents for Franky
Page 1: ...Instruction Manual ...