This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

MSP430 PWM Frequency/Duty Cycle Measurements

I have the eZ430-RF2500 (with MSP430-F2274) and eZ430-F2013 (with MSP430-F2013) and I am having trouble getting started with this problem: I would like to program the MSP430 to take in a PWM signal from a function generator, calculate the Frequency and Duty Cycle of the signal, and then output those values.

I've read through the user guides, datasheets and examples, and I believe that to do this I would have to use some type of capture/compare setup where I determine the time difference between successive rises/falls, and then calculate the frequency and duty cycle from that. However, as I said I am having difficulty understanding how to set up the timer and capture/compare calculations to work this out. 

If anyone would be able to give me a starting point on how to set up the code for this, or point me towards example code that would do so, I would greatly appreciate it.

**Attention** This is a public forum