PIC32 Example: HelloWorld

From Mech
Revision as of 16:12, 10 July 2009 by Andrew Long (talk | contribs)
Jump to navigationJump to search

Download HelloWorld.zip.

Follow Directions for Starting New MPLAB Project.

Program to Blink LED on UBW32. Rate changes when holding USER switch button.

First include header files. GenericTypeDefs.h and Compiler.h are located in Microchip Framework and need to have search paths in MPLAB. HardwareProfile.h has global constants for the PIC board.

  #include "GenericTypeDefs.h"
  #include "Compiler.h"
  #include "HardwareProfile.h"