Trouble with H Bridge

I’m having a problem using an H-Bridge to control two motors. The short version is that the logic pins on the H-Bridge seem to be at a higher voltage before I connect them to the arduino. Current doesn't flow when I set their IO pins to HIGH. Current does flow when I set their IO pins to LOW, but presumably it is flowing into the IO pin and not out of it.

The long version is this: I set everything up on the breadboard and it worked as it was supposed to. That is, one of the motors was connected to outputs 1 and 2. When the pin connected to input 1 is set to HIGH, but the pin connected to input 2 is LOW, the motor would spin one way. Switching the charges changed the direction of the motor.

Then I transferred it to perf board, thinking that everything was identical, but when I turned it on none of the motors moved. With some programs I got movement, but not exactly as I expected. As I was fiddling with it, I unplugged the logic pins and tried applying positive voltage to them individually and nothing happened. Then I got my big surprise. I could make the motors move by connecting the logic pins to ground.

I don’t understand why this is. It must be that those pins are already at a higher voltage. Connecting to ground lets the current flow, but in the direction opposite of what I expected. I can control both motors in both directions, but I have to invert everything in my program. For example, before, the motors moved fastest when I set PWM close to 255. Now they move fastest when PWM is set close to 0.

I’m using the TI L293 H-Bridge, and I tried to look at the schematics for it, but I’m new to this and I don’t understand the transistors well enough to find the problem. I can just rearrange the program and live with it, but I’m worried that I might be damaging something. I don’t know if I’ve created some short circuit or reverse polarity that will cause problems.

Does this sound familiar to anyone?

Hi, a circuit diagram of your arrangement would help. Check and make sure your grounds are all connected, ground of arduino and ground of motor control chip if not the same that could cause your level problems. Tom

You don't need to worry about whether the inputs source or sink, they are logic inputs - just apply the right voltages to the input pins and 5V to VCC1 (logic supply).