EEVblog Electronics Community Forum
Electronics => Projects, Designs, and Technical Stuff => Topic started by: MadScientist on November 12, 2022, 08:58:38 am
-
I need a mechanism to detect red green bi colour leds optically so as to relay the colour status remotely
Ok trying to avoid optical filters etc.
Are there any optical style detectors that can be tuned to wavelength etc. ?
-
Does it have to be cheap? There's color sensors etc. In school, some 20 years ago, we did a 'marble color detection system'. How it worked, was a (color?) sensor and 4 colored leds. You'd turn on the leds 1 by 1 and checked the reflection. The highest reflection based on the color that was on, must have been the color. In a nutshell. So stuff like this certainly should exist. Maybe the color sensor was just a regular LDR (the marble did go into a 'dark room') ... so maybe LDR's are differently affected by wavelength? Doesn't sound to far fetched. Have you done any experimentation? :)
-
Well, you could try to measure reflected light from the LED on a green or red paper. If it is lit green then will reflect more from red paper and vice versa. Perhaps a cheap photodiode or LDR with followed by a comparator. This would need lot of testing and tuning.
But a colour sensor would be easiest to start as suggested by @oliv3r.
https://uk.farnell.com/vishay/veml6040a3og/colour-sensor-3-6v-16bit-digital/dp/2504135
Just need to make sure the ambient light is not directly reaching the sensor.
-
You might want to experiment with Red and Green LEDs as optical sensors, they will potentially be more sensitive at their own wavelength. Output level will be small though.
P.S. I don't know the actual setup, presumable an LED on some front panel - obviously any ambient light will be a problem.
-
It might be overkill, but a super cheap camera sensor and some software it should be quite easy I think.
-
Do you mean that you're trying to avoid additional optical filters?
In that case consider https://www.sparkfun.com/products/12829 (https://www.sparkfun.com/products/12829)
It's basically a single pixel camera sensor. A single camera pixel has 3 sensors with a different optical filter infront of them.
-
The ready made RGB sensors are likely the easiest way.
There is a chance that one could use a set of LED as photo diodes. As a photodiode a LED should only react to the light it can emit or more energetic (more to the blue side of the visible spectrum) light.
So a yellow or orange LED should react to green light, but not to red light.
How good a LED works as a sensor can vary quite a bit by type. The current is expected to be quite small and would need sensitive amplifiaction.
-
I'm just a know-nothing hobbyist, but I would try an ambient color sensor like ams OSRAM TCS3601 (https://ams-osram.com/products/sensors/ambient-light-color-spectral-sensors/ams-tcs3701-color-and-proximity-sensor), with TCS37013M available at Mouser for about a dollar/euro apiece in singles. It runs off 1.8V, and communicates using I²C, so you might wish to use a suitable level shifter, say TCA9416D; and unless you already have a microcontroller, one with a suitable interface (and I²C) to your computer or whatever you use that needs to know the color. I'm sure even an ATtiny202 would suffice for this, as the detection is just comparing the four or five intensity components.
Note that even if you wish to set the detection thresholds at run time, the microcontroller can still be useful, as it can poll the sensor at relatively high frequency, and only report changes upstream.
-
Do you have to distinguish between red and green or would red/not red or green/not green be sufficient?
In this case any optical sensor and a piece of red or green acrylic would do the job.
Or is this considered as optical filter, and why is it to be avoided?
-
I was thinking if it would be possible to use two different solar cells, one that's more sensitive to the red led and one more sensitive to the green ... measure both voltages and figure out the color based on the differences in the voltage of the cells.
If you can't get close to the led then I can only think of a camera sensors or maybe infrared detectors (like the ones used in scroll wheel of mice
-
I was thinking if it would be possible to use two different solar cells, one that's more sensitive to the red led and one more sensitive to the green ... measure both voltages and figure out the color based on the differences in the voltage of the cells.
How would you do that without using optical filters, which OP doesn’t want? Solar cells are sensitive to a wide range of wavelengths, I doubt you could ever use them for color detection.
-
I wonder what spectrum a conventional LED would be sensible to.
You could also test if a normal photodiode generates different current depending on the wavelength, in that case you could simply read the voltage drop on the load, ex. 1.5V=red, 1.25V=green.
-
As a minor extension to Gyro's suggestion, maybe the detector is a dual Red/Green LED.
As a very vague, and incomplete thought - can anything useful be done with colour-mixing? For example if by default a blue light falls on the same place that the red or green fall...
-
RGB sensors are relatively cheap and the easiest path as others have said... as long as you have a microcontroller available. All the ones I have seen are I2C, so if you're expecting some kind of direct logic to control something, you'll be out of luck with those. Now an RGB sensor + a cheap MCU would be all you'd need.
You didn't mention what the distance between LED and sensor would be though (unless I missed it), nor the environment? Obviously if the sensor can't be placed close enough to the LEDs and/or there is external light around them, that may not work at all.
-
LEDs do work as photodiodes, sensitive to their own wavelength and shorter, so can be used here, I have used it a few times at work. Oddly they don't seem to be sensitive to that much shorter than their own wavelength but I don't know what the mechanism for that is. I found a red LED was pretty sensitive to red/orange/yellow, but for unknown reasons poorly sensitive to blue or UV. A green LED was sensitive to green/blue/near-UV. This is all LEDs in clear packages.
-
I wonder whether the mad scientist is going to return to his posting, while a dozen suggestions have been made.
-
LEDs work in reverse- an 560nm peak led will act as a 560nm centre tuned photodiode and so on. Glass clear types are not ideal, use the coloured diffuser ones.
Add a small signal darlington and you're away! A dual opamp set up as a pair o trancondctance amps will do it, just let the photocurrent drive it to the rail!
-
You might want to experiment with Red and Green LEDs as optical sensors, they will potentially be more sensitive at their own wavelength. Output level will be small though.
That does work. And I think Forrest Mims was the first one to do it.