Relay chatter

Discussion in 'General Electronics Chat' started by stratus, Nov 16, 2009.

  1. stratus

    Thread Starter New Member

    Nov 16, 2009
    8
    0
  2. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    Here's the schematic:

    [​IMG]

    The problem is that there is no hysteresis in the control loop.

    Hysteresis definitions: http://en.wikipedia.org/wiki/Hysteresis
    Scroll about 2/3 of the way down under Electronics.

    To add hysteresis, feedback (in the form of a resistor) needs to exist between the output of the opamp (used as a comparator) pin 6, and the noninverting input pin 3.

    Without making any extensive analysis, try connecting a 47k resistor in series with a 500k potentiometer wired as a rheostat (just one "end" terminal and the middle terminal used) across pins 3 and 6. Adjust the pot until the relay stops clattering, but it does switch when the sunlight level changes significantly.

    [eta]
    Also, a large capacitor (1,000uF to 3,300uF) should be added across the supply of the relay, and a small cap (0.1uF) across the supply of the comparator
     
    Last edited: Nov 16, 2009
  3. stratus

    Thread Starter New Member

    Nov 16, 2009
    8
    0
    Thank you for your answer.As i have said i am a newbie to electronics so i want to ask you if it is possible to sketch it.
     
  4. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    OK, here's an edited version:

    [​IMG]

    I missed the fact that there already is a capacitor present; C1, 100uF. That is rather small, considering that a relay is being driven in the same circuit. I would increase it to the range I wrote in my prior post.
     
  5. stratus

    Thread Starter New Member

    Nov 16, 2009
    8
    0
    Thank you again.I will try it.
     
  6. stratus

    Thread Starter New Member

    Nov 16, 2009
    8
    0
    Unfortunately it does not working.
     
  7. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    OK, so tell us about this 12v relay that you are using.
    What is its' coil resistance? How much current does it use?

    Tell us about your fan. How much current does it use?

    Tell us about your solar panel; what is its' wattage rating?
     
  8. stratus

    Thread Starter New Member

    Nov 16, 2009
    8
    0
    Last edited: Nov 17, 2009
  9. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    OK, there is still not enough hysteresis.

    Decreasing the 47k resistor/500k pot is really not a good option, as that would tend to load the output of the opamp too much.

    However, increasing R2 and R3 is definitely do-able.
    R3 is currently 10k Ohms.
    R2 is currently 4.7K Ohms.
    If the hysteresis loop is not considered, this gives a voltage level of Vsolarpanel x (R2/(R3+R2)).
    If the solar panel is generating 12v, then the voltage level will be: 12 x (R2/(R3+R2)) = 12 x (4.7k/14.7k) = 12 x 0.319 = 3.828V.

    We can simply increase both the values of R2 and R3, maintaining approximately the same ratios. This will give approximately the same effect as decreasing the 47k/500k hysteresis feedback loop, but will not add any more load to the output of the opamp.
    Since R3 is currently 10k Ohms, increase it to 43k Ohms.
    Since R2 is currently 4.7K Ohms, increase it to 20k Ohms.

    20k/(43k+20k) = 20/63 = 0.317; our previous ratio was 0.319. This is plenty close enough.

    You should then be able to obtain several volts worth of hysteresis. Each time you change the hysteresis via the 500k pot, you will need to re-adjust P1 to set the trip voltage level.
     
  10. stratus

    Thread Starter New Member

    Nov 16, 2009
    8
    0
    I just saw that instead of 47k resistor i put 470k! resistor.I put the right resistor tomorrow and i inform you about the result.If it does not work i will follow the last procedure.
     
  11. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    The 470k resistor would explain a big part of it.

    I don't know how much your solar panel voltage will drop when the relay coil and fan load is transferred from the battery to the solar panel and back again. That is why the relay is chattering.

    When the load of the coil and fan is transferred from the solar panel to the battery because the solar panel voltage decreased, the voltage output of the solar panel goes up due to the decrease in load. The opamp "sees" that voltage increase, and "decides" to switch the load back to the solar panel. The voltage output of the solar panel then drops, and the cycle repeats indefinitely.

    Adding the right amount of hysteresis will help a great deal to reduce or completely eliminate that chattering. If you don't have enough hysteresis, the relay will chatter. If you have too much hysteresis, you will notice that the fan speed will vary (slow down) a great deal before the fan power reverts to battery powered operation.
     
  12. stratus

    Thread Starter New Member

    Nov 16, 2009
    8
    0
    It is working fine.The weather was clear today but i have the "relay chatter" problem and during the sunset and today the problem disappears.I will wait to test it with the clouds to be sure that is ok.Thank you for your help
     
  13. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    Glad it seems to be working better. :)

    You could simulate the cloud cover during bright daylight by slowly covering your panel with something opaque, like a piece of cardboard, a scrap of plywood, a jacket, tarpaulin, etc. - just anything that would block the sunlight (gradually) from directly shining on the solar cell.

    Did you just replace the 470k resistor with the 47k resistor? Or did you go for "the whole enchilada" and replace R2/R3 with the 20k and 43k resistors?
     
  14. stratus

    Thread Starter New Member

    Nov 16, 2009
    8
    0
    I just replace the 470k resistor with the right 47k.
     
Loading...