Color Sensor

Discussion in 'Electronic Projects' started by BM Engineer, Mar 20, 2017.

  1. BM Engineer

    BM Engineer

    Joined:
    Mar 12, 2017
    Messages:
    10
    Likes Received:
    0
    Hello,
    I want to develop a circuit that detects the orange color of an LED and measure the time the LED orange light is on.
    I want to measure the orange light of 10 LED apart from each other. and they are placed in different places. Can I use one microcontroller? how to connect them ?
    What are the best color sensors.? Also, I want to make it as cheap as possible. So, what are the cheapest components to use ( like The microcontroller and so on).?
     
    BM Engineer, Mar 20, 2017
    #1
    1. Advertisements

  2. BM Engineer

    davenn Moderator

    Joined:
    Sep 5, 2009
    Messages:
    11,666
    Likes Received:
    1,313
    Location:
    Sydney, Australia
    and how far apart are the LEDs and the detector going to be ?
    you are going to have to filter out ALL other light sources ... will be difficult
     
    davenn, Mar 20, 2017
    #2
    1. Advertisements

  3. BM Engineer

    BM Engineer

    Joined:
    Mar 12, 2017
    Messages:
    10
    Likes Received:
    0
    1cm
     
    BM Engineer, Mar 21, 2017
    #3
  4. BM Engineer

    Alec_t

    Joined:
    Jul 7, 2015
    Messages:
    1,712
    Likes Received:
    469
    Location:
    Wales
    Is the LED light always orange, or does the colour change?
     
    Alec_t, Mar 21, 2017
    #4
  5. BM Engineer

    BM Engineer

    Joined:
    Mar 12, 2017
    Messages:
    10
    Likes Received:
    0
    It's always orange ..
    Actually, It's an indicator led for a medical device, I want to record the time a certain program is on - the led is on whenever the program is active
     
    BM Engineer, Mar 23, 2017
    #5
  6. BM Engineer

    Alec_t

    Joined:
    Jul 7, 2015
    Messages:
    1,712
    Likes Received:
    469
    Location:
    Wales
    A photo-transistor or light-dependent-resistor in direct contact with the LED could exclude extraneous light easily, but presumably the LED has to be visible also to a human when the device is in use?
     
    Alec_t, Mar 23, 2017
    #6
  7. BM Engineer

    BM Engineer

    Joined:
    Mar 12, 2017
    Messages:
    10
    Likes Received:
    0
    Yes it's visible
    but it's small
    can I use A photo-transistor or light-dependent-resistor anyway?
     
    BM Engineer, Mar 25, 2017
    #7
  8. BM Engineer

    Bluejets

    Joined:
    Oct 5, 2014
    Messages:
    1,745
    Likes Received:
    349
    If you are only detecting when it is on you could just measure the voltage across it.
     
    Bluejets, Mar 25, 2017
    #8
    Arouse1973 likes this.
  9. BM Engineer

    (*steve*) ¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd Moderator

    Joined:
    Jan 21, 2010
    Messages:
    22,450
    Likes Received:
    1,866
    Location:
    Mid way between Beijing and the Ronne Ice Shelf
    Yet again, I think it's time that you let us in on what the problem is you're trying to solve. While your solution might turn out to be the best one, it might also be unnecessarily complex.

    What are you trying to achieve?
     
    (*steve*), Mar 26, 2017
    #9
  10. BM Engineer

    Alec_t

    Joined:
    Jul 7, 2015
    Messages:
    1,712
    Likes Received:
    469
    Location:
    Wales
    Yes. What I'd probably do is put the light sensor in a housing mounted right over the LED so as to exclude all extraneous light. That of course would prevent the user seeing the LED, so I'd then use the sensor signal to light another LED visible to the user.
     
    Alec_t, Mar 26, 2017
    #10
    BM Engineer likes this.
  11. BM Engineer

    Herschel Peeler

    Joined:
    Feb 21, 2016
    Messages:
    400
    Likes Received:
    65
    Location:
    Las Vegas
    A LED can also be used as a light sensor. Light falling on an LED generates a voltage. The color of the lens (poorly) filters in that color. So an orange LED selects predominately the orange light.

    I don't know if they will be sensitive enough for you though. A CdS cell (photo resistor) or phototransistor might be better.
     
    Last edited by a moderator: Apr 4, 2017
    Herschel Peeler, Mar 27, 2017
    #11
  12. BM Engineer

    BM Engineer

    Joined:
    Mar 12, 2017
    Messages:
    10
    Likes Received:
    0
    Yes
    I was a little bit confused when I posted this
    I want to measure the on time of a LED which is an indicator for a certain program running in a medical device. In other words, I want to measure each time the program is activated.
     
    Last edited by a moderator: Apr 4, 2017
    BM Engineer, Mar 28, 2017
    #12
  13. BM Engineer

    (*steve*) ¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd Moderator

    Joined:
    Jan 21, 2010
    Messages:
    22,450
    Likes Received:
    1,866
    Location:
    Mid way between Beijing and the Ronne Ice Shelf
    The problems are threefold:
    1. It's a medical device so we wouldn't suggest anything invasive, or even completely obscuring the LED and providing a duplicate controlled by your circuit.
    2. Non-contact to a relatively low intensity signal in conditions of unknown and probably variable ambient lighting.
    3. Unknown method of attachment.
    OK, so let's ignore 1 and 3 and go with the non-contact optical sensor. it would make a lot of sense to have two identical sensors, one pointing at the LED and the other pointing adjacent to the LED. You would then amplify the differential between these two sensors. That should help significantly in eliminating some of the effects of variable ambient lighting. (you could also point the second sensor to a dummy LED. This could be the top of a LED cut off and stuck to the case near the real one. This may help in getting better readings from the reference sensor.)

    It is also possible to achieve this by using a single sensor and amplifying the difference between the current signal and a low-pass filtered version of it. This presumes that changes in ambient lighting will be slower than the rate of change of light intensity of the LED as it switches on and off.

    At the output, you would again be looking for pulses with a fast rising or falling edge indicating a change in state of the LED. Depending on lighting conditions or noise, it is quite possible that you might detect extra edges or miss some.

    Is it important that you get the duration of every flash of the LED?

    Is there a maximum and minimum time the LED is on (or indeed off between pulses)? This may allow some transitions to be ignored.

    For best results you woul probably want to process the signal using a microcontroller so it can determine when it thinks the LED is actually on and off. As a simple test it can try to duplicate the LED status and you can visually check to see if it's getting things reasonably right. Using an oscilloscope you can compare the signal from your sensor to the output from the microcontroller to check for small glitches that are not visible.

    Once you have the detection of pulses working sufficiently well, I guess you'll want to do something else with them. The microcontroller may be able to assist there too.
     
    (*steve*), Mar 28, 2017
    #13
  14. BM Engineer

    Bluejets

    Joined:
    Oct 5, 2014
    Messages:
    1,745
    Likes Received:
    349
    You might be able to look at monitoring what turns the led on as it might be as simple as monitoring power supply on/off.
    Not enough info.
     
    Bluejets, Mar 28, 2017
    #14
  15. BM Engineer

    RodB

    Joined:
    Mar 19, 2017
    Messages:
    3
    Likes Received:
    1
    Hi - I once worked for an engineer that used a camera chip to analyse LED color. The output from the camera was fed to a microprocessor and analysed to determine the time it took for the LED light to pass through a pane of glass. You might be able to use this for determining if the light is on and how long it stays on.

    Rod
     
    RodB, Apr 4, 2017
    #15
    1. Advertisements

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Similar Threads
  1. Silvester Taylor

    Zenith Color tv Model # H2017Y7 Color problem

    Silvester Taylor, Dec 29, 2003, in forum: Electronic Repair
    Replies:
    1
    Views:
    764
    Jerry G.
    Dec 29, 2003
  2. Arvis N.
    Replies:
    0
    Views:
    866
    Arvis N.
    Aug 19, 2004
  3. Arvis N.
    Replies:
    4
    Views:
    970
    James Sweet
    Aug 31, 2004
  4. Jacques Carrier

    Zenith 25" color TV SM2568S CRT board color adjustments

    Jacques Carrier, Sep 27, 2004, in forum: Electronic Repair
    Replies:
    2
    Views:
    1,352
    Asimov
    Sep 27, 2004
  5. Jerome Halphen
    Replies:
    0
    Views:
    6,613
    Jerome Halphen
    Jan 16, 2005
  6. clout45@gmail.com

    color problems with my Panasonic CTZ2137A color TV

    clout45@gmail.com, Apr 17, 2006, in forum: Electronic Repair
    Replies:
    0
    Views:
    637
    clout45@gmail.com
    Apr 17, 2006
  7. Ben
    Replies:
    0
    Views:
    1,073
  8. Guest
    Replies:
    5
    Views:
    491
    CWatters
    May 20, 2005
Loading...