Read PWM input using PIC24HJ128GP502

Thread Starter

vikas kumar_1516955635

Joined Jan 26, 2018
3
Hi,

I am using pic24hj128gp502

I am generating a 1KHz signal using a function generator, 5Vpk-pk, 20% duty.

I need to measure the PWM usnig my PIC24 and see it in my UART2 port.

I have executed UART2 port and I can see a message that i send

I saw some guide regarding input capture compare but I didn't understand how to implement it in software

Guide: http://ww1.microchip.com/downloads/en/D ... 70198D.pdf

I have attached my code. Please have a look and let me know how to move further.

Also can I please know when the CPU reads the input of the PWM what it reads as ? as a binary or as a hex value?

Please import the file to your MPLAB and look only for the following files

main.c
CCP.c
CCP.h
CONU2.c
CONU2.h
 

Attachments

Top