I'm working on my first electronics/Arduino project to control two pairs of motors. Currently, the motors are controlled by a simple four-button, wired remote controller, where each button controls a pair of the motors. I was hoping to replace this remote with an Arduino/Raspberry Pi and a 4-channel relay board to control wirelessly. I already have everything set up to where I can control the relays wirelessly through my phone.

The issue I'm having is that I'm trying to figure out the proper way to wire up the relays to the motors. Each relay has three terminals, and there are a total of 10 wires coming into the controller (remember that 4 of them being redundant as there are two pairs of motors):

  1. Motor 1 up (M1+) x2 --> Relay 1 NO
  2. Motor 1 down (M1-) x2 --> Relay 2 NO
  3. Motor 2 up (M2+) x2 --> Relay 3 NO
  4. Motor 2 down (M2-) x2 --> Relay 4 NO
  5. VCC --> ???
  6. GND --> ???

Wiring up the motors is easy enough. But I'm unsure of how to connect the single VCC & GND wires to each of the four relays. Should these wires be split into four? Or is there something else I need?

I've attached two images: a simple diagram of the wiring, and a picture showing the remote. On the remote there are four Toneluck MQS-1D microswitches, if that matters. Thanks!

Simplified wiring diagram Front and back of the controller


1 Answer 1


When we look at the internal circuit diagram of the relay it looks like the following:

enter image description here

I have also added one motor to show how the connections are to be made.

Vcc is the signal given by the microcontroller (one of the output pins from the Arduino). When this signal is given the SPDT switch changes state to NO. This completes the circuit and the motor will rotate.

Note Vcc is just a 5v signal if from the microcontroller (Assuming this is the rating of the relay). But Bat2 needs so supply the required voltage and current for the motor to run.

Now moving onto what you want to achieve in your project, the description is vague. You are running 2 pairs of motors with 4 Relays. I presume each pair is controlled by 2 switches. One for moving forward and one for moving backward. The same for the other pair.

The circuit diagram looks like the following:

enter image description here

Truth Table: U1 - M1 and M2 Forward

U2 - M1 and M2 Backward

U3 - M3 and M4 Forward

U4 - M3 and M4 Bakcward

U1 and U2 - Nothing

U3 and U4 - Nothing

All other combinations can be inferred as M3 and M4 are isolated from M1 and M2. You have to make sure your battery can handle running all 4 motors at once though.

enter image description here

  • \$\begingroup\$ Hi Akash, thanks for the answer. I think you got a good idea of what I'm trying to do--your schematic looks like what I have been planning on going with. The question I'm asking is, how do I connect a single GND or single Vin wire in your schematic to all four relays? Should these wires be split into four? \$\endgroup\$ Apr 29, 2015 at 0:24
  • \$\begingroup\$ @Threeve The Circuit diagram i posted we for an electronic relay. What you are using is a microswitch which responds to mechanical input. A SPDT relay contains 5 terminals, a microswitch only 3. So do you want help in designing a system using a microswitch, because it essentially acts as a button. Source:youtube.com/watch?v=q6nP1FjxAMU \$\endgroup\$
    – Sada93
    Apr 29, 2015 at 4:40
  • \$\begingroup\$ @Threeve If it is Mechanical input that you want, you can still use the circuit diagram above by just ignoring Vcc1, Vcc2 ... (the entire left side). To connect Vcc, provide power to the Vcc terminal but also short Vcc and the empty terminal next to it. This shorts all the NO terminals and connects them to Vcc. You also need to short ground with the terminal to the left of it which is empty. Connect this ground to the negative of your supply. \$\endgroup\$
    – Sada93
    Apr 29, 2015 at 4:55
  • \$\begingroup\$ Apologies if I wasn't clear enough. I'm not looking to replace the microswitches on the board with relays--I want to remove the controller completely and replace it with a separate 4-channel relay board. This question is less about schematics and more about what's the best practice to physically wire the relay board. By removing the controller completely, how would I wire a single incoming VCC (and GND) to the four terminals on each of the relays? Do I make a 4-way splice from the relays to the single VCC and GND wires, or is there another configuration I should use? Thanks! \$\endgroup\$ Apr 29, 2015 at 14:34
  • \$\begingroup\$ Yes, if you are replacing it completely with a 4 channel relay you will need to "splice" or short the single VCC with all 4 relays and the ground of all 4 relays with the negative of your supply (as seen in the circuit diagram). This power source will drive your motor. Do not use the on board VCC of the arduino as it cannot handle the current requirement of the motor and may damage it. The arduino/microcontroler is used only to control the motors through the current coil as seen in the circuit diagram above. \$\endgroup\$
    – Sada93
    Apr 29, 2015 at 16:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.