Hi all, I'm struggling to use the output of my IR sensors(2 sensors) to control 2 motors.I am using 2 Sharp IR GP2Y0D340K Distance sensor , a Ardumoto to power the motors and a Arduino Uno. When I connect power to the Arduino the motors turn as expected , but only keep turning in one direction. I want the motors to change direction when the IR sensor detects an object, but they do not respond to the sensors. In my code I have assigned the sensors readings( 1 or 0 ) to be sent to the serial monitor just so that I can see if they are working, and they are. Can someone please take a look at my code and why the motors do not respond. Thanks in advance.