Good. A bit late answer, but I finally stole few minutes to generate 9-bit
wide lookup table if you want to experiment. I am just a csa2 lurker these
days.
http://www.softjunk.org/sw/apple2/ra2/files/screenshot/ntsc/bpp/tbl_ntsc9.h
9-bit wide shift register at 14 MHz fed with Apple II serial video. Goes
through lookup table #0 .. #3 depending on phase relation with 3.58 MHz
color carrier, i.e. 0, 1, 2, 3, 0, 1, 2, 3, 0, 1, 2, 3 ...
Each entry is R8G8B8 triplet, which you should reduce to R3G3B3 or
similar to fit nicely in a single 2048x9 BRAM.
Example:
Serial video is 00110011011001100....
lookup table #0 with 001100110 -> output pixel 0
lookup table #1 with 011001101 -> output pixel 1
lookup table #2 with 110011011 -> output pixel 2
lookup table #3 with 100110110 -> output pixel 3
... repeat for the whole line ...
And the few points of caution:
1) I can't remember vector direction, so just try both, i.e. whether
shifter is clocked left or right
2) lookup entry gives middle pixel value for a 9-bit wide vector, like
this "xxxxXxxxx", so allow for some spare pixels on left and right edge of
screen
3) HGR and DHGR have different start phases with respect to color
carrier, so take this into account as well or simply do DHGR always
1) and 3) give total of 8 permutations to try, in the worst case.
Some excuses in advance if I messed up something.
-- Vlad