Categories

Compile the Bus Pirate firmware

Posted on Tuesday, September 8th, 2009 in Bus Pirate, Development by Ian

mplab

This is an old version, see the latest version on the documentation wiki.

You don’t need a Microchip programmer to develop firmware for the Bus Pirate. You can use Microchip’s free development tools and upload code through the USB bootloader. It’s a mini PIC 24F development board!

First, download and install Microchip’s IDE called MPLAB, and the free demonstration C30 compiler. Next, download a Bus Pirate source code archive, or get the latest development version from SVN with a program like TortoiseSVN.

Open the Bus Pirate project in MPLAB.

Uncomment the correct Bus Pirate hardware version and language in base.h. Compile the project. You may need to modify the compiler location when prompted, but MPLAB is getting better about making these changes automatically.

The compiled firmware must be exported in order to work with the bootloader. In MPLAB, go to File->Export… Make sure that the Program Memory and Configuration Bits boxes are checked. Make sure INHX32 (Intel 32bit HEX) is selected on the File Format tab. Click OK to export the firmware.

Bootload the firmware following your normal upgrade process (Linux, OSX).

After the break, learn how to use TortoiseSVN to check out the Bus Pirate source on Windows.

If you have Tortoise SVN on Windows:

  1. Right click->SVN checkout on your desktop or Windows file explorer.
  2. Enter the SVN address (http://the-bus-pirate.googlecode.com/svn) and a directory to use. Choose anonymous check out.
  3. If you have commit permissions (you’ve been added as a developer on the Bus Pirate project), then use the secure SVN address (https://the-bus-pirate.googlecode.com/svn). Give Tortoise your email address when prompted, your Google SVN password is different than your account passwordget your Google SVN password here.
  4. TortoiseSVN will download the source.
  5. The developers work in the TRUNK folder. If you’re contributing to the project, make your changes, then right click on the modified file and choose SVN commit. If you added new files, first use SVN add, then use SVN commit.
This entry was posted on Tuesday, September 8th, 2009 at 7:28 am and is filed under Bus Pirate, Development. You can follow any responses to this entry through the RSS 2.0 feed. You can skip to the end and leave a response. Pinging is currently not allowed.

Leave a Reply

Notify me of followup comments via e-mail. You can also subscribe without commenting.

Recent Comments

  • Joe Desbonnet: Ya, I can recommend the low melting point solder. I used brand 'ChipQuik' and it's amazingly easy to use.
  • Jerome: I need a new BusPirate for the Fablab ;) Many thanks!
  • Max: Seems like an unexpectedly violent way to remove the chip indeed. A hot air station should of course do the job just fine, but in...
  • jose: Part removal described here is pure butchery, the cheapest hot air station will do a fast and clean job removing the QFP, heat air to...
  • Cody: Yes please