I am new to the arduino, and circuits. I am trying to build an inverted pendulum stabilizer out of an old printer. for the most part things have gone off without a hitch. I have gotten each of the necessary components working seperately. However, when I bring everything together I am noticing some contamination in my sensors due to a changes in motor direction/speed. Eventually I am planning on using my sensors to control the motor, but for now I have the motor interfaced with a switch and a pot. When I mess around with the motor it messes up the output of an encoder wheel I have in the circuit. I have tried a standard decoupling fix( adding capacitor after the motor supply), and it improved things greatly, but I still am having some problems. After a while of being powered on the encoder wheel readout messes up again. I'll post some pictures soon.
You might have to add some inductors (chokes) to beef up the decoupling protection. See:- http://www.thebox.myzen.co.uk/Tutorial/De-coupling.html
How exactly should the inductor be placed in the circuit. I tried using an inductor and it made things worse. I'm sure I must be placing it wrong. I basically have one side of a solderless breadboard charged with 12 V for the motor supply. I first put a 10microF capacitor from 12 to ground and then I place the inductor in series with the motor supply voltage pin on the h-bridge. I'm not sure the value of inductance. All of these components where taken from the original printer IC.