I am using PORT AD of MC9S12XEP100 for general purpose input. I can set the Data & Data Direction of that port but how can I configure that port for interrupt and what will be the vector number for the ISR?
Hi Harshal Pawar,
In addition to Edward, I recommend this technical note of Defining Interrupt Functions.
There are two methods to define an interrupt. I recommend you the second one. "The keyword “interrupt”"
For detail, see attached TN101.
Have a great day,
Jun Zhang
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
First of all this question is not related to CW and especially CW for MCU's. Please use next time for S12XE related questions: https://community.nxp.com/community/s32/16-bit/content , and if your have CW 5.x for S12(X) related questions https://community.nxp.com/community/codewarrior/classic/content .
And regarding your request, not all S12XE ports have interrupt capability. Ports AD0 and AD1 are not interrupt capable. However you can use external AD trigger to fire some AD conversion, which you may further configure to trigger AD interrupt on completion of AD sequence.
Edward