4 Channels DC Servo Stepper Motor Driver Module for Arduino

I've bought this driver : Chihai Motor 3162 DC Motor Holzer Encoding 24V 8000rpm High Torque - Free shipping - DealExtreme


I can't find how to do the wiring. I've tried but even though there's almost 11v going in, only 0,2v go out. I'm using that A1 A2 output...,pins 11,3 and 4 are connected to ENA,A1 and A2...also a GND to a GND on the arduino sensor shield

What do you want to control with it?

There is almost no information on that website you linked to. I guess the board contains four h-bridges - perhaps using a pair of L298 chips. I can't see the writing on the chips.

...R

I'm trying to control a dc motor...it works fine with one 3.7v battery. The site doesn't say muc and I couldn't find anything on google =/ I just need to increase de voltage at the output...maybe I could use another battery between the motor driver's output and the dc motor. Can I do this?

Can you see the writing on the Chips on the board - what does it say?
The L298 chips have a significant voltage drop so a higher voltage battery may be necessary.

You should post the code you are using in case that's where the problem is.

...R

Looks like two L298's - at least all the I/O is labelled - has a splitter for 4 servos
and 5V and 3.3V out.

I think you'll need to provide a minimum of 5V for the motor supply - 3.7V won't be enough
(you'd get almost nothing out too, the output stages can lose upto 2.5V due to it using
darlington output stages)

I have more than 10V for motor supply... The multimeter shows 10v going in and only 0.2v going out

partisfal:
The multimeter shows 10v going in and only 0.2v going out

And you are still not showing your code ...

...R

#include <VirtualWire.h>
//motor
const int IAE = 9;
const int IBE = 10;
const int IAD = 6;
const int IBD = 5;

//canhao
const int CA = 11;
const int CB = 4;

void setup()
{

  vw_set_ptt_inverted(true); // Required for DR3100
  vw_set_rx_pin(12);
  vw_setup(4000);  // Bits per sec
  pinMode(CA, OUTPUT);

  pinMode(CB, OUTPUT);

  //pinMode(laser, OUTPUT);

  pinMode(IAD, OUTPUT);

  pinMode(IAE, OUTPUT);

  pinMode(IBE, OUTPUT);

  pinMode(IBD, OUTPUT);

  Serial.begin(9600);
  digitalWrite(IBD, LOW);

  digitalWrite(IAE, LOW);

  digitalWrite(IAD, LOW);

  digitalWrite(IBE, LOW);
  vw_rx_start();       // Start the receiver PLL running

}


void loop() {

  uint8_t buf[VW_MAX_MESSAGE_LEN];
  uint8_t buflen = VW_MAX_MESSAGE_LEN;

  if (vw_get_message(buf, &buflen)) // Non-blocking
  {

    if (buf[0] == '0') {
      freio();
    }

    if (buf[0] == '4') {
      frente();
    }

    if (buf[0] == '2') {
      virae();
    }

    if (buf[0] == '1') {
      vira();
    }
    if (buf[0] == '3') {
      re();
    }
    if (buf[0] == '5') {
      dispara(); //branco motor e laranja placa -
    }
    if (buf[0] == '6') {
      disparaoff();
    }
  }
}

long freio() {
  digitalWrite(IBD, LOW);

  digitalWrite(IAE, LOW);

  digitalWrite(IAD, LOW);

  digitalWrite(IBE, LOW);
}

void re() {
  digitalWrite(IBD, LOW);

  digitalWrite(IAE, LOW);

  digitalWrite(IAD, HIGH);

  digitalWrite(IBE, HIGH);
}

void frente() {
  analogWrite(IBD, 243);

  digitalWrite(IAE, HIGH);

  digitalWrite(IAD, LOW);

  digitalWrite(IBE, LOW);
}

void virae() {
  digitalWrite(IBD, HIGH);

  digitalWrite(IAE, LOW);

  digitalWrite(IAD, LOW);

  digitalWrite(IBE, HIGH);


}
void vira() {
  digitalWrite(IBD, LOW);

  digitalWrite(IAE, HIGH);

  digitalWrite(IAD, HIGH);

  digitalWrite(IBE, LOW);

}


void dispara() {
  digitalWrite(CA, HIGH);
  digitalWrite(CB, LOW);
}

void disparaoff() {
  digitalWrite(CA, LOW);
  digitalWrite(CB, LOW);
}

If your problem is how to make the driver module drive the motor I suggest you write the shortest possible program that does that and nothing else.
No messages to be received and no buff[0] to be figured out.
Maybe just put the code from one of your motor functions into setup() and leave loop() empty.

Having said that I don't see anything obviously wrong with your code, but I am not familiar with your driver module.

Also, you have not told us what is written on the chips - you should get the datasheet for whatever chip it is and study it carefully - and provide a link to the datasheet here.

For my own convenience this is the link to the driver module that you have in your original post

...R

the big chip has "78M05 K026" written on it and the smallest "AMS1117 3.3HT246G"

here's the datasheet : datasheet

partisfal:
the big chip has "78M05 K026" written on it and the smallest "AMS1117 3.3HT246G"

here's the datasheet : datasheet

Those are a 5V and 3.3V linear regulator respectively.

You need to enable the enable pins with an L298 before anything happens, so be sure to
drive those as will as the other inputs. For example drive ENA HIGH, then drive A1 HIGH and A2
LOW, and you should see a motor connected to the A connector run. Switchover A1 and A2 for
the other direction.

partisfal:
the big chip has "78M05 K026" written on it and the smallest "AMS1117 3.3HT246G"

Is one of those the number on the two big chips standing up in the middle of the circuit board - I doubt it?
Perhaps you can post a photo of the writing on them.

That "datasheet" you linked to is a spreadsheet. I have never seen datasheets in spreadsheet format before. They are usually PDF files. I am reluctant to open a spreadsheet.

...R

So... Just to close the post. I forgot to enable the enables pins... So that was my mistake -.- thanks for the help guys :slight_smile:

Its a dual L298 shield I'm pretty certain - go read the L298 datasheet about
the enable and direction inputs so you understand how to work its signals.

Often such shields have a jumper that configures whether the logic supply
for the L298's comes from the Arduino 5V or is derived from the motor supply
locally. If you don't have the motor supply attached and are deriving L298 logic
supply from the Arduino it will overload the chip by trying to power the motor
directly from the Arduino 5V - so make sure you don't try and drive the motor
with its supply disconnected.