1. Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.
    Dismiss Notice

CdS Cell Range

Discussion in 'Electronic Projects Design/Ideas/Reviews' started by ADWSystems, Sep 2, 2017.

  1. ADWSystems

    ADWSystems Member

    Joined:
    Mar 14, 2008
    Messages:
    711
    Likes:
    5
    Location:
    USA
    I have not had the opportunity to employ as Cds in the manner, but it seems a correct usage or at least a popular one.

    The goal is to be able to differentiate bright sun, from clouds, from dark. The typical circuit is a CdS cell-resistor voltage divider connected to a ADC.

    If we take a given the Cds Cell in bright sun is 10K and darkness as 100K (just some numbers to work with). What resistor value should be used to achieve the highest range (given 0-5V)? A 10K resistor will be 0.45V to 2.5V. Is there more to be had without burning out the CdS cell?
     
  2. alec_t

    alec_t Well-Known Member Most Helpful Member

    Joined:
    Jul 10, 2011
    Messages:
    9,253
    Likes:
    1,218
    Location:
    Cardiff, Wales
    The resistance range of a cell can be around 100:1 (e.g. a few k to nearly 1 meg). Check the datasheets of typical cells.
     
  3. crutschow

    crutschow Well-Known Member Most Helpful Member

    Joined:
    Mar 14, 2008
    Messages:
    10,592
    Likes:
    477
    Location:
    L.A., USA Zulu -8
    Here's an LTspice simulation for an Rcds variation of 10kΩ to 100k Ω and load resistors of 10kΩ, 25kΩ, 50k, and 100kΩ.
    Which looks best to you?

    You shouldn't have to worry about burning the CdS for a supply voltage of 5V as long as the load resistor is at least 1kΩ.

    upload_2017-9-2_15-55-7.png
     
    • Like Like x 1
  4. dave

    Dave New Member

    Joined:
    Jan 12, 1997
    Messages:
    -
    Likes:
    0


     
  5. audioguru

    audioguru Well-Known Member Most Helpful Member

    Joined:
    Mar 16, 2004
    Messages:
    32,443
    Likes:
    935
    Location:
    Canada, of course!

    Years ago, my solar garden lights had a Cds cell to turn the LED on and off. But the Chinese Cds cells had such poor quality that they got sunburned and failed.
    Now solar garden lights do not have a Cds, instead they use the solar panel to "see" light or dark.
     
  6. ADWSystems

    ADWSystems Member

    Joined:
    Mar 14, 2008
    Messages:
    711
    Likes:
    5
    Location:
    USA
    That sounds like two birds with one stone. (1) Get rid of a part that (2) fails anyway. :)
     
  7. ADWSystems

    ADWSystems Member

    Joined:
    Mar 14, 2008
    Messages:
    711
    Likes:
    5
    Location:
    USA
    My assumption (gut feeling) was correct. There isn't a simple way to expand the operating range of the simple CdS-Resistor combination to fill most of the 5V range. At 10K, it uses the lower half, at 100K the upper half, anything in between uses the in between. I can either gain the output with an opamp or raise the pullup voltage on the Cds-Resistor.
     
  8. audioguru

    audioguru Well-Known Member Most Helpful Member

    Joined:
    Mar 16, 2004
    Messages:
    32,443
    Likes:
    935
    Location:
    Canada, of course!
    But the cheap Chinese solar panels also get sunburned and fail (the plastic face has poor ultraviolet protection). The solar panels with a glass face are fine if they are sealed properly so that rain does not corrode the rear (most solar garden lights are sealed poorly).
     
  9. crutschow

    crutschow Well-Known Member Most Helpful Member

    Joined:
    Mar 14, 2008
    Messages:
    10,592
    Likes:
    477
    Location:
    L.A., USA Zulu -8
    Why do you need to have a 5V range.
    Do you really need the full resolution of the ADC for your sensing purposes?
     
  10. ADWSystems

    ADWSystems Member

    Joined:
    Mar 14, 2008
    Messages:
    711
    Likes:
    5
    Location:
    USA
    Notice I said "most of the 5V range", not all or the full range. I don't think I could get all of it and with variation of the CdS cells probably lose some at the top and bottom anyway. So the target is most. As you notice with the 10k simulation, the range is 0.45V to 2.5V, 2-2.5V of the 5V range. I find it better to get as much as you can when you start. It's easier than realizing later you need more and having to redesign.
     
  11. alec_t

    alec_t Well-Known Member Most Helpful Member

    Joined:
    Jul 10, 2011
    Messages:
    9,253
    Likes:
    1,218
    Location:
    Cardiff, Wales
    Many (most?) ADCs require a source impedance of <10k to obtain reasonable accuracy, so you will probably need to buffer the voltage across the cell. If so, the buffer amp can have gain and offset to give a full 0V-5V input range to the ADC.
     
  12. ADWSystems

    ADWSystems Member

    Joined:
    Mar 14, 2008
    Messages:
    711
    Likes:
    5
    Location:
    USA
    Non-inverting opamp buffer?

    Wouldn't most CdS circuits of this configuration then require the voltage to be buffered? Based on my (elementary evaluations) we are talking about resistors in the 1k-10k range and CdS resistance in the 1k-1Meg range, thereby rarely providing impedances <10k.
     
  13. alec_t

    alec_t Well-Known Member Most Helpful Member

    Joined:
    Jul 10, 2011
    Messages:
    9,253
    Likes:
    1,218
    Location:
    Cardiff, Wales
    That would be my approach. Your mileage may differ, depending on what accuracy you need.
    Are we? The simulation above is for resistance in the 10k-100k range :confused:.
     
  14. ADWSystems

    ADWSystems Member

    Joined:
    Mar 14, 2008
    Messages:
    711
    Likes:
    5
    Location:
    USA
    From the simulation, I prefer to eat my sandwiches from the end not from the middle. From your simulation, likely the 10K as it appears to be more linear than the 100k (I haven't had time to do calculations yet to verify). I've received PMs stating a 10K would be the maximum and I should be looking in the 1k-10k range.
     
  15. MikeMl

    MikeMl Well-Known Member Most Helpful Member

    Joined:
    Mar 17, 2009
    Messages:
    11,045
    Likes:
    541
    Location:
    AZ 86334
    Yes, the ADC wants a source impedance of <=10K. Yes, it is more convenient to use a resistive divider that has an output impedence of >10K. Solve the problem by shunting the ADC input to ground with a 0.1 uF capacitor, after all, the clouds do not move that fast...

    I have used this trick when sensing 12V battery voltage, where I wanted the two resistors in the divider to be high enough not to provide much leakage to the battery (>~100K). The capacitor holds the voltage at the tap constant while the AD does its dance ( a few tens of micro-sec ). The DC input leakage spec for the AD is ~1uA, which does not load the voltage divider much. Again, the battery voltage changes slooowly.

    Besides, you are supposed to use an "anti-aliasing" filter upstream of any ADC input...
     
    Last edited: Sep 4, 2017
    • Like Like x 1
  16. ADWSystems

    ADWSystems Member

    Joined:
    Mar 14, 2008
    Messages:
    711
    Likes:
    5
    Location:
    USA
    I assume you mean a 0.1uF to ground?

    That's a new rule on me. I'll check into it.
     
  17. MikeMl

    MikeMl Well-Known Member Most Helpful Member

    Joined:
    Mar 17, 2009
    Messages:
    11,045
    Likes:
    541
    Location:
    AZ 86334
    Yes, and this is quite readable.
     
    Last edited: Sep 4, 2017

Share This Page