Microchip MPLAB Files

From Mech
Jump to: navigation, search

When you installed the MPLAB IDE, the directory C:\Program Files\Microchip was created. It has a lot of stuff in it, some of it redundant. This page is to give you an idea of the directory structure, and to help you understand what code gets included when you specify your PIC32 type, and when you include plib.h, for example.

Not all files are mentioned here, just ones that help you figure out what's going on. In the directory C:\Program Files\Microchip, there are a few subdirectories, such as Docs, MPLAB C32, MPLAB C32 Suite, and MPLAB IDE. The contents of MPLAB C32 and MPLAB C32 Suite look very similar. Below we explore the MPLAB IDE and MPLAB C32 directories, highlighting only the directories and files that are of particular interest.


MPLAB IDE

  • Device
    • PIC32MX795F512L.dev (defines memory locations of the peripheral SFRs)


MPLAB C32

  • doc
    • Microchip-PIC32MX-Peripheral-Library.chm
    • MPLAB C32 Libraries.pdf
    • MPLAB C32 User Guide.pdf
  • examples
    • plib_examples (lots of directories containing sample code using the peripherals; below are some examples)
      • adc10
      • timer
  • lib (contains various compiled libraries with .a extensions, and .h header files; none we need to worry about)
  • pic32-libs
    • dsp
      • wrapper
        • various .c files that call mips_XXX DSP functions
    • include
      • math.h (math function prototypes)
      • p32xxxx.h (uses the processor you chose when you created the project to include the right p32mx... file; see below. also does some other minor things.)
      • peripheral
        • adc10.h
        • lots of other peripheral library header files
      • plib.h (includes all the peripheral library headers)
      • proc
        • p32mx795f512l.h (huge file defining SFR names and constants for virtual memory addresses for the particular PIC)
        • ppic32mx.h (some more constant definitions, generic to all PIC32's, included by the file above)
    • peripheral
      • C source code for the peripheral library, one directory per peripheral
  • pic32mx
    • include (looks the same as the include directory above)
    • lib (contains compiled libraries with .a extensions)
      • mips16
        • .a libraries for DSP functions for different PIC32's
      • proc
        • 32MX795F512L
          • procdefs.ld (some virtual memory addresses for the linker for our PIC32)
Personal tools