Stepper for project not working right.

Hello everyone. I need some help because i´am getting some weird behaviour from this stepper . I´am using the exactly same configuration used in here for the bipolar stepper. I´am using the next code for testing goals:

#include <Stepper.h>
#define STEPS 200
Stepper stepper(STEPS, 8, 9, 10, 11);
void setup()

void loop()

So the motor has to do a full rotation forwards, wait 2 seconds and a full rotation backwards, then wait 2 seconds and start again. After I upload the code and give power to both stepper and arduino, the stepper behaves correctly doing the rotations nicely, but as time passes, about 10 seconds, the stepper starts to move slower and slower until it just doesnt move anymore, but the coils in the inside still seem to be doing something because you can still hear them, but the shaft doesnt move at all. What could be the problem?

I´am just doing 1 thing differently from the setup from the arduino Learning section. And it is that I was not sure how to connect the 4 wires to the Hbridge, so I just connected 2 wires from 1 phase to pins 14 and 11, from the hbridge, and the other 2 wires to pins 3 and 6. The other thing that may be affecting the correct funcionality is that i´am giving the motor 9V instead of the 12V that it "needs". If I turn off the arduino for a couple of minutes and turn it on again the motor behaves exactly as previously stated, doing nice rotations for some time and then starts again to move slower, until no movement.

Something that bugs me is that I also got this behaviour from a Floppy stepper a while ago but never discovered what was the problem.

Thank you very much in advance.