A PWM signal is analysed to extract its frequency and Duty Cycle, the Duty and Period can be selected for display on the port B,D using Pin C7

Description
Both capture modules are used, CCP1 is configured to detect the rising edge which marks the beginning of the period. CCP2 is configured to detected the falling edge which marks the end of duty cycle. Timer1 is cleared on CCP1 interrupt.
| Filename | Version | Description |
| tut15.pjt | 1.0 | MPLAB Project |
| tut15.asm | 1.0 | PIC16F628 Assembler code |
| tut15.hex | 1.0 | Precompiled HEX |
| tut15.lst | 1.0 | Precompiled LST |
| tut15.vbb | 1.0 | Virtual Breadboard simulation |
|
|
CCP1 Capture |
|
|
CCP2 Capture |