DC Motor with motor shield is too weak
![userHead](https://dfimg.dfrobot.com/dfPortrait2.png)
Hi,
I'm trying to control a DC motor with a motor shield but it has too little power.
My setup is:
ESP32 Board (FireBeetle): https://www.dfrobot.com/product-1590.html
Motor Shield (Compatible with FireBeetle): https://www.dfrobot.com/product-1666.html
DC Motor: 3-6V DC Motor with a gear ratio 1:90, max 110 RPM.
The ESP32 board is supplied with USB power for operation. The shield is powered by an external power supply with adjustable voltage and current (for testing purposes), which is fed with 4V and limited to 1A. However, the shield only draws a maximum of 400mA when the motor shaft is held.
The code I'm using is very simple. It uses two limit switches (D6 and D7) to rotate the motor until one of the switches is pressed. If so, the motor drives in the other direction.
#include "Arduino.h"
#include "Wire.h"
#include “DFRobot_MotorStepper.h”
const int DOOR_END_OPEN = D7;
const int DOOR_END_CLOSED = D6;
const int PRESSED = LOW;
const int DEPRESSED = HIGH;
DFRobot_Motor motor1(M1, A0);
void setup() {
Wire.begin();
motor1.init();
pinMode(DOOR_END_OPEN, INPUT);
pinMode(DOOR_END_CLOSED, INPUT);
}
void loop() {
delay(1000);
actionDoor(CW, DOOR_END_CLOSED);
delay(1000);
actionDoor(CCW, DOOR_END_OPEN);
}
bool isDepressed(int pin)
{
return digitalRead(pin) == DEPRESSED;
}
void loopUntilPressed(int pin)
{
while (isDepressed(pin)) {
delay(1);
}
}
void actionDoor(int directionValue, int endPin, int motorSpeed = 4096)
{
if (isDepressed(endPin))
{
motor1.speed(motorSpeed);
motor1.start(directionValue);
loopUntilPressed(endPin);
motor1.stop();
}
}
What could be the reason that the motor + motor shield is not drawing more current and thus be more powerful?
Hi
Sorry for the unpleasant experience.
DC Motor & Stepper Driver - FireBeetle Covers(SKU:DFR0508) is a very Compact shield, which makes it quite difficult to dissipate the heat caused by high power consumption. That's the reason why it can not output more power.
Thank you very much for your advice, and we will continuously improve our product.
![userHeadPic](https://dfimg.dfrobot.com/dfPortrait2.png)