Code: Make your PiBot work!


OK, so you've got your shiny new PiBot built - how do you make it work? We've compiled below some links to common control methods and some sample code to make your creation move around. If you're adventurous, why not hack together some different inputs on the Pi? Webcams, flashing lights, whatever. It's a proper computer, so take advantage of all the cool things it can do.

Currently working code:

  • Scratch project (Rev 1 board)
    You can grab the Scratch project to control PiBot for Scratch 1.4 from here.
    NOTE: You will need a GPIO enabled version of Scratch. The best one is available to download here.
  • Rev 1 board C code and test app
    We're not doing as much with the Rev 1 boards now (the board without the bump stops) but the original command line app for the Raspberry Pi and Source are on GitHub: Pibot on GitHub
  • Rev 2/3 board C code and test app
    This is the current board we are selling and using in Schools. This test code will compile on your Raspberry Pi and give you basic control and the ability to read the status of GPIO pin 15 which is the bump stop status. A compiled app is in the repo too. Pibot Rev 2 on GitHub
  • Rev 2/3 board Python code
    Download a simple command file from here. Run it with sudo python pybot.py on the command line.
  • Raw GPIO command set
    Rev 1
    Rev 2
Raspberry Fool has been lovingly handmade in England by Tom Stacey and Brendon Shaw.