View previous topic :: View next topic |
Author |
Message |
thiaguetz
Joined: 03 Feb 2004 Posts: 12 Location: Brazil
|
PIC Tv Color/Pulse detector |
Posted: Thu Feb 05, 2004 5:16 pm |
|
|
Hi doods,
Today i was watching tv and I started thinking about detecting pulses or colors from a TV.
ok ok... i will explain ;)
Is there a way that i can detect a flat screen color (think about a TV displaying on the entire screen the color red) or a pulse, like a morse code only generating a black-white-black interval?
In other words... think about a morse code using 2 colors sequence (black and white)...
I was thinking about using a LDR with a PIC that will "see" the lighting changes... but i remembered that a LDR is too slow...
Then i rembered that i can use a phototransistor... but the lightning enviroment can influence the phototransitor sensivity.
So... if i choose to use one of then, the logic could be...
i record a flat screen color on a video tape or something that the tv will only display the color red... than i could have a value table that correspond the light measure that the red can send...
and then i can detect that color...
what do you think?
anyone know a way to do this?
thanks! |
|
|
fpgeh
Joined: 07 Sep 2003 Posts: 19 Location: Vancouver, BC
|
|
Posted: Thu Feb 05, 2004 6:58 pm |
|
|
I'm not quite sure what you are trying to do, but it's probably a lot harder than you'd expect. First, TV signals are usually modulated on a carrier frequency, which would require demodulation prior to any color processing.
Even if you had baseband signals, most TVs use composite video. Composite video is a single signal containing both the black and white intensity at baseband and the color information carried on a sub-carrier frequency. To do any color processing you would need to demodulate this color information.
Anyways, there is a lot to consider. Check out www.epanorama.net for more info. Goto the video "video" section. I think I saw some PIC circuits there for character overlays and such. |
|
|
thiaguetz
Joined: 03 Feb 2004 Posts: 12 Location: Brazil
|
|
Posted: Fri Feb 06, 2004 6:50 am |
|
|
HI!
Well, i will visit the link that you post here.
My idea is place a circuit in front of the TV and when the TV show the color red on the entire screen the circuit play a siren or something.
I know how to build the entire circuit, but only this part i cannot figure it out.
Is there a way to do with a LDR or a phototransistor?
thanks |
|
|
SherpaDoug
Joined: 07 Sep 2003 Posts: 1640 Location: Cape Cod Mass USA
|
|
Posted: Fri Feb 06, 2004 8:03 am |
|
|
You could simply put a colored filter on a phototransistor. Or better yet two different colors on two phototransistors and check their ratio. This will compensate for changes in brightness, temperature, supply voltage etc. A pair of LDRs should also work though I think they are more sensitive to green. Check the LDR spec sheet.
If you can get an RGB video signal you can easily electrically compare the colors. Extracting color information from a composite video signal is tough without specialized chips. _________________ The search for better is endless. Instead simply find very good and get the job done. |
|
|
thiaguetz
Joined: 03 Feb 2004 Posts: 12 Location: Brazil
|
|
Posted: Fri Feb 06, 2004 10:52 am |
|
|
Ummm...
The color filter is a nice idea
I will try that.
Thanks SherpaDoug |
|
|
bwhiten
Joined: 26 Nov 2003 Posts: 151 Location: Grayson, GA
|
|
Posted: Fri Feb 06, 2004 12:08 pm |
|
|
Look at this web site, www.taosinc.com
Take a look at their TCS230 for multiple color detection or
the TSLx257 series for single color detection.
I have used all these successfully for testing the correct color of LEDs on a pcb production line. |
|
|
diogoc
Joined: 12 Feb 2008 Posts: 19
|
|
Posted: Thu Jul 16, 2009 3:39 am |
|
|
hi
do you have an example code for tcs230?
thanks |
|
|
bkamen
Joined: 07 Jan 2004 Posts: 1615 Location: Central Illinois, USA
|
|
Posted: Thu Jul 16, 2009 10:04 am |
|
|
bwhiten wrote: | Look at this web site, www.taosinc.com
Take a look at their TCS230 for multiple color detection or
the TSLx257 series for single color detection.
I have used all these successfully for testing the correct color of LEDs on a pcb production line. |
What a cool little product. Don't know what *I'd* use it for -- but it's cool!
As to the author of the thread,
That's the fun part for you to figure out!
:D
-Ben _________________ Dazed and confused? I don't think so. Just "plain lost" will do. :D |
|
|
bwhiten
Joined: 26 Nov 2003 Posts: 151 Location: Grayson, GA
|
|
Posted: Thu Jul 16, 2009 11:49 am |
|
|
Sorry. Five long years ago and the code is now owned by a manufacturing test company in Alabama.
From what I remember it was not very complex to code. |
|
|
John P
Joined: 17 Sep 2003 Posts: 331
|
|
Posted: Thu Jul 16, 2009 2:41 pm |
|
|
Surely a color filter would fail if the screen were all white? Then your sensor would see red, even if there were green and blue visible at the same time. You'd need three sensors, so you could say "Red, but not green or blue".
Also, how can you discriminate between a screen that's "mostly red" versus one that's "all red"? |
|
|
bkamen
Joined: 07 Jan 2004 Posts: 1615 Location: Central Illinois, USA
|
|
Posted: Thu Jul 16, 2009 3:32 pm |
|
|
The white filter will give a higher output than just the red...
So you'd want to scan through them all and compare... then you'd get an idea if a light source was white or just something else...
Also, to the original poster, you could do inverted PWM with INT0 interrupts and a timer...
I'd also look up the capture/compare units to see if they might be applicable. (I think they are).
Cheers,
-Ben
p.s. I used INT0 on PWM from ADXL202 accelerometers and it worked quite nicely. _________________ Dazed and confused? I don't think so. Just "plain lost" will do. :D |
|
|
|