VGA.spin Explained! (bug found?)
Rayman
Posts: 14,876
VGA.spin is a very complex driver and very hard to understand.
But, it's the basis for a lot of my LCD drivers, so I've had to decipher it...
I think I've got it mostly figured out.
Anyway, I've added my notes to the original VGA.spin file to other people
figure out what's going on.
Regarding the possible bug, I think on my line 440:
sub x,
should be
sub t1,
But, it would only show up when asking for a very slow pixel clock...
VGA_Explained.spin
But, it's the basis for a lot of my LCD drivers, so I've had to decipher it...
I think I've got it mostly figured out.
Anyway, I've added my notes to the original VGA.spin file to other people
figure out what's going on.
Regarding the possible bug, I think on my line 440:
sub x,
should be
sub t1,
But, it would only show up when asking for a very slow pixel clock...
VGA_Explained.spin
spin
107K
Comments
Did some web searching for what the exact syncs should look like for interlaced VGA, but couldn't find anything...
In interlaced mode, the vsync is different for even and odd fields.
I think I see what's going on, but it'd be nice to find a reference so I could be sure that I'm reading it right
(and also that it's being done right
This is enormously helpful! Thanks for making the effort to do this and to share it with the rest of us!
-Phil
Perhaps this could be the beginning of an "UnSpun" series - taking a real close, easy to follow look at some of the more mysterious prop code.
ff
I really like the way you have expanded the explanation over several lines not just a few short comments.
Regards,
Coley
Both to get the VGA-driver explained but also a quite complex assembler program with so much explanation is just GREAT, thanks a lot!
Good work Rayman.
Please let me know if anybody finds errors or ommissions and I'll try to make it better.
I like "UnSpun" too... Maybe I should change the title of this thread to: VGA.spin ---> UnSpun !