Switching power and polarity with relays.

Discussion in 'The Projects Forum' started by Falven, Jan 20, 2012.

  1. Falven

    Thread Starter New Member

    Feb 27, 2010
    15
    0
    Hello!
    I am pretty new at electronics.
    I need to create a circuit to switch a 12v motor on and off; also reverse it's polarity.

    I have:
    3 SPST relays 5v 5A cr.
    2 DPDT relays 12v 5A cr.
    My control is a 5v source that needs to switch the circuit on/off and reverse the polarity (a microcontroller).

    Specifically, what I need is to be able to:
    1. Cut power to the circuit on or off using the 5v source.
    2. Switch the polarity of the motor using the 5v source.

    I have been trying to draw a circuit but I can't wrap my head around the polarity switching.

    Thanks,
    -Francisco
     
  2. PaulEE

    Member

    Dec 23, 2011
    423
    32
    I assume you have two separate signals, one for polarity, and one for on/off...right?
     
  3. Falven

    Thread Starter New Member

    Feb 27, 2010
    15
    0
    Yes i do :)
     
  4. BillB3857

    Senior Member

    Feb 28, 2009
    2,400
    348
  5. Falven

    Thread Starter New Member

    Feb 27, 2010
    15
    0
    Heh, a little over my head, remember I'm a beginner...
     
  6. praondevou

    AAC Fanatic!

    Jul 9, 2011
    2,936
    488
    you need 1 dpdt and 1 spst relay. (5V coils)

    [​IMG]
     
    Falven likes this.
  7. Falven

    Thread Starter New Member

    Feb 27, 2010
    15
    0
    Yeah I couldn't find a 5v dpdt 5a cr relay anywhere... Radioshack, mouser, digikey...
     
  8. praondevou

    AAC Fanatic!

    Jul 9, 2011
    2,936
    488
    ok then, 2x 5V spst, 1x 12V dpdt. If these are polarized relays (with built in diode) make sure you connect them correctly.

    [​IMG]

    edit: you may want to put the upper SPST relay in series with the motor power supply... that way you will also cut the power supply to the DPDT relay in case "polarity" is activated
     
    Last edited: Jan 20, 2012
  9. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    Wait a minute -
    Get a couple of SPDT relays from an auto parts store.
    Use NPN transistors (2n2222) to open/close the ground path for the relay coils.

    You will need diodes across the relay coils, or you will "zap" the transistors/uC.

    Will someone please locate the schematic I've posted on this subject a number of tiimes? It's hard for me to search on this "WebTV".
     
    Last edited: Feb 12, 2014
  10. praondevou

    AAC Fanatic!

    Jul 9, 2011
    2,936
    488
    I also think you mentioned "microcontroller"?

    Are you sure the uC can actually directly drive the 5V relays?

    What uC is it and what is the current consumption of the 5V relay coils?
     
  11. Falven

    Thread Starter New Member

    Feb 27, 2010
    15
    0
  12. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
  13. Falven

    Thread Starter New Member

    Feb 27, 2010
    15
    0
    ATMEGA328 or ATMEGA1280
    Both say they can write 5V to a pin.
    http://arduino.cc/en/Reference/DigitalWrite

    Can't change the 5v source, it's a microcontroller that can write 5v at most. I have used it to switch 5v relays before so that should work.
     
  14. praondevou

    AAC Fanatic!

    Jul 9, 2011
    2,936
    488
    Wookie, like this?

    No idea what current can be supplied by the uC nor what relay the OP has...
    [​IMG]

    EDIT: Come on Sgt! How can you be so fast on a WebTV??? I wasn't even trying to find the post you referred to, looking through more than 20000 posts... :-/
     
    Last edited: Jan 20, 2012
  15. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    Decrease the 2k2 resistors to 220.

    AT LEAST 20mA.
     
  16. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    It's not that I was so fast; it's simply that I remkembered the exact filename of the image:
    MotorReverseRelayTransistor.PNG
    Then seaching was quite fast.
     
  17. praondevou

    AAC Fanatic!

    Jul 9, 2011
    2,936
    488
    How much current can you draw from it? Will it supply 24mA each output?


    If you use Sgts' circuit you can drive it with 5V. The uC output drives a transistor, the transistor drives a relay.
     
  18. Falven

    Thread Starter New Member

    Feb 27, 2010
    15
    0
    From http://arduino.cc/en/Tutorial/DigitalPins:

    I do have some transistors (3x) laying around.
    1. http://www.radioshack.com/product/index.jsp?productId=2062617
    2. http://www.radioshack.com/product/index.jsp?productId=2062618
    3. http://www.radioshack.com/product/index.jsp?productId=2062613

    Thanks
     
  19. Falven

    Thread Starter New Member

    Feb 27, 2010
    15
    0
    So will this circuit work but instead of using the 2k2 resistors I should use 220 ohm resistors?.
     
  20. praondevou

    AAC Fanatic!

    Jul 9, 2011
    2,936
    488
    Yes. The SPST is a 12V relay though.

    Your options are either to drive transistors which then drive directly 12V relays OR the uC drives the 2x 5V relays, one of them driving the 12V DPDT. I posted the other option below.

    If you already bought the relays I'd think just using relays would be easier.

    BUT the contact rating of the relays you linked to is 5A max for resistive load. A motor is not a resistive load. You also said 5A would be the maximum load current. The relays are then not suitable . The circuit is only suitable for a smaller load current. If you want to use it the way it is you'd need relays with higher contact rating. (only the relays that carry load current)

    I included the diodes.
    [​IMG]

    I have to go now, sorry.
     
Loading...