Microcontrollers: From Assembly Language to C Using the PIC24 Family, by R. Reese, B. Jones, and J. W. Bruce, covers assembly language, C programming, and hardware interfacing for the Microchip PIC24 family, a recently introduced microcontroller family from Microchip. Hardware interfacing topics include parallel port usage, analog-to-digital conversion, digital-to-analog conversion, the serial peripheral bus (SPI), the inter-integrated circuit bus (I2C), asynchronous serial communication, and timers. Numerous lab experiments are included in the appendices. All source code is compatible with the free assembler and compiler tools available from Microchip. The text incorporates detailed description of the PIC24 library collection though numerous, carefully-explained code examples and forms the basis of an introductory course on microcontrollers and microprocessors. An errata list provides corrections to textbook errors. The text is approximately 800 pages (~250 pages for introduction and assembly language programming, ~450 pp. hardware interfacing using C, ~100 pages for appendices). A book FAQ answers some common questions, like 'Why should I switch to the PIC24 family?". A list of book adopters provides other views of how this material is used for microcontroller education. You are also welcome to join the "PIC24 Assembly-to-C Book" discussion group. For educators and students
The textbook comes with homework problems and lab experiments, including working source code which students base their labs on. ECE 3724 (Microprocessors), taught at MSU, provides a class schedule, lecture slides, suggested homework problems, and more. A PCB for instructors provides a simple platform on which most of the programs in the book can be quickly evaluated. A getting started guide enables students and instructors to bring their system to life and begin the hardware portion of the lab. Please contact the authors for more information!For hobbyists
The textbook provides a wealth of well-documented, working examples of useful building blocks for your creations! From wiring up your PIC to building a large system, the explanations provided are backed by a well-documented, freely-downloadable software library.
Chapters (first edition)
(A detailed table of contents can be found here)
- Number System and Digital Logic Review
- The Stored Program Machine
- Introduction to the PIC24 Microcontroller Family
- Unsigned 8/16-bit Arithmetic, Logical, Conditional Operations
- Extended Precision and Signed Data Operations
- Pointers and Subroutines
- Advanced Assembly Language: Higher Math
- The PIC24HJ32GP202: System Startup and Parallel Port I/O
- Interrupts and a First Look at Timers
- Asynchronous and Synchronous Serial I/O
- Data Conversion
- Advanced Hardware Topics
- Operating Systems for Embedded Systems
- Capstone Projects
- Appendix A - PIC24 Architecture and Instruction Set Summary
- Appendix B - Software Tools Overview
- Appendix C - Suggested Laboratory Exercises
- Appendix D - Notes on the C Language and the Book's PIC24 Library Functions
- Appendix E - Circuits 001
- Appendix F - References
- Appendix G - Problem Solutions to odd numbered end-of-chapter exercises (even-numbered solutions are available by email request of instructor to the authors).
The text is suitable for multiple courses. It is used at MSU in an introductory microcontroller course that integrates assembly language programming (6 weeks) taught in a C context along with basic hardware interfacing (8 weeks) that is implemented using C. Chapters 1-6,8,9,10,11 (selected topics), 12 (selected topics) are covered. For a traditional assembly language based course, Chapters 1-7 can be covered in detail, and selected hardware topics discussed in an assembly language context. The text can also be used in a traditional embedded systems course that begins with hardware interfacing and uses C for program implementation. Such a course would cover Chapters 8-15 as these comprise the hardware interfacing portion of the text.
These supplements are meant to be used with the first edition of the book:
- Appendix H - The ADC Module with DMA - discusses differences between ADC operation for PIC24 CPUs with and without DMA (the code examples in Chapter 11 use a PIC24 without DMA). Presents code examples for using the ADC with the DMA module.
- A prototyping walkthrough for the PIC24HJ32GP202 system of Chapter 8.
Mapping of Figures to Code Examples (first edition)
Book FAQ, Book Adopters
Here is a book FAQ, with common questions such as "Why use the PIC24 instead of the PIC18 family?". A list of book adopters provides alternate views on how this material is used for microcontroller education.
Where to Buy
Visit the errata list for corrections to textbook errors.
Textbook Online References (datasheets, reference manuals, etc)
Here is a list of online references used by the textbook.