problem with motor shield: DC motor refuses to work

Hi, I have got a motor shield mounted on a Mega. I have used it before, and now suddenly a DC motor refuses to turn. It seems that a pin stopped working... Do I have to change the shield? The code's got no problems, it worked before.

I don't see any problems.

The problem is that a pin does not give energy to the DC motor...

Hi, What pin? What motor drive shield? How do you know the pin is not working?

Thanks.. Tom... :)

This is the motor shield. I tested the DC motor with a 9v battery (those DC motors need between 6 and 9 volts) and it works. I took a tester and it says no energy flows through the motor port (the blue thing... I am Italian so I do not know how to call it). The power is given by a 9v battery, I even tried connecting it to a wall socket. The motor shield is mounted on a Mega.

Okay, the OPs motor shield;
How many motors are you running?
If you have spare motor terminals, have you tried changing your code to use another part of the shield?

Can you post your code please?

Thanks… Tom… :slight_smile:

I am running four DC motors. This is the code:

#include <AFMotor.h>

AF_DCMotor motor1(1);
AF_DCMotor motor2(2);
AF_DCMotor motor3(3);
AF_DCMotor motor4(4);

void setup() {
    //delay(1840); girare
    //delay(1250); 30cm
    //delay(1840); girare
    //delay(1250); 30cm
    delay(3750); //120cm;;;;

void loop() {

I cannot use more than 4 DC motors, so I do not have free pins.

9V block batteries are totally unsuitable for powering motors. You will need a motor power supply capable of providing sufficient current. Check the motor data sheet for the current required. Key words: "stall current".

That is not the problem. No energy flows to the pin. If I make only that pin to work, no energy gets there. Tested with a tester.

Hi, So you only have one of the four motors not working, and you have tested the motor. You may have damaged one motor driver chip, if they are plug in chips then you can replace them with new ones.

What are the motor specs and what are you using to power the motors?

If you can swap motors around and the same terminal does not work, you may have an IC failure.

Tom... :)

Yes, I have an IC failure. Thank you, I will search for the plug in chips.

Swap the two outside chips (LM293D), and see if the other motor now stops working.

Then the next question you should ask yourself is why did this chip go bad? Are your motors drawing more current than the shield can handle, especially when stalled?

The shield has a 9 volt pin, where I have to connect the battery. The DC motors need 6 volts. They are compatible with the shield...