IrReceiver.begin mess up L293D motor shield

Hi, I just started messing around with Arduino and I'm stuck here
I'm trying to control some DC motors with an IR remote. However, when I try to do it, only the M3 and M4 motors actually work as intended. When I comment the IrReceiver.begin line, the other motors came to life again. I'm running two 18650 batteries as external power, are they not enough?

I'm going to assume that you're using an Uno R3.

Because you didn't say.

I'm going to assume that you're using one of those cheap motor shields that's a clone of the discontinued more than a decade ago product by Adafruit .

Because you didn't say.

I'm going to assume that you're using the AFMotor library.

Because you didn't say.

Are all those assumptions correct? If so, throw out the motor shield, uninstall the AFMotor library, and buy a motor shield that doesn't use all the timers on an R3 (and won't work at all on pretty much anything but an R3), thereby making it difficult, if not impossible, to use anything else that might like to use a timer. Like the IRremote library, for example. Something like

And I strongly suggest that you take some time and read How to get the best out of this forum so that you provide all the relevant information when asking a question.

2 Likes

RTFM GitHub - Arduino-IRremote/Arduino-IRremote: Infrared remote library for Arduino: send and receive infrared signals with multiple protocols

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.