Shop OBEX P1 Docs P2 Docs Learn Events
Using CounterB for a 64-128mhz Duty signal on a VGA pin to get 256shades of a c — Parallax Forums

Using CounterB for a 64-128mhz Duty signal on a VGA pin to get 256shades of a c

tonyp12tonyp12 Posts: 1,951
edited 2010-08-05 21:21 in Propeller 1
Using CounterB for a 64-128mhz Duty signal on a VGA pin to get 256 shades of a color for background ?
With just adding a capacitor to filter the high freq to create a DAC.

And modify a VGA object so it have the option of a new FRQB value for each scan line.
It should be possible to create the blue shade below?



Boing.PNG
·

Comments

  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2010-08-05 15:50
    Yes, that should work. I've used DUTY mode like that for NTSC output to create shades of gray. It should be even easier with VGA, since you don't have to worry about filtering out the chroma signal with your capacitor.

    -Phil
  • tonyp12tonyp12 Posts: 1,951
    edited 2010-08-05 16:14
    Phil, got any hints on the layout and cap value?

    It would be great to have a poor mans Amiga copper.

    With the option of differential duty,
    could have a mirror of the shade on two different VGA pins with a lot of possible colors.

    A 16bit Copper command,
    would have 12bits for FRQB value, 2 bits for pin combinations, 1 bit for single or diff mode.
    And 1 bit for future use.

    As you can change these values every scan line, we can have some fun.
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2010-08-05 16:59
    It's probably not very critical. You do want to maintain an overall 75-ohm output impedance on whichever color channel you choose for the effect. But, since you're setting intensity for the entire scan line, it would be hard to over-filter the DUTY doody. Just experiment and see what works.

    -Phil
  • ericballericball Posts: 774
    edited 2010-08-05 17:26
    I wouldn't worry too much about filtering, just blast it out and see what happens. The impedance of the cable and typical chokes will provide some filtering.

    Just be aware that the blue will go across the entire line. So the red squares in the ball will have a blue tint near the ground plane.

    And it won't be a "mirror", but more of the opposite intensity. I'd also want to be able to specify any of the six RGB pins for either output.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Composite NTSC sprite driver: Forum
    NTSC & PAL driver templates: ObEx Forum
    OnePinTVText driver: ObEx Forum
  • jazzedjazzed Posts: 11,803
    edited 2010-08-05 18:52
    Interesting idea.

    Would this be a cheap way to get 3D shading on randomly placed squares such as an OK button or maybe list boxes? Think about Cable or UVerse TV channel listing overlays and how much nicer they look than just boxes with text in them.

    Thanks,
    --Steve

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Propeller Pages: Propeller JVM
  • tonyp12tonyp12 Posts: 1,951
    edited 2010-08-05 21:21
    Eric is right, the blue will bleed through on anything on
    the screen that does not also use·blue·in it.
    White and Cyan etc is OK.

    So the other option would be to have the duty on a separate pin(s) together
    with a 6input AND gate and one 6input NAND gate.
    So two different colors is the mask to let 2 different Duty's through.


    Probably should take it all the way with a 64 out of 4096 color lookup table palate mode.

    Post Edited (tonyp12) : 8/5/2010 10:35:04 PM GMT
Sign In or Register to comment.