# HG changeset patch # User Paul Boddie # Date 1356139367 -3600 # Node ID 575d8cc03fcee91e86470c7af058030e0a51866f # Parent 53cd92fd0b9670d7cb3d0b77cc22aa2bab4f8fe8 Fixed the description of flashing colours since all logical colours can be made to flash by mapping any of them to physical colours 8 through 15, and only these physical colours are able to support the flashing effect. diff -r 53cd92fd0b96 -r 575d8cc03fce ULA.txt --- a/ULA.txt Sat Dec 22 01:02:20 2012 +0100 +++ b/ULA.txt Sat Dec 22 02:22:47 2012 +0100 @@ -305,11 +305,46 @@ that the palette registers must be updated upon the flash counter - read and written by OSBYTE &C1 (193) - reaching zero and that some way of changing the colour pairs to be any combination of colours might be possible, instead of -having colour complements as pairs. It is conceivable that the interrupt code -responsible does the simple thing and merely inverts the current values for -colours 8 through 15, and this might be verified by looking for an operation -that involves the bit pattern 11001100, since this value would be EORed with -the existing palette register values in order to perform this value inversion. +having colour complements as pairs. + +It is conceivable that the interrupt code responsible does the simple thing +and merely inverts the current values for any logical colours for which the +associated physical colour (as supplied as the second parameter to the VDU 19 +call) has the top bit of its four bit value set. These top bits are not +recorded in the palette registers but are presumably recorded separately and +used to build bitmaps as follows: + + 2 colour 4 colour 16 colour + -------- -------- --------- + 0 00010001 00010001 00010001 + 1 01000100 00100010 00010001 + 2 01000100 00100010 + 3 10001000 00100010 + 4 00010001 + 5 00010001 + 6 00100010 + 7 00100010 + 8 01000100 + 9 01000100 + 10 10001000 + 11 10001000 + 12 01000100 + 13 01000100 + 14 10001000 + 15 10001000 + +An operation in the interrupt code would then combine the bitmaps for all +logical colours in 2 and 4 colour modes, with the 16 colour bitmaps being +combined for groups of logical colours as follows: + + 0, 2, 8, 10 + 4, 6, 12, 14 + 5, 7, 13, 15 + 1, 3, 9, 11 + +These combined bitmaps would be EORed with the existing palette register +values in order to perform the value inversion necessary to produce the +flashing effect. Palette Definition Lists ------------------------