In my embedded system having the processor Freescale MK70FN1M0xxx12, I am unable to use the port F pins as interrupts. However, port E and port C do have this working. Port F is interrupt enabled on the processor yet the ISR(Interrupt Service Routine) is not functioning as expected for port F pins. Request to please give the information on what could be missing and how can it be resolved. As this is a show stopper, request to please get back ASAP.
Thanks in Advance!!! Charlie Gujrati
Hi
Please check attached demo code, which is using K70 PTF2 pin generate interrupt with TWR-K70F120M board.
The code is based on Kinetis 120MHz product bare-metal sample code [gpio] demo.
Wish it helps.
Have a great day,
Ma Hui
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Hi,
Thank you on your inputs. Could you please elaborate on the solution as i used the port F details as mentioned in the code as below:
PORTF_PCR2 =PORT_PCR_MUX(1)|PORT_PCR_IRQC(0xA)|PORT_PCR_PE_MASK|PORT_PCR_PS_MASK;
as the issue which i am facing is just on PORT F pins. However, for other PORTS viz., E, C i am able to receive Interrupts.
Only port F has the issue where in interrupts are not getting generate. but the pins go low to high viz., the voltage is in the range of 0-3V however, ISR routine is not getting called. Could you please help me out as this is a show stopper.
Thanks,
Charlie
Hi
Please check PORTx_PCRn register [IRQC] bit description:
The IRQC value 0xA is interrupt on falling edge, if customer want to generate interrupt at rising edge, the IRQC value should be 0x9.
Wish it helps.
Have a great day,
Ma Hui
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
please move your ticket to Kinetis Microcontrollers
Here is the i.MX community.
moved to Kinetis Microcontroller