Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

L297 + L298 circuit not working

Status
Not open for further replies.

jatindecoded

Newbie level 4
Newbie level 4
Joined
May 4, 2013
Messages
7
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Visit site
Activity points
1,343
I have paired up L297 and L298 together to make a bipolar stepper driver. My schematics are :

schematics

I have hooked up the step and direction pin number 4 and 5 respectively on Arduino. I am using a 5V power supply from a DC adaptor

The code I'm using is(sorry for bad indentation) :

Code:
#define stepPin 4
    #define dirPin 5

     void setup() {
     Serial.begin(9600);
        Serial.println("Starting stepper exerciser.");

         pinMode(stepPin, OUTPUT);
          pinMode(dirPin, OUTPUT);

            digitalWrite(dirPin, HIGH);
                    digitalWrite(stepPin, LOW);
                          }

               void loop() {
               int i, j;

                      for (i=1000; i>=200; i-=100) {
Serial.print("Speed: ");
Serial.println(i);

for (j=0; j<2000; j++) {
  digitalWrite(stepPin, HIGH);
  delayMicroseconds(i);
  digitalWrite(stepPin, LOW);
  delayMicroseconds(i);
}

delay(500);
digitalWrite(dirPin, !digitalRead(dirPin));

for (j=0; j<2000; j++) {
  digitalWrite(stepPin, HIGH);
  delayMicroseconds(i);
  digitalWrite(stepPin, LOW);
  delayMicroseconds(i);
}

delay(1000);
Serial.println("Switching directions."); 
digitalWrite(dirPin, !digitalRead(dirPin));
       }
         }


I am using NEMA17 bipolar 5V motors , the data sheet can be found here : datasheet

Motor specs are here

I have also tried L297 with L293d , but the things aren't working the way they should.
 
Last edited by a moderator:

In order to be able to help you have to provide:

  • The actual schematic you have user rather than the one from the datasheet
  • Describe what exactly is the problem/behaviour of the motor
  • The exact type of the motor with current specs
  • The specs of your power supply
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top