Chapter 3

Software

Abstract

This chapter provides a comprehensive overview of the Microchip XC32 compiler and the process that takes a C program and turns it into an executable running on the PIC32. It begins by introducing the virtual memory map (used by the CPU) and its relationship to the physical memory map described in Chapter 2. Using a simple program as an example, this chapter explains how the C compiler finds the right Microchip header files to compile C code to object code, and how the linker finds the right Microchip object code to link with the user’s code to create an executable file. It makes clear how the user’s code, which reads from and writes to special function registers (SFRs), ends up controlling the PIC32’s peripherals. ...

Get Embedded Computing and Mechatronics with the PIC32 Microcontroller now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.