Enhanced mid-range (14-bit) PIC architecture and peripherals, using C (XC8) and assembly language
These lessons are intended for new students and do not assume any prior knowledge of other PIC families.
One set of lessons introduces the enhanced mid-range (14-bit) PIC architecture and peripherals, using assembly language.
A second set of lessons shows how to program enhanced mid-range PICs in C, using the Microchip XC8 compilers - and without having to learn assembly language first.
Migration lessons are also provided for those who have completed the baseline and mid-range tutorials, highlighting the new features of the enhanced mid-range architecture without repeating many of the earlier explanations.
To get the most out of these lessons, you should consider the Baseline and Mid-Range PIC training board (which was designed to complement these tutorial series), instead of purchasing these tutorials separately.
Additional enhanced mid-range PIC lessons will made available as free downloads to purchasers of these tutorials, as they become available.
The following lessons are currently included:
Assembly language lessons |
C lessons |
1: Lighting an LED Introducing the PIC12F1501 Using MPLAB X and the PICkit 3 to build and program PIC assember projects |
1: Lighting an LED Introducing the PIC12F1501 Using XC8, MPLAB X and the PICkit 3 to build and program PIC C projects |
2: Flashing an LED Adding delay loops, selecting the internal RC oscillator frequency |
2: Flashing an LED Using the XC8 delay function and macros Selecting the internal RC oscillator frequency |
3: Writing Modular Code Subroutines, relocatable modules, paged program memory access |
|
4: Reading Switches Internal pull-ups, reading and debouncing simple switches |
3: Reading Switches Internal pull-ups, reading and debouncing simple switches |
5: Timer0 Using Timer0 for event timing, delays, debouncing and as a counter |
4: Timer0 Using Timer0 for event timing, delays, debouncing and as a counter (with some examples of C macros) |
6: Assembler Directives and Macros MPASM expressions, macros and conditional assembly |
|
7: Introduction to Interrupts Interrupt service routines, timer and external interrupts, debouncing |
5: Introduction to Interrupts Interrupt service routines, timer and external interrupts, debouncing |
8: IOC, Sleep Mode and the Watchdog Timer Using interrupt-on-change, sleep mode and the watchdog timer |
6: IOC, Sleep Mode and the Watchdog Timer Using interrupt-on-change, sleep mode and the watchdog timer |
9: Reset, Power and Clock Options Introduction to the PIC16F1824 Oscillator (clock) modes, power-on and brown-out resets |
7: Reset, Power and Clock Options Introduction to the PIC16F1824 Oscillator (clock) modes, power-on and brown-out resets |
10: Analog Comparators Basic comparator operation, hysteresis, interrupts and wake on change |
8: Analog Comparators Basic comparator operation, hysteresis, interrupts and wake on change |
11: Voltage Reference and DAC Fixed voltage reference, digital-to-analog converter (DAC) and operation with comparators |
9: Voltage Reference and DAC Fixed voltage reference, digital-to-analog converter (DAC) and operation with comparators |
12: Driving 7-Segment Displays Single and multiple 7-segment displays, lookup tables, interrupt-driven multiplexing and binary-coded decimal (BCD) |
10: Driving 7-Segment Displays Single and multiple 7-segment displays, lookup tables and interrupt-driven multiplexing |
13: Analog-to-Digital Conversion Using the analog-to-digital converter (ADC) module, ADC interrupts and operation in sleep mode |
11: Analog-to-Digital Conversion and Simple Filtering Analog-to-digital conversion (ADC) and using arrays and simple integer expressions to calculate a moving average |
14: Arrays and Long Integer Arithmetic Indirect data and program memory addressing, multi-byte addition, subtraction and multiplication |
|
15: Timer1 Using Timer1 as a general 16-bit timer/counter, with an external watch crystal, operation in sleep mode, and applying gate control for pulse width, period and frequency measurement |
12: Timer1 Using Timer1 as a general 16-bit timer/counter, with an external watch crystal, operation in sleep mode, and applying gate control for pulse width, period and frequency measurement |
16: Timer2 Using Timer2 (or Timer4, Timer6, etc.) as a simple 8-bit timer, with period register and postscaler, to generate a specific interrupt time-base |
13: Timer2 Using Timer2 (or Timer4, Timer6, etc.) as a simple 8-bit timer, with period register and postscaler, to generate a specific interrupt time-base |
17: CCP, part 1 - Capture and Compare Using the CCP modules' capture and compare modes to measure signal and pulse widths and to trigger precisely timed events, including periodic analog sampling |
14: CCP, part 1 - Capture and Compare Using the CCP modules' capture and compare modes to measure signal and pulse widths and to trigger precisely timed events, including periodic analog sampling |
18: CCP, part 2 - PWM Using the CCP and ECCP modules' pulse-width modulation (PWM) modes for tasks including tone generation, LED dimming and bi-directional brushed DC motor control |
15: CCP, part 2 - PWM Using the CCP and ECCP modules' pulse-width modulation (PWM) modes for tasks including tone generation, LED dimming and bi-directional brushed DC motor control |