Bryan Parkoff wrote:
"mdj" <mdj.mdj@gmail.com> wrote in message 1166499011.152258.3620@73g2000cwn.googlegroups.com">news:1166499011.152258.3620@73g2000cwn.googlegroups.com...Michael J. Mahon wrote:I'd suggest using three 4-resistor networks to do the three 4-bit D-to-A conversions--four resistors beats a D/A chip for just 4 bits.Agreed. It might also be possible nowadays to use a uC to replace the GAL idea. GAL/PAL seems to be going the way of the dodo, and using one small cheap chip instead of two seems a good move.And buffer amplifiers may be needed for the RGB signals as well, if the RGB monitor's inputs are 75 Ohm.Without this, you'd see some pretty strange colour artifacting. Also Bryan - your table seems to be quite wrong. Care to post a corrected one? Have you done a comparison of the IIgs's colour palette to the actual composite colours? It's possible that 12 bit RGB only provides an approximate of some of the colours, although admitedly it's probably close enough.Matt,Sorry, I made mistake. It should be the correct table to be shown strange colors below.IRGB RED GREEN BLUE Hex Color 0 0000 0000 0000 0000 000 Color 1 0001 0000 0000 1010 00A Color 2 0010 0000 1010 0000 0A0 Color 3 0011 0000 1010 1010 0AA Color 4 0100 1010 0000 0000 A00 Color 5 0101 1010 0000 1010 A0A Color 6 0110 1010 0101 0000 A50 Color 7 0111 1010 1010 1010 AAA Color 8 1000 0101 0101 0101 555 Color 9 1001 0101 0101 1111 55F Color A 1010 0101 1111 0101 5F5 Color B 1011 0101 1111 1111 5FF Color C 1100 1111 0101 0101 F55 Color D 1101 1111 0101 1111 F5F Color E 1110 1111 1111 0101 FF5 Color F 1111 1111 1111 1111 FFFThis table above is 16 CGA colors. Thanks to Michael's correction when I made mistake to label RGBI as bit reverse. I believe that RGB, GREEN, and BLUE data are to be correct because 24 bit data and 12 bit data are 99% identical when you set "1111" on low nibble or duplicate from high nibble to low nibble. Filling "1111" on low nibble gives little brightness. You can use like (12 bit data) A50 as 24 bit data) AA5500 or (24 bit data) AF5F00.
Just for the record, the exact conversion from 12-bit to 24-bit RGB data (or any other kind of 8-8-8 data) is: 12-bit XYZ --> 24-bit X0Y0Z0. Anything besides low-order zero fill is creating data that isn't in the 12-bit representation. Duplicating the hex digits (e.g.: XXYYZZ) is a way of expanding the 24-bit values so that they still run from zero to full-scale, so it produces the correct relative colors. -michael NadaNet networking for Apple II computers! Home page: http://members.aol.com/MJMahon/ "The wastebasket is our most important design tool--and it's seriously underused."