<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>LPC Microcontrollers中的主题 LPC1313 NVIC_EnableIRQ function</title>
    <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC1313-NVIC-EnableIRQ-function/m-p/684768#M27584</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I have enabled external interrupts on the pin 6 of Port0 of LPC1313 using the following steps-&lt;/P&gt;&lt;P&gt;(I am using the LPCOpen library for this.)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Chip_GPIO_SetPinDIRInput(LPC_GPIO_PORT, 0, 6);&lt;BR /&gt; Chip_GPIO_SetPinModeEdge(LPC_GPIO_PORT, 0, 64);&lt;BR /&gt; Chip_GPIO_SetEdgeModeSingle(LPC_GPIO_PORT, 0, 64);&lt;BR /&gt; Chip_GPIO_SetupPinInt(LPC_GPIO_PORT, 0, 6, GPIO_INT_RISING_EDGE);&lt;BR /&gt; Chip_GPIO_EnableInt(LPC_GPIO_PORT, 0, 64);&lt;BR /&gt; NVIC_ClearPendingIRQ(EINT0_IRQn);&lt;BR /&gt;NVIC_EnableIRQ(EINT0_IRQn);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There is no activity on the specified GPIO pin during this time (also verified in the DATA register for that port). However, as soon as the&amp;nbsp;&lt;SPAN&gt;NVIC_EnableIRQ(EINT0_IRQn); command is executed, an interrupt seems to have occurred and the program goes to the PIOINT0_IRQHandler.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Please tell me why an interrupt is getting registered on enabling and if there is a workaround to avoid this case.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Thanks and Regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Prachi&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 05 Jul 2017 08:45:34 GMT</pubDate>
    <dc:creator>prachipanse</dc:creator>
    <dc:date>2017-07-05T08:45:34Z</dc:date>
    <item>
      <title>LPC1313 NVIC_EnableIRQ function</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC1313-NVIC-EnableIRQ-function/m-p/684768#M27584</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I have enabled external interrupts on the pin 6 of Port0 of LPC1313 using the following steps-&lt;/P&gt;&lt;P&gt;(I am using the LPCOpen library for this.)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Chip_GPIO_SetPinDIRInput(LPC_GPIO_PORT, 0, 6);&lt;BR /&gt; Chip_GPIO_SetPinModeEdge(LPC_GPIO_PORT, 0, 64);&lt;BR /&gt; Chip_GPIO_SetEdgeModeSingle(LPC_GPIO_PORT, 0, 64);&lt;BR /&gt; Chip_GPIO_SetupPinInt(LPC_GPIO_PORT, 0, 6, GPIO_INT_RISING_EDGE);&lt;BR /&gt; Chip_GPIO_EnableInt(LPC_GPIO_PORT, 0, 64);&lt;BR /&gt; NVIC_ClearPendingIRQ(EINT0_IRQn);&lt;BR /&gt;NVIC_EnableIRQ(EINT0_IRQn);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There is no activity on the specified GPIO pin during this time (also verified in the DATA register for that port). However, as soon as the&amp;nbsp;&lt;SPAN&gt;NVIC_EnableIRQ(EINT0_IRQn); command is executed, an interrupt seems to have occurred and the program goes to the PIOINT0_IRQHandler.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Please tell me why an interrupt is getting registered on enabling and if there is a workaround to avoid this case.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Thanks and Regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Prachi&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Jul 2017 08:45:34 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC1313-NVIC-EnableIRQ-function/m-p/684768#M27584</guid>
      <dc:creator>prachipanse</dc:creator>
      <dc:date>2017-07-05T08:45:34Z</dc:date>
    </item>
    <item>
      <title>Re: LPC1313 NVIC_EnableIRQ function</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC1313-NVIC-EnableIRQ-function/m-p/684769#M27585</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello prachi panse,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; Please call clear peinding interrupts for selected pins before you enable the IRQ:&lt;/P&gt;&lt;P&gt;STATIC INLINE void Chip_GPIO_ClearInts(LPC_GPIO_T *pGPIO, uint8_t port, uint32_t pinmask)&lt;BR /&gt;{&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;pGPIO[port].IC = pinmask;&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please try it on your side at first.&lt;/P&gt;&lt;P&gt;If you still have problem, please let me know!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Have a great day,&lt;BR /&gt;Kerry&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-----------------------------------------------------------------------------------------------------------------------&lt;BR /&gt;Note: If this post answers your question, please click the Correct Answer button. Thank you!&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Jul 2017 08:01:07 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC1313-NVIC-EnableIRQ-function/m-p/684769#M27585</guid>
      <dc:creator>kerryzhou</dc:creator>
      <dc:date>2017-07-06T08:01:07Z</dc:date>
    </item>
    <item>
      <title>Re: LPC1313 NVIC_EnableIRQ function</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC1313-NVIC-EnableIRQ-function/m-p/684770#M27586</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello prachi panse,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; Please call clear peinding interrupts for selected pins before you enable the IRQ:&lt;/P&gt;&lt;P&gt;STATIC INLINE void Chip_GPIO_ClearInts(LPC_GPIO_T *pGPIO, uint8_t port, uint32_t pinmask)&lt;BR /&gt;{&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;pGPIO[port].IC = pinmask;&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please try it on your side at first.&lt;/P&gt;&lt;P&gt;If you still have problem, please let me know!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Have a great day,&lt;BR /&gt;Kerry&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-----------------------------------------------------------------------------------------------------------------------&lt;BR /&gt;Note: If this post answers your question, please click the Correct Answer button. Thank you!&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Jul 2017 08:06:10 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC1313-NVIC-EnableIRQ-function/m-p/684770#M27586</guid>
      <dc:creator>kerryzhou</dc:creator>
      <dc:date>2017-07-06T08:06:10Z</dc:date>
    </item>
  </channel>
</rss>

