Shop OBEX P1 Docs P2 Docs Learn Events
camera interface with pasive components — Parallax Forums

camera interface with pasive components

Chris MicroChris Micro Posts: 160
edited 2009-05-09 09:21 in Propeller 1
Hello together,

how can I connect a video camera to a propeller without using a fast adc?
I know that there is a microphon input on the prop demo board made only by passive components. Now I want to connect a video camera.

Here is my proposal for a passive camera interface realized with two digital inputs an one digital output.

1. sync signal input
2. digital dark/light input
3. pwm dac output to shift the dark/light level

What do you think about?

chris

Post Edited (Chris Micro) : 5/8/2009 8:19:52 PM GMT
1563 x 1068 - 21K
100 x 100 - 17K

Comments

  • PerryPerry Posts: 253
    edited 2009-05-08 20:28
    There is some work I tried like this with "Stupid Video Capture"

    http://forums.parallax.com/showthread.php?p=686552

    Perry
  • Mike GreenMike Green Posts: 23,101
    edited 2009-05-08 20:42
    You need some active analog circuitry at least. The minimum you could get away with would be a sync separator (Like an EL1881) and a high speed sample and hold circuit. The sync separator would go to the Propeller and an assembly routine would count horizontal scan lines, then time from the start of a specific horizontal scan line before triggering the sample and hold circuit to sample the video signal and hold it in a capacitor long enough for the Propeller's built-in ADC to read the value. With very clever coding, you might be able to sample a couple of widely separated pixels per scan line.
  • Chris MicroChris Micro Posts: 160
    edited 2009-05-08 21:12
    Perry said...

    There is some work I tried like this with "Stupid Video Capture"
    forums.parallax.com/forums/default.aspx?f=25&m=227676
    Uhh, I hoped to have the minimum possible number of components, but your solution needs less yeah.gif
    But there is one difference: My circuit uses two digital input pins ( sync and signal ). With this setup one can achive a much higher resulution because the signal pin can be sampled much faster. The trade of is: it has only on bit resultuion ( dark and light ). But if one takes consecutive picuters and shifts the compare level in every picture one can get pictures of a still image with more bits. In my circuit the compare level for the signal can be shiftet by a digital output ( pwm dac ).
    Mike Green said...
    You need some active analog circuitry at least. The minimum you could get away with would be a sync separator (Like an EL1881) and a high speed sample and hold circuit.
    I know the lm1881. But I wanted to avoid this chip and try to realize the circuit with only passive components. My sync separator consists of the poti and a diode ( see schematic ). With this circuit it is more or less possible to detect the negativ sync pulses in the video signal.
    In my experiments I could detect the line sync signals with this circuit.
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2009-05-08 21:35
    Make sure your sync separator works with both the lens cover on (all black) and staring at a lightbulb (all white). Then, while it's staring at a light source, wave your hand in front of the lens to switch rapidly from dark to light. I'm not sure from looking at your schematic whether your simple diode "DC restorer" will be effective under all lighting conditions or changes in lighting conditions.

    -Phil
  • Chris MicroChris Micro Posts: 160
    edited 2009-05-08 23:43
    You are right, the sync separator is of poor quality. Is there any possibility to improve it without using an integrated circuit?
  • Mike GreenMike Green Posts: 23,101
    edited 2009-05-08 23:50
    I'm sure it's been done, but not without at least some amplifiers / timers / etc. By the time you put all the parts needed on the board, you might as well use the IC.
  • Chris MicroChris Micro Posts: 160
    edited 2009-05-09 09:21
    Hi Mike,

    you are right: It cost a lot of time to develop such a circuit by itself. But wouldn't it be usefull for a lot of propeller users to have a minimalistic video input like the mikrofon input?

    I made a minmalistic camera interface for an atmega8 .
    The sync separator there is realised in the same way as propossed in the first post: the video signal is clamped with a diode to a switching level.
    The Atmega8 has a specialised comparator input. The detection of the sync pulse with this input works pretty well.
    With the propeller it seems to be more problematic. I don't know the excat switching levels of the imput pins and I have the impression that they shift a little bit relating to the signal history.

    The analog to digtital conversion part in the LM1881 uses not much components: 2 Operational Amplifiers one with a diode Feedback to the negativ input pin ( see image attached ).
    So the most components of the lm1881 are not needed by the propeller because he can to the calculation for H-Sync and V-Sync by its own.
    752 x 647 - 51K
Sign In or Register to comment.