Book description
*Just months after the introduction of the new generation of 32-bit PIC microcontrollers, a Microchip insider and acclaimed author takes you by hand at the exploration of the PIC32*Includes handy checklists to help readers perform the most common programming and debugging tasksThe new 32-bit microcontrollers bring the promise of more speed and more performance while offering an unprecedented level of compatibility with existing 8 and 16-bit PIC microcontrollers. In sixteen engaging chapters, using a parallel track to his previous title dedicated to 16-bit programming, the author puts all these claims to test while offering a gradual introduction to the development and debugging of embedded control applications in C. Author Lucio Di Jasio, a PIC and embedded control expert, offers unique insight into the new 32-bit architecture while developing a number of projects of growing complexity.
Experienced PIC users and newcomers to the field alike will benefit from the text’s many thorough examples which demonstrate how to nimbly side-step common obstacles, solve real-world design problems efficiently and optimize code using the new PIC32 features and peripheral set. You will learn about:*basic timing and I/O operation*debugging methods with the MPLAB SIM *simulator and ICD tools*multitasking using the PIC32 interrupts*all the new hardware peripherals*how to control LCD displays*experimenting with the Explorer16 board and *the PIC32 Starter Kit*accessing mass-storage media*generating audio and video signals *and more!TABLE OF CONTENTSDay 1 And the adventure beginsDay 2 Walking in circlesDay 3 Message in a BottleDay 4 NUMB3RSDay 5 InterruptsDay 6 Memory Part 2 ExperimentingDay 7 RunningDay 8 Communication Day 9 LinksDay 10 Glass = BlissDay 11 It’s an analog worldPart 3 ExpansionDay 12 Capturing User InputsDay 13 UTubeDay 14 Mass StorageDay 15 File I/ODay 16 Musica Maestro!
- 32-bit microcontrollers are becoming the technology of choice for high performance embedded control applications including portable media players, cell phones, and GPS receivers.
- Learn to use the C programming language for advanced embedded control designs and/or learn to migrate your applications from previous 8 and 16-bit architectures.
Table of contents
- Cover
- Title Page
- Copyright
- Dedication
- Acknowledgments
- Introduction
- Table of Contents
-
Part I: Exploring
-
Day 1: The Adventure Begins
- The Plan
- Preparation
- The Adventure Begins
- Compiling and Linking
- The Linker Script
- Building the First Project
- Using the Simulator
- Finding a Direction
- The JTAG Port
- Testing PORTB
- Mission Debriefing
- Notes for the Assembly Experts
- Notes for the PIC MCU Experts
- Notes for the C Experts
- Tips & Tricks
- Exercises
- Books
- Links
-
Day 2: Walking in Circles
- The Plan
- Preparation
- The Exploration
- While Loops
- An Animated Simulation
- Using the Logic Analyzer
- Debriefing
- Notes for the Assembly Experts
- Notes for the 8-Bit PIC Microcontroller Experts
- Notes for the 16-Bit PIC Microcontroller Experts
- Notes for the C Experts
- Notes for the MIPS Experts
- Tips & Tricks
- Notes on Using the Peripheral Libraries
- Exercises
- Books
- Links
-
Day 3: Message in a Bottle
- The Plan
- Preparation
- The Exploration
- Do Loops
- Variable Declarations
- for Loops
- More Loop Examples
- Arrays
- Sending a Message
- Testing with the Logic Analyzer
- Testing with the Explorer 16 Demonstration Board
- Testing with the PIC32 Starter Kit
- Debriefing
- Notes for the Assembly Experts
- Notes for the PIC Microcontroller Experts
- Notes for the C Experts
- Tips & Tricks
- Exercises
- Books
- Links
-
Day 4: NUMB3RS
- The Plan
- Preparation
- The Exploration
- On Optimizations (or Lack Thereof)
- Testing
- Going long long
- Integer Divisions
- Floating Point
- Measuring Performance
- Debriefing
- Notes for the Assembly Experts
- Notes for the 8-Bit PIC® Microcontroller Experts
- Notes for the 16-Bit PIC and dsPIC® Microcontroller Experts
- Tips & Tricks
- Exercises
- Books
- Links
- Day 5: Interrupts
-
Day 6: Memory
- The Plan
- Preparation
- The Exploration
- Memory Space Allocation
- Looking at the Map
- Pointers
- The Heap
- The PIC32MX Bus
- PIC32MX Memory Mapping
- The Embedded-Control Memory Map
- Debriefing
- Notes for the C Experts
- Notes for the Assembly Experts
- Notes for the PIC Microcontroller Experts
- Tips & Tricks
- Exercises
- Books
- Links
-
Day 1: The Adventure Begins
-
Part II: Experimenting
-
Day 7: Running
- The Plan
- Preparation
- The Exploration
- Performance vs. Power Consumption
- The Primary Oscillator Clock Chain
- The Peripheral Bus Clock
- Initial Device Configuration
- Setting Configuration Bits in Code
- Heavy Stuff
- Ready, Set, Go!
- Fine-Tuning the PIC32: Configuring Flash Wait States
- Fine-Tuning the PIC32: Enabling the Instruction and Data Cache
- Fine-Tuning the PIC32: Enabling the Instruction Pre-Fetch
- Fine-Tuning the PIC32: Final Notes
- Debriefing
- Notes for the Assembly Experts
- Notes for the PlC® Microcontroller Experts
- Tips & Tricks
- Exercises
- Books
- Links
-
Day 8: Communication
- The Plan
- Preparation
- The Exploration
- Synchronous Serial Interfaces
- Asynchronous Serial Interfaces
- Parallel Interfaces
- Synchronous Communication Using the SPI Modules
- Testing the Read Status Register Command
- Writing Data to the EEPROM
- Reading the Memory Contents
- A 32-Bit Serial EEPROM Library
- Testing the New SEE Library
- Debriefing
- Notes for the C Experts
- Notes for the Explorer 16 Experts
- Notes for the PIC24 Experts
- Tips & Tricks
- Exercises
- Books
- Links
-
Day 9: Asynchronous Communication
- The Plan
- Preparation
- The Exploration
- UART Configuration
- Sending and Receiving Data
- Testing the Serial Communication Routines
- Building a Simple Console Library
- Testing a VT100 Terminal
- The Serial Port as a Debugging Tool
- The Matrix Project
- Debriefing
- Notes for the C Experts
- Notes for the PIC® Microcontroller Experts
- Tips & Tricks
- Exercises
- Books
- Links
-
Day 10: Glass = Bliss
- The Plan
- Preparation
- The Exploration
- HD44780 Controller Compatibility
- The Parallel Master Port
- Configuring the PMP for LCD Module Control
- A Small Library of Functions to Access an LCD Display
- Building an LCD Library and Using the PMP Library
- THE EXPLORER.C LIBRARY
- Creating the include and lib Directories
- Advanced LCD Control
- Progress Bar Project
- Debriefing
- Notes for the PIC24 Experts
- Tips & Tricks
- Exercises
- Books
- Links
- Day 11: It’s an Analog World
-
Day 7: Running
-
Part III: Expansion
-
Day 12: Capturing User Inputs
- The Plan
- Preparation
- Buttons and Mechanical Switches
- Button Input Packing
- Button Inputs Debouncing
- Rotary Encoders
- Interrupt-Driven Rotary Encoder Input
- Keyboards
- PS/2 Physical Interface
- The PS/2 Communication Protocol
- Interfacing the PIC32 to the PS/2
- Input Capture
- Testing Using a Stimulus Scripts
- The Simulator Profiler
- Change Notification
- Evaluating Cost
- I/O Polling
- Testing the I/O Polling Method
- Cost and Efficiency Considerations
- Keyboard Buffering
- Key Code Decoding
- Debriefing
- Notes for the PIC24 Experts
- Tips & Tricks
- Exercises
- Books
- Links
-
Day 13: UTube
- The Plan
- Preparation
- The Exploration
- Generating the Composite Video Signal
- The Output Compare Modules
- Image Buffers
- Serialization, DMA, and Synchronization
- Completing a Video Library
- Testing the Composite Video
- Measuring Performance
- Seeing the Dark Screen
- Test Pattern
- Plotting
- A Starry Night
- Line Drawing
- Bresenham Algorithm
- Plotting Math Functions
- Fractals
- Text
- Printing Text on Video
- Text Test
- The Matrix Reloaded
- Debriefing
- Notes for the PIC24 Experts
- Tips & Tricks
- Exercises
- Books
- Links
-
Day 14: Mass Storage
- The Plan
- Preparation
- The Exploration
- The Physical Interface
- Interfacing to the Explorer 16 Board
- Starting a New Project
- Selecting the SPI Mode of Operation
- Sending Commands in SPI Mode
- Completing the SD Card Initialization
- Reading Data from an SD/MMC Card
- Writing Data to an SD/MMC Card
- Testing the SD/MMC Interface
- Debriefing
- Tips & Tricks
- Exercises
- Books
- Links
-
Day 15: File I/O
- The Plan
- Preparation
- The Exploration
- Sectors and Clusters
- The File Allocation Table
- The Root Directory
- The Treasure Hunt
- Opening a File
- Reading Data from a File
- Closing a File
- The Fileio Module
- Testing fopenM() and freadM()
- Writing Data to a File
- Closing a File, Take Two
- Accessory Functions
- Testing the Complete Fileio Module
- Code Size
- Debriefing
- Tips & Tricks
- Exercises
- Books
- Links
-
Day 16: Musica, Maestro!
- The Plan
- Preparation
- The Exploration
- OC PWM Mode
- Testing the PWM as a D/A Converter
- Producing Analog Waveforms
- Reproducing Voice Messages
- A Media Player
- The WAVE File Format
- The play() Function
- The Audio Routines
- A Simple WAVE File Player
- Debriefing
- Tips & Tricks
- Exercises
- Books
- Links
- Disclaimer
- Final Note for the Experts
-
Day 12: Capturing User Inputs
- Index
Product information
- Title: Programming 32-bit Microcontrollers in C
- Author(s):
- Release date: April 2011
- Publisher(s): Newnes
- ISBN: 9780080560106
You might also like
book
Programming 8-bit PIC Microcontrollers in C
Microcontrollers are present in many new and existing electronic products, and the PIC microcontroller is a …
book
C Programming for the PIC Microcontroller: Demystify Coding with Embedded Programming
Go beyond the jigsaw approach of just using blocks of code you don’t understand and become …
book
GNU/Linux Rapid Embedded Programming
An annotated guide to program and develop GNU/Linux Embedded systems quickly About This Book Rapidly design …
book
Programming Arduino Projects with the PIC Microcontroller: A Line-by-Line Code Analysis and Complete Reference Guide for Embedded Programming in C
Now that you’ve built a few Arduino projects, and reused some pre-written sketches, it’s time to …