I connected a 12v motor to my Arduino Nano via an L298n. In1 is on d2 and in2 is on d3. The problem is nothing happens, the light on the l298n that indicates whether a signal is being sent flashes. As soon as I pull out in2 it only works in one direction. When only in2 is connected still nothin happens. The motor works and the parts work without problem
code:
#include <L298N.h>
const unsigned int IN1 = 2;
const unsigned int IN2 = 3;
L298N motor(IN1, IN2);
void setup() {
}
void loop() {
motor.forward();
delay(2000);
motor.backward();
delay(2000);
}
i hope that helps