Getting Started with PIC32

From Mech
(Difference between revisions)
Jump to: navigation, search
(First Program)

Revision as of 10:23, 18 November 2009

Follow these steps to get started with PIC32.


MPLAB is the software used for editing, compiling, debugging code. This software creates the HEX files to download to the PIC.

Download and Install Microchip MPLAB (Microchip's free IDE for editing, debugging and compiling code)

Download and Install Microchip C32 Compiler (the academic version is free)

Download and UnzipMicrochip Applications Library located at bottom of page. I put this folder in C:/Program Files/Microchip. This zip file contains common source code and header files.

  • Source and header files from the framework need to be added to the project if using USB communication


An advantage of the PIC32 is that a bootloader can be installed. This means you do not need a programmer to put new programs on the PIC. The UBW32 comes preloaded with a bootloader, but the NU32 board does not.

The HID bootloader is used to put HEX files on the PIC32. The HID bootloader should be included in the Applications Library downloaded above. It will be located under the start menu Programs -> Microchip -> MCHPFSUSB v2.5 -> Tools -> HIDBootLoader

NOTE: occassionally, the bootloader will get stuck verifying that the program is running. (There must be a bug in the bootloader application code) It will take 90-100% of CPU. End task manually with the task manager if this happens.

See Programming HID Bootloader on PIC32 for directions on how to install a bootloader on your PIC.

First Program

You can test your bootloader by programming this HelloWorld hex file on to PIC using the directions to load programs with HID Bootloader.

The directions here detail how to code and program Hello World on to the PIC32 using the HID Bootloader.

Personal tools