Dear Freescale,
I have a question for GPT Interrupt.
For this, I configured the GPT Interrupt like as below,
- used GPT : GPT2
- Interrupt Period : 100usec
- Interrupt Pin : MX25_PIN_GPIO_D
So I expected that the interrupt pin will be toggled with 100usec period.
But the result was strange based on ISR.
- with ISR : Abnormal Operation
- without ISR : Normal Operation
Could you tell me what's the problem?
For your more understanding, I'll attach the modified/added files.
- Kernel
. arch/arm/mach-mx25/clock.c
: add GPT2 clock (survey "Eric" in the code)
- Driver
. mx25_gpt_interrupt_driver.c
: GPT Interrupt Test driver
: GPT ISR in the code
#if 1 // GPT Interrupt ISR - No.ISR = Normal / OK.ISR = Ab-normal
/* GPT ISR register */
setup_irq(irq, &mxc_timer_irq_kicc);
#endif
- captured Wave
. Normal : Normal-Without_GPT_ISR.jpg
. Abnormal : Abnormal-With_GPT_ISR.jpg
Best Regards,
Eric.
Original Attachment has been moved to: clock.c.zip
Original Attachment has been moved to: mx25_gpt_interrupt_driver.c.zip
You can refer arch/arm/plat-mxc/time.c for the gpt interrupt setting.
GPTIR should be set to 0x1.
Please also try to use ipg_clk_32k as gpt clock source to test if the issue is still exist.
Dear Shaojun Wang,
I applied the gpt interrupt setting of arch/arm/plat-mxc/time.c,
but the result was the same.
And I applied the EPIT, but the result was the same.
Actually when I used the GPIO interrupt, the result was Success.
I don't know what's the problem.
Could you give me other guide?