Troubleshooting Voltage Drop to Motors

We recently started building a mecanum car, starting with this kit:

We are using an Arduino Nano, an LM2596 Buck Converter, 2 DRV8833 Motor Drivers, a LiPo 2S 7.4V 5200Mah 50C battery, a Terminal Block Distribution Module, and a RadioLink T8S

The DRV8833 is not the exact one that is in the Fritzing diagram


The Fritzing Breadboard Diagram:

Everything is working just ok. The car can be driven by the remote and the cool mecanum steering is working as intended. However, the voltage going to the motors seems way too low and this where I’m hoping for some assistance.

We are using this DRV8833 motor driver: GitHub - TheArduinist/DRV8833: A Arduino-based library for the Pololu DRV8833 dual motor driver carrier and using the non-speed option as we are just looking for On/Off at this point.

Using a multimeter, the voltage from the battery is ~7.8V and remains 7.8V at both motor drivers VCC/GND. However, the output on both OUT1/2s and OUT3/4s is only ~2.2V.

When we run a test setup with just one motor driver and one motor, we get 7.8V out to the motor.

So we’re struggling to sort out what is going on how to fix this. My electrical knowledge is very rusty, but I believe the motors are wired in parallel so they should each be getting 7.8V (which they are at the VCC/GND from the multimeter). So why is only 2.2V going to each motor?

Please post the code, using code tags. If you are using PWM speed control, then the voltage measured by the multimeter will not be the full 7.8V.

What is the stall current for the motors? Post a link to the motor data sheet.

Fritzing diagrams are usually unclear or misleading and often useless, so please do not post them. Forum members appreciate instead hand drawn wiring diagrams, with parts, pins and connections clearly labeled.

1 Like
#include <DRV8833.h>
#include "ppm.h"

#define THROTTLE 3
#define ROLL 1
#define PITCH 2
#define YAW 4
#define SWITCH3WAY_1 5
#define BUTTON 6
#define SWITCH3WAY_2 7
#define POT 8

DRV8833 driverR = DRV8833();
DRV8833 driverL = DRV8833();
DRV8833 driverW = DRV8833();

const int inputA1 = 3, inputA2 = 4, inputB1 = 5, inputB2 = 6, inputC1 = 7, inputC2 = 8, inputD1 = 9, inputD2 = 10, inputE1 = 12, inputE2 = 2;
const int leftRightL_lowThresh = 1400;
const int leftRightL_min = 1000;
const int leftRightL_highThresh = 1550;
const int leftRightL_max = 2000;
const int upDownL_lowThresh = 1400;
const int upDownL_min = 1000;
const int upDownL_highThresh = 1550;
const int upDownL_max = 2000;
// The speed of the motors:
//const int motorSpeed = 255; // Half speed (255 / 2).
bool started = false;

void setup() {
  ppm.begin(A0, false);

  Serial.begin(2000000);

  // Wait for the serial port to connect. Needed for Leonardo.
  while (!Serial);
  driverL.attachMotorA(inputB1, inputB2);
  driverL.attachMotorB(inputA1, inputA2);
  driverR.attachMotorA(inputC1, inputC2);
  driverR.attachMotorB(inputD1, inputD2);
  driverW.attachMotorA(inputE1, inputE2);
  Serial.println("Ready!");
}

void loop() {

  short upDownL = ppm.read_channel(THROTTLE);
  short turn = ppm.read_channel(ROLL);
  short stickR = ppm.read_channel(PITCH);
  short leftRightL = ppm.read_channel(YAW);
  short switch3way_1 = ppm.read_channel(SWITCH3WAY_1);
  short button = ppm.read_channel(BUTTON);
  short switch3way_2 = ppm.read_channel(SWITCH3WAY_2);
  short pot = ppm.read_channel(POT);

  if (button >= 100) {
    started = true;
  }

  if (started and upDownL > upDownL_highThresh) {
    if (leftRightL > leftRightL_highThresh) {
      //move up right
      Serial.println("Move Up Right");
      driverL.motorAForward();
      driverL.motorBStop();
      driverR.motorAStop();
      driverR.motorBForward();
    } else if (leftRightL < leftRightL_lowThresh) {
      //move up left
      Serial.println("Move Up Left");
      driverL.motorAStop();
      driverL.motorBForward();
      driverR.motorAForward();
      driverR.motorBStop();
    } else {
      //move up
      Serial.println("Move Up");
      driverL.motorAForward();
      driverL.motorBForward();
      driverR.motorAForward();
      driverR.motorBForward();
    }
  } else if (started and upDownL < upDownL_lowThresh) {
    if (leftRightL > leftRightL_highThresh) {
      //move down right
      Serial.println("Move Down Right");
      driverL.motorAStop();
      driverL.motorBReverse();
      driverR.motorAReverse();
      driverR.motorBStop();
    } else if (leftRightL < leftRightL_lowThresh) {
      //move down left
      Serial.println("Move Down Left");
      driverL.motorAReverse();
      driverL.motorBStop();
      driverR.motorAStop();
      driverR.motorBReverse();
    } else {
      //move down
      Serial.println("Move Down");
      driverL.motorAReverse();
      driverL.motorBReverse();
      driverR.motorAReverse();
      driverR.motorBReverse();
    }
  } else if (started and leftRightL > leftRightL_highThresh) {
    //move right
    Serial.println("Move Right");
    driverL.motorAForward();
    driverL.motorBReverse();
    driverR.motorAReverse();
    driverR.motorBForward();
  } else if (started and leftRightL < leftRightL_lowThresh) {
    //move left
    Serial.println("Move Left");
    driverL.motorAReverse();
    driverL.motorBForward();
    driverR.motorAForward();
    driverR.motorBReverse();
  } else if (started and turn >= 1600) {
    //Turn ???1
    Serial.println("Turn ???1");
    driverR.motorAReverse();
    driverR.motorBReverse();
    driverL.motorAForward();
    driverL.motorBForward();
  } else if (started and turn <= 1350) {
    //Turn ???2
    Serial.println("Turn ???2");
    driverL.motorAReverse();
    driverL.motorBReverse();
    driverR.motorAForward();
    driverR.motorBForward();
  } else {
    //Stop
    //Serial.println("Stop");
    driverL.motorAStop();
    driverL.motorBStop();
    driverR.motorAStop();
    driverR.motorBStop();
  }

  if (switch3way_1 <= 1550) {
    driverW.motorAForward();
    //weapon
    Serial.println("weapon on");
  } else {
    driverW.motorAStop();
  }
}

Right now we are not using PWM. Just HIGH and LOW Digital Pins.

I am really not sure on the data for these motors. They came with this kit:

I gave up looking at your frizzy mess. Lines are not connected, no color code followed, unknown boards etc. You need to post an annotated schematic (the language of electronics) and links to technical information on each of the hardware devices. Links to Amazon and other market places give lots of neet sales information but very seldom enough to use the producte.

You can estimate the stall current by measuring the motor winding resistance, using your multimeter. Turn the motor shaft VERY slowly, and keep the lowest measurement you get. The stall current is the motor power supply voltage divided by the winding resistance in Ohms. Let us know what you find.

However, I think that the DRV8833 motor drivers should be able to handle those motors, suggesting that you have a wiring error.

As mentioned above, it is not really possible to decode that Fritzing with any confidence. Please post a pic of a hand drawn diagram that unambiguously shows all the connections, with all pins clearly labeled.

1 Like

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.