+ Post New Thread
Page 1 of 2 1 2 LastLast
Results 1 to 20 of 34
  1. #1
    Junior Member level 2
    Points: 820, Level: 6

    Join Date
    Dec 2010
    Posts
    23
    Helped
    4 / 4
    Points
    820
    Level
    6

    Microcontroller-based: Electric fan switching- relay or triac?

    I have a project in which i will control the speed of the electric fan (220Vac, 60W, 5A max.) through the microcontroller automatically depending on the temperature. I was planning to replace the fan's switch with either a relay or triac. Min. time interval between switchings is 10seconds.

    Which do you think is better suited for the application: RELAY or TRIAC? why?

    Thanks..

  2. #2
    Advanced Member level 3
    Points: 6,081, Level: 18
    Achievements:
    7 years registered
    cameo_2007's Avatar
    Join Date
    Mar 2007
    Location
    12°58' N77°38'E
    Posts
    752
    Helped
    71 / 71
    Points
    6,081
    Level
    18

    Re: Microcontroller-based: Electric fan switching- relay or triac?

    Is it controlling the Speed or just switch off/on?
    control the speed With a Relay?? not a good choice

    Obviously it should be the Triac.


    1 members found this post helpful.

  3. #3
    Junior Member level 2
    Points: 820, Level: 6

    Join Date
    Dec 2010
    Posts
    23
    Helped
    4 / 4
    Points
    820
    Level
    6

    Re: Microcontroller-based: Electric fan switching- relay or triac?

    Is it controlling the Speed or just switch off/on?
    This electric fan has a switch for speed control (1,2,3). I can replace the rotary switch with relays or triacs, one for each speed level. Forget about phase control with triac, etc. All i need to do is switching.



    •   Alt7th January 2011, 04:24

      advertising

        
       

  4. #4
    Advanced Member level 5
    Points: 38,206, Level: 47
    Achievements:
    Created Album pictures Created Blog entry 7 years registered
    Tahmid's Avatar
    Join Date
    Jun 2008
    Location
    Silicon Valley, California, USA (from Dhaka, Bangladesh)
    Posts
    4,758
    Helped
    1788 / 1788
    Points
    38,206
    Level
    47
    Blog Entries
    22

    Re: Microcontroller-based: Electric fan switching- relay or triac?

    Hi,
    For only switching relay is ok. I still suggest triac as it is a solid-state solution, no mechanical parts.

    Hope this helps.
    Tahmid.


    1 members found this post helpful.

  5. #5
    Junior Member level 2
    Points: 820, Level: 6

    Join Date
    Dec 2010
    Posts
    23
    Helped
    4 / 4
    Points
    820
    Level
    6

    Re: Microcontroller-based: Electric fan switching- relay or triac?

    I think i've read something like triac consumes more power than relay.. i was also wondering how to turn the triac on and off with a microcontroller. Would it be like just give enough voltage/current to the gate turn it on, and to turn it off, just remove the gate voltage... or the gate voltage should be in sync with the 60Hz line voltage (zero crossing detector) to turn it on, and additional commutation circuit to turn it off?



  6. #6
    Advanced Member level 5
    Points: 38,206, Level: 47
    Achievements:
    Created Album pictures Created Blog entry 7 years registered
    Tahmid's Avatar
    Join Date
    Jun 2008
    Location
    Silicon Valley, California, USA (from Dhaka, Bangladesh)
    Posts
    4,758
    Helped
    1788 / 1788
    Points
    38,206
    Level
    47
    Blog Entries
    22

    Re: Microcontroller-based: Electric fan switching- relay or triac?

    Hi,
    Take a look at this:


    In this circuit, giving one to the transistor turns on the triac:



    I hope you understand why.

    Hope this helps.
    Tahmid.
    Last edited by Tahmid; 7th January 2011 at 17:54. Reason: Error in diagram. Fixed that.


    1 members found this post helpful.

  7. #7
    Junior Member level 2
    Points: 820, Level: 6

    Join Date
    Dec 2010
    Posts
    23
    Helped
    4 / 4
    Points
    820
    Level
    6

    Re: Microcontroller-based: Electric fan switching- relay or triac?

    In this circuit, giving one to the transistor turns on the triac
    Thanks for the schematic. How about turning it off, will it turn off if i give zero to the transistor?

    And the microcontroller is dc and the triac is ac so we cannot just connect their grounds.



  8. #8
    Super Moderator
    Points: 234,575, Level: 100
    Awards:
    1st Helpful Member

    Join Date
    Jan 2008
    Location
    Bochum, Germany
    Posts
    40,534
    Helped
    12391 / 12391
    Points
    234,575
    Level
    100

    Re: Microcontroller-based: Electric fan switching- relay or triac?

    Please check the above triac circuit for the correct connection of triac terminals and power supply. It's supposed to give a nice cloud of smoke when powered.

    To make it work correctly, MT1 has to be connected to neutral and the positive DC supply.

    P.S.:
    And the microcontroller is dc and the triac is ac so we cannot just connect their grounds.
    It's no problem, if you don't mind the microcontroller circuit being connected to the mains supply. Because you can't rely on neutral being actually at safe ground potential, you have to regard the complete circuit as "live" with respective safe insulation.
    Last edited by FvM; 7th January 2011 at 11:13.


    1 members found this post helpful.

    •   Alt7th January 2011, 11:06

      advertising

        
       

  9. #9
    Advanced Member level 5
    Points: 38,206, Level: 47
    Achievements:
    Created Album pictures Created Blog entry 7 years registered
    Tahmid's Avatar
    Join Date
    Jun 2008
    Location
    Silicon Valley, California, USA (from Dhaka, Bangladesh)
    Posts
    4,758
    Helped
    1788 / 1788
    Points
    38,206
    Level
    47
    Blog Entries
    22

    Re: Microcontroller-based: Electric fan switching- relay or triac?

    Please check the above triac circuit for the correct connection of triac terminals and power supply. It's supposed to give a nice cloud of smoke when powered.
    Why? This is properly shown. Microchip has also shown such a connection in AN958, fig 5:


    Plus I've found such circuits in commercial IR dimmers as well. They all work fine.

    Hope this helps.
    Tahmid.


    1 members found this post helpful.

  10. #10
    Super Moderator
    Points: 234,575, Level: 100
    Awards:
    1st Helpful Member

    Join Date
    Jan 2008
    Location
    Bochum, Germany
    Posts
    40,534
    Helped
    12391 / 12391
    Points
    234,575
    Level
    100

    Re: Microcontroller-based: Electric fan switching- relay or triac?

    Look sharp! In your previous schematic, you have connected neutral to 5V and live to MT1. So +/-300 V peak are applied over Q1, R6 and triac gate. The Microchip circuit is correct of course, because live connects to +5 and MT1.

    P.S.: As minor point, I would strictly avoid to exchange pins MT1 and MT2 in a circuit symbol. The numbers may be overlooked, and then you get the triac wrongly connected.

    Last edited by FvM; 7th January 2011 at 13:00.



    •   Alt7th January 2011, 12:54

      advertising

        
       

  11. #11
    Advanced Member level 5
    Points: 38,206, Level: 47
    Achievements:
    Created Album pictures Created Blog entry 7 years registered
    Tahmid's Avatar
    Join Date
    Jun 2008
    Location
    Silicon Valley, California, USA (from Dhaka, Bangladesh)
    Posts
    4,758
    Helped
    1788 / 1788
    Points
    38,206
    Level
    47
    Blog Entries
    22

    Re: Microcontroller-based: Electric fan switching- relay or triac?

    Yes, but the circuit I've shown is taken from a fellow member's circuit (circuit had error, fixed that, didn't see that, sorry) and I've found this configuration in a commercial IR dimmer circuit.

    And I've even tried by reversing live and neutral on that circuit and there's no "smoke" or anything as such. I've even built my IR fan speed controller on the very board and everything works as desired.
    Last edited by Tahmid; 7th January 2011 at 17:57.



  12. #12
    Super Moderator
    Points: 234,575, Level: 100
    Awards:
    1st Helpful Member

    Join Date
    Jan 2008
    Location
    Bochum, Germany
    Posts
    40,534
    Helped
    12391 / 12391
    Points
    234,575
    Level
    100

    Re: Microcontroller-based: Electric fan switching- relay or triac?

    Whatever you tell, be very sure that it does not work. But I'm basically satisfied, if we can agree, that the Microchip circuit is working correctly and should be suggested.

    P.S.: Sometimes schematics don't represent the actual circuit. Someone may have corrected them silently when assembling the circuit.



  13. #13
    Advanced Member level 5
    Points: 38,206, Level: 47
    Achievements:
    Created Album pictures Created Blog entry 7 years registered
    Tahmid's Avatar
    Join Date
    Jun 2008
    Location
    Silicon Valley, California, USA (from Dhaka, Bangladesh)
    Posts
    4,758
    Helped
    1788 / 1788
    Points
    38,206
    Level
    47
    Blog Entries
    22

    Re: Microcontroller-based: Electric fan switching- relay or triac?

    Why not give it a try and tell us the result? I have the circuit working, maybe you could give it a try.

    ---------- Post added at 18:10 ---------- Previous post was at 18:03 ----------

    P.S.: Sometimes schematics don't represent the actual circuit. Someone may have corrected them silently when assembling the circuit.
    There was no correction as the said circuit was on PCB and I traced the circuit from there and then made by circuit with that.
    Yes, the circuit provided by Microchip is fine.



  14. #14
    Advanced Member level 3
    Points: 6,081, Level: 18
    Achievements:
    7 years registered
    cameo_2007's Avatar
    Join Date
    Mar 2007
    Location
    12°58' N77°38'E
    Posts
    752
    Helped
    71 / 71
    Points
    6,081
    Level
    18

    Re: Microcontroller-based: Electric fan switching- relay or triac?

    Quote Originally Posted by crankler View Post
    This electric fan has a switch for speed control (1,2,3).
    Well, this was not there in your acual question.

    For this application , just use the relays and switch it on and done, and do not worry about the reliability etc etc, I have seen relays working for years without any fuss.
    Though triacs are the better option, you need to understand the functionality, circutry etc etc and finally you will end up not making anything.


    1 members found this post helpful.

  15. #15
    Advanced Member level 5
    Points: 38,206, Level: 47
    Achievements:
    Created Album pictures Created Blog entry 7 years registered
    Tahmid's Avatar
    Join Date
    Jun 2008
    Location
    Silicon Valley, California, USA (from Dhaka, Bangladesh)
    Posts
    4,758
    Helped
    1788 / 1788
    Points
    38,206
    Level
    47
    Blog Entries
    22

    Re: Microcontroller-based: Electric fan switching- relay or triac?

    @ FvM,
    Hi, here are the PCBs of the circuit I was talking about and it's working fine. You should give the circuit a try and see what happens.






    Tahmid.



  16. #16
    Super Moderator
    Points: 234,575, Level: 100
    Awards:
    1st Helpful Member

    Join Date
    Jan 2008
    Location
    Bochum, Germany
    Posts
    40,534
    Helped
    12391 / 12391
    Points
    234,575
    Level
    100

    Re: Microcontroller-based: Electric fan switching- relay or triac?

    Unfortunately, I can't decode the wiring from the PCB bottom. Do you have a sharp foto or a copy of the artwork?



  17. #17
    Advanced Member level 5
    Points: 38,206, Level: 47
    Achievements:
    Created Album pictures Created Blog entry 7 years registered
    Tahmid's Avatar
    Join Date
    Jun 2008
    Location
    Silicon Valley, California, USA (from Dhaka, Bangladesh)
    Posts
    4,758
    Helped
    1788 / 1788
    Points
    38,206
    Level
    47
    Blog Entries
    22

    Re: Microcontroller-based: Electric fan switching- relay or triac?

    Hi,
    The proper camera is out of order. I'll upload a much clearer photo by day after tomorrow. By the time, you can try the circuit and find out if it's working or not.

    ---------- Post added at 22:27 ---------- Previous post was at 22:12 ----------

    I scanned this using my scanner as the camera is out of order:


    ---------- Post added at 22:42 ---------- Previous post was at 22:27 ----------

    O, I see what you mean. The diagram had an error. Sorry for the confusion.
    Last edited by Tahmid; 7th January 2011 at 17:53. Reason: Added image and comment



  18. #18
    Super Moderator
    Points: 234,575, Level: 100
    Awards:
    1st Helpful Member

    Join Date
    Jan 2008
    Location
    Bochum, Germany
    Posts
    40,534
    Helped
    12391 / 12391
    Points
    234,575
    Level
    100

    Re: Microcontroller-based: Electric fan switching- relay or triac?

    Good, everything clear now, the photo and the circuit.



    •   Alt7th January 2011, 18:16

      advertising

        
       

  19. #19
    Junior Member level 2
    Points: 820, Level: 6

    Join Date
    Dec 2010
    Posts
    23
    Helped
    4 / 4
    Points
    820
    Level
    6

    Re: Microcontroller-based: Electric fan switching- relay or triac?

    Whoa,,didn't expect there would be arguments.. by the way, thanks to Tahmid & FvM.. i thought MT1 and MT2 are interchangeable. Didn't expect that Line can be connected to +5v safely.

    So it would work without a zero-crossing detector?
    And if i give enough voltage/current to the gate, the triac will turn off, and if i remove the gate voltage/current, the triac will instantly turn off?

    I just thought that SCRs are more difficult to turn off, requiring a commutation circuit and it might also be the same with the TRIAC...?



  20. #20
    Super Moderator
    Points: 234,575, Level: 100
    Awards:
    1st Helpful Member

    Join Date
    Jan 2008
    Location
    Bochum, Germany
    Posts
    40,534
    Helped
    12391 / 12391
    Points
    234,575
    Level
    100

    Re: Microcontroller-based: Electric fan switching- relay or triac?

    For on/off switching of inductive loads, zero crossing detectors are generally unwanted in my view. For gavanically isolated control, a MOC302x opto triac is the most simple solution.

    Ignoring zero crossings mean, turn the output on or off at will. The triac (or SCR) will immediately turn on, but turn off delayed after the next load current zero crossing (which is not exactly identical to voltage zero crossing with inductive loads). A RC snubber would be needed at least with MOC302x to prevent dV/dt self triggering, but doesn't harm with triacs in general.


    1 members found this post helpful.

--[[ ]]--