Shop OBEX P1 Docs P2 Docs Learn Events
Question on S-video, Need Guru help here... — Parallax Forums

Question on S-video, Need Guru help here...

RinksCustomsRinksCustoms Posts: 531
edited 2007-07-12 20:40 in Propeller 1
I'm just finishing the schematics on the TwinProp, and would like to incorporate an S-video out, but am scratching my head on what bit (0..3) would go with what pin on an s-video connector. The TV driver specs bit 3 as a 560 ohm for s-video, is this the same resistor as the aural cog resistor?

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
E3 = Thought

http://folding.stanford.edu/·- Donating some CPU/GPU downtime just might lead to a cure for cancer! The average PC while browsing the internet typically uses less than 30% of it's potential, why not donate a portion of the rest for cancer resaerch?

Comments

  • deSilvadeSilva Posts: 2,967
    edited 2007-07-11 12:26
    As no one answers...
    Yes it is so! You can either have broadcast and (opt.) audio, or baseband and (opt.) separate chroma; "chroma" is the highest pin of the 4-pin-group. There is a good article about pin-out and other background information in Wikipedia en.wikipedia.org/wiki/S-Video
  • RinksCustomsRinksCustoms Posts: 531
    edited 2007-07-11 19:06
    At a second look of the TV driver and the pinnout from <a href="http://pinouts.ru/Video/SVideo_pinout.shtml">pinouts.ru</a&gt; I think i may have answered my own question, but won't be sure until I have time to test this idea tongiht.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    E3 = Thought

    http://folding.stanford.edu/·- Donating some CPU/GPU downtime just might lead to a cure for cancer! The average PC while browsing the internet typically uses less than 30% of it's potential, why not donate a portion of the rest for cancer resaerch?
  • ericballericball Posts: 774
    edited 2007-07-11 19:24
    deSilva said...
    As no one answers...
    Yes it is so! You can either have broadcast and (opt.) audio, or baseband and (opt.) separate chroma; "chroma" is the highest pin of the 4-pin-group. There is a good article about pin-out and other background information in Wikipedia en.wikipedia.org/wiki/S-Video
    Are you certain?· Have you tested?

    I can't find the forum entry describing how the video generator creates signal, but it only uses pins +0,+1,+2 in the group (or +4,+5,+6).· Pin +3 (+7) is only used for broadcast audio.· (See http://forums.parallax.com/showthread.php?p=628130·for how broadcast works.)

    Basically, in baseband the PLLA is 16x the colorburst frequency which drives a 16 stage phase shifter.· The 4 color bits (bits 7..4) select the shifter stage which is then sampled and optionally (bit 3) combined (via add/subtract 1) with the 3 luma bits (bits 2..0) and used to drive the three output pins.

    output[noparse][[/noparse]2..0] = input[noparse][[/noparse]2..0] + input[noparse][[/noparse]3] ^ shift(input[noparse][[/noparse]7..4]) - input[noparse][[/noparse]3] ^ !shift(input[noparse][[/noparse]7..4])

    So, if you're using the normal baseband video generation, there is no separate chroma pin.· To generate S-Video you're going to need to roll your own video driver to synchronize two cogs - one to generate luma+sync and the other to generate chroma (using the normal baseband mode), or something based on the VGA mode which will create luma & modulated chroma directly.

    ·
  • deSilvadeSilva Posts: 2,967
    edited 2007-07-11 20:55
    Well, I "deduced" ist smile.gif

    (1) "Chroma Mixing" off gives a grayscale picture
    (2) Now add "Chroma with Baseband" and - hey presto - color re-appears (notabene a little bit more fuzzy than before).

    Andre LaMothe also describes the Video Engine extensively in his recommendable book.

    Your objection, Ericball, just addresses the register (surface) view; color mixing into composite video seems to be still a little bit more under the hood...

    The counter check would have been to remove the resistor connection between Pin 4 and the video socket, but I did not want to cripple my Hydra ...

    Post Edited (deSilva) : 7/11/2007 9:08:30 PM GMT
  • RinksCustomsRinksCustoms Posts: 531
    edited 2007-07-12 04:28
    My hypothesis for S-video out,
    You have the prerequisit 3 for baseband, the TV driver specs an aditional 4th following the other three resistors for chroma. So you would use the 3 resistor DAC for the Y (luminance) and the extra resistor - bit 3 (a 560 ohm) for the C (chrominance) and connect both grounds to a ground the prop is connected to.

    {{
         1.1K
    bit0 &#9472;&#61629;&#61630;&#9472;&#9472;&#9472;&#9472;&#9472;&#9488;
         560&#937;    &#9474;
    bit1 &#9472;&#61629;&#61630;&#9472;&#9472;&#9472;&#9472;&#9472;&#9547;&#9472;&#9472;&#9472;&#9472;&#9472;&#61627;  Y    - hypothetical
         270&#937;    &#9474;
    bit2 &#9472;&#61629;&#61630;&#9472;&#9472;&#9472;&#9472;&#9472;&#9496;  &#9484;&#9472;&#9472;&#61627;  Ygnd - hypothetical
                    &#61464;
         560&#937;
    bit3 &#9472;&#61629;&#61630;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#61627;  C    - hypothetical
                    &#9484;&#9472;&#9472;&#61627;  Cgnd - hypothetical
                    &#61464;   
     }}
    

    Oky doky! I'm assuming that the forum cannot display the full spectrum of the parallax font so just use a bit of imagination.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    E3 = Thought

    http://folding.stanford.edu/·- Donating some CPU/GPU downtime just might lead to a cure for cancer! The average PC while browsing the internet typically uses less than 30% of it's potential, why not donate a portion of the rest for cancer resaerch?
  • RinksCustomsRinksCustoms Posts: 531
    edited 2007-07-12 20:40
    My hypothesis was correct! The above schematic is correct in it's layout and pin connections, the video on my tv is very clean. deSilva is correct, i accidentally bumped the end of the 560ohm Chroma resistor into the dac and the picture got fuzzy cand color was very saturated. I gues the HYDRA has bit 4 tied to the output, but you can easily modify the tv_pins parameter to use any 4 pins within a group of 8 pins, ie- %000_0000 sets the pin group to pins 7..0 and the lower nibble (pins 3..0 - o being the start pin of the DAC) are set to output baseband.

    Let's say the 3 pin DAC starts on pin·8 and ends on pin·10 and you want to use s-video output, you need to add a 560 ohm resistor at the next pin after the DAC (pin 11 in this case), you would then set the "pins" in the DAT section to %001_0010, which tells the driver that the DAC uses the lower nibble of pin group 8..15 and the group mode should be baseband + chroma.

    For a pinnout of an s-video connector check out pinnout.ru, they have accurate pinnouts of almost every connector, cable, and device·made! And they give explination on how some of those devices work.



    Attached is the modified Graphics Demo to work on start·pin 8 with s-video out and a 4 pin DAC.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    E3 = Thought

    http://folding.stanford.edu/·- Donating some CPU/GPU downtime just might lead to a cure for cancer! The average PC while browsing the internet typically uses less than 30% of it's potential, why not donate a portion of the rest for cancer resaerch?
Sign In or Register to comment.