Arduino, and Mechanical Movement of Objects - a Newbie Question

That second picture is another project I am working on, sorry....

Did I mess up my drawing? lol

Idler gear A is always connected to driven gear, but in one direction, it just "idles" off to the side not touching anything. When you want to reverse direction, you pivot the idler gear into connection with the output gear C and the output gear will now rotate in the same direction as the driven gear.

Yep. I did mess up my drawing. The idler gear would would turn in the opposite direction of the driven gear, always. I just drew it wrong.

Here is a tutorial: http://www.societyofrobots.com/mechanics_gears.shtml#rotdirection

But the take away is that for each gear in a chain of gears, each one will move in the opposite direction of the one driving it. By introducing a gear in between the driven gear and output gear, the third one will move in the same direction as the first.