Other Parts Discussed in Thread: EK-TM4C1294XL
Hi,
I am using TM4C129EKCPDT with Code Compressor studio v11 .
What is the best way to generate 10us pulse with n number of pulses and measure the 10us pulse ??.
Regards,
Sumit Chaulya
LTTS
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.
Hi,
I am using TM4C129EKCPDT with Code Compressor studio v11 .
What is the best way to generate 10us pulse with n number of pulses and measure the 10us pulse ??.
Regards,
Sumit Chaulya
LTTS
Hi,
There are two modules that you can use to generate PWM. These the timer module and the PWM module. To generate PWM using the timer module, you can refer to C:\ti\TivaWare_C_Series-2.2.0.295\examples\peripherals\timer\pwm.c file. Once the PWM is starting it will just continue. If you want to generate for a 'n' number of pulses then you will need to manually stop the PWM generation. The timer module can also do either time or edge measurements on an input pin. Please refer to the datasheet for details.
If you want to use the PWM module to generate PWM then there are pwm_invert, pwm_interrupt and pwm_dead_band examples. They can be found in C:\ti\TivaWare_C_Series-2.2.0.295\examples\boards\ek-tm4c1294xl.
Hi Charles,
Thank you for your response.
I need another help from you . What is the best way to detect and measure the 10us pulse width with maximum accuracy ???
Thanks and regards,
Sumit
Hi,
Is your 10us input pulse periodic?
You can configure one timer to detect rise edge and another timer to detect fall edge. Take the timestamp difference between the two edges and you can measure your input pulse width.