Python Library

Cellbots started as a single Python file, but has grown into a significant libray to support multiple communication methods and a variety of robot platforms. The use of Python on Android is possible thanks to the Scripting Layer 4 Android, an open source project that allows scripting languages such as Python, Lua, PHP, Perl, and others to work on your phone. While this doesn’t support rich UI’s like Android primary Java language does, you can whip up some new code quickly and experiment with robotics.

With the Cellbots Python library, you can run your phone as a remote control or as the robot’s onboard brain. Commands can be sent via Google Talk as chat messages (XMPP), through Telnet, voice recognition, over HTTP using the local network. The primary way for the phone to talk to the robot is using Bluetooth on any Android 2.0 and up phone, but methods for modding the phone to accept serial input can also be used.

The Python codebase currently supports talking to Arduino robots like Truckbot and Tankbot, the VEX Pro, and iRobot Create & Roomba. We’re working to add support for LEGO MINDSTORMS and you should be able to add your own by working from the source code. We’ve currently scoped the project for two-wheel differential drive robots and look forward to ideas on extending that to more complex types in the future.

To get started, install the Scripting Layer 4 Android on your phone. Then check out the Python source code and copy it to the phone at /sdcard/sl4a/scripts/cellbot/ and edit the config files to your liking. Then pair with your phone and launch to get started as a remote control or direct drive of the robot.

Whether you have one or two Android phones, we’re sure you’ll find new and clever ways to script up clever robot hacks in just a couple lines of Python!

6 Responses to Python Library

  1. Pingback: Googlers Give Cellbots a Major Upgrade |

  2. Pingback: Android stretches its legs… errr wheels… with help from 20% time at Google |

  3. Pingback: Googles 20% time brings robotic app to Android | sUAS News

  4. Derek Harrington says:

    Where is the Python source code? and what format do I put it in to copy it to my android phone?

  5. George says:

    Where is the Python source code?

  6. srirag says:

    Where is the python source code sir.

Leave a Reply

Your email address will not be published. Required fields are marked *


You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>