Wednesday, September 29, 2010

Lemons v1.3, now Bluetooth enabled and with a horn!

I decided to bump up the version number by 0.2. 0.1 for adding remote control via Bluetooth, and 0.1 for having a kick ass horn! I added a Bluetooth serial modem to Lemons that can be purchased at SparkFun. Getting it to pair with my laptop was no problem, and I was quickly able to add code to Lemons that can listen for commands via serial. This resulted in a simple but fun start to remote control where I would type a key like 'w', and Lemons would move forward for one second. My goal was to have something more responsive however, and I wanted to have it on my Droid. So, I wrote my first Android application. I found this link to be quite helpful in setting Bluetooth up on the Android side. I wanted to have a touch screen interface that reminded me of the old remote controls I used to use for my RC cars when I was a kid. My plan was to simulate those vertical and horizontal joysticks using sliding seekbars, one horizontal and one vertical. Unfortunately, the Android SDK does not come with a vertical seekbar, but I found one on Google Groups that worked nicely. I also added buttons to toggle the lights on and off and to beep the newly added piezo buzzer I mounted towards the front of Lemons. My next step is to add a camera to Lemons and have the video feed back to my Droid.


  1. Nice to see your great job here! I am very impressed about this. Could you share your experience about this project? How you could connect Android with the audrino by bluetooth? Do you use the Amarino or you use another methods (eg. python). Nice to hear these from you! Thanks!

  2. Thanks for the kind comment po! I explained how I did it (on a very high level) on this blog post. I decided to write my own Android app and did not use Amarino. This URL was quite helpful in setting up a bluetooth connection in Android code: . My Android app links to my bluetooth serial modem, then I simply send command data via serial. The Arduino code will decipher the commands sent via serial and translate them to perform the proper actions on the robot. If you want more info or code, you are welcome to send me a message through my youtube account: mothball187.