Monday, November 12, 2012

Very simple way to control robot with smartphone

A very simple robot controlled from on-board Samsung Galaxy S2 (using my girlfriend's Galaxy Note as remote control. Todo: write some autonomous software using the phone's camera, sensors, etc)

The robot is controlled by drawing white rectangles on the smartphone screen, which activate photodiodes (I used red LEDs as photodiodes).

The robot is built entirely out of various trash and spare components I had:

Close-up on the wheel:

The blue thing on the motor shaft is insulation from some wire, used to increase grip. The wheel is two bottle caps and insulating tape, spinning freely on a thin wire used as a shaft. The weight of the robot presses the wheel and motor shaft together.

Circuit board:

Circuit diagram (I built 2 of this):

Circuit notes: I used red LED as a photodiode, BC337 for t1 and t2, and IRFZ44N for the mosfet, because that's what I had laying around. I've built 2 controllers for both wheels. If you are buying components for that project, I heavily recommend making some different circuit and using a motor controller IC that would allow you to reverse the motor. You can use the D1, T1, T2, R1 combination with pretty much anything. Also, you may want to connect the lower leg of the photodiode D1 to +9 rather than the emitter of T1 (reverse bias the diode) . IRFZ44N is an enormous overkill for these puny motors - it could switch 50 amps of current, at 55 volts.


  1. Hello ! Really nice and simple circuit, thank you for publishing this ! I use 2 2N3904 transistors, a 300k resistor and a 5mm red led (the ones with red coloured casing works better than red light with crystal clear casing). All this for 11 cents at TAYDA electronics... The reverse biased diode do no work, but as in your schematic, it works very well (1volt - 5 volts swings with 9V power supply). I will use it for a disk tachometer with black and white stripes (aluminium foil do not reflect the light from the red led). Do you have any idea of the max switching frequency ?

  2. It was wondering if I could use this write-up on my other website, I will link it back to your website though.Great Thanks.