<?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>Kinetis MicrocontrollersのトピックRe: Kinetis K65 interrupt nesting</title>
    <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Kinetis-K65-interrupt-nesting/m-p/842802#M50802</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;That sounds right. Simplest thing to do is try it and then you can be sure.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mark&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 07 Jan 2019 03:56:49 GMT</pubDate>
    <dc:creator>mjbcswitzerland</dc:creator>
    <dc:date>2019-01-07T03:56:49Z</dc:date>
    <item>
      <title>Kinetis K65 interrupt nesting</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Kinetis-K65-interrupt-nesting/m-p/842798#M50798</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am using one of the PIT channel as a base timer interrupt for my scheduler. Is there a way or workaround to allow the&amp;nbsp;same interrupt to come again when the interrupt is getting executed? I want to implement a task overrun based on this feature. Otherwise please suggest a better way of doing it.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 29 Dec 2018 05:51:53 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Kinetis-K65-interrupt-nesting/m-p/842798#M50798</guid>
      <dc:creator>kishorebolisett</dc:creator>
      <dc:date>2018-12-29T05:51:53Z</dc:date>
    </item>
    <item>
      <title>Re: Kinetis K65 interrupt nesting</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Kinetis-K65-interrupt-nesting/m-p/842799#M50799</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Kishore Bolisetti,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; What do you mean?&amp;nbsp; Do you still want to use another PIT channel timer interrupt?&lt;/P&gt;&lt;P&gt;From the K65 interrupt vector assignments table, you can know that different PIT channel have different vector&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_1.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/71394iA8000256A049A51B/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_1.png" alt="pastedImage_1.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;So, you can use other PIT channel interrupt.&lt;/P&gt;&lt;P&gt;But the same interrupt when happens, and didn't exit the ongoing interrupt handler, it can't generate another same interrupt.&lt;/P&gt;&lt;P&gt;&amp;nbsp;So, I think you can try another channel PIT interrupt.&lt;/P&gt;&lt;P&gt;Wish it helps you!&lt;/P&gt;&lt;P&gt;If you still have question about it, please kindly let me know.&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>Wed, 02 Jan 2019 11:01:17 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Kinetis-K65-interrupt-nesting/m-p/842799#M50799</guid>
      <dc:creator>kerryzhou</dc:creator>
      <dc:date>2019-01-02T11:01:17Z</dc:date>
    </item>
    <item>
      <title>Re: Kinetis K65 interrupt nesting</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Kinetis-K65-interrupt-nesting/m-p/842800#M50800</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When you are running in the interrupt context the interrupt mask level will be set to the interrupt's priority. If you thus clear the original interrupt in the peripheral and allow it to fire again it won't be able to pre-empt the original interrupt routine unless it has a higher priority.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You could thus increase the interrupt priority of the peripheral in the first interrupt handler to make it able to interrupt again.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mark&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Complete Solutions and technical support for professional Kinetis developments: &lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="https://community.nxp.com/external-link.jspa?url=http%3A%2F%2Fwww.utasker.com%2Fkinetis.html" rel="nofollow" target="_blank"&gt;http://www.utasker.com/kinetis.html&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Jan 2019 18:11:45 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Kinetis-K65-interrupt-nesting/m-p/842800#M50800</guid>
      <dc:creator>mjbcswitzerland</dc:creator>
      <dc:date>2019-01-02T18:11:45Z</dc:date>
    </item>
    <item>
      <title>Re: Kinetis K65 interrupt nesting</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Kinetis-K65-interrupt-nesting/m-p/842801#M50801</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, Thanks for the response. My configurations are as per below:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. During Initialization&lt;/P&gt;&lt;P&gt;   1.1 Configure PIT channel 2 interrupt (5 milliseconds periodicity)&lt;/P&gt;&lt;P&gt;   1.2 Set Priority group in (SCB AIRCR register) to 3&lt;/P&gt;&lt;P&gt;   1.3 Set NVIC priority register to have a value of 0x40&lt;/P&gt;&lt;P&gt;   1.4 Start the PIT channel&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2. In interrupt processing&lt;/P&gt;&lt;P&gt;   2.1 Clear PIT Channel 2 status&lt;/P&gt;&lt;P&gt;   2.2 Set NVIC priority register to have a value of 0x20 to increase the interrupt priority to allow the same interrupt to come again&lt;/P&gt;&lt;P&gt;   2.3 Interrupt or task processing&lt;/P&gt;&lt;P&gt;   2.4 Set NVIC priority register to have a value of 0x40 to bring back the priority to initial set value&lt;/P&gt;&lt;P&gt;   2.5 exit from the interrupt&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the step 2.3, i create a delay of 10 milliseconds and expect the processor control to hit the entry point of the interrupt while it is within step 2.3. Please let me know if the expected behavior is possible with this microcontroller?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Kishore&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 05 Jan 2019 03:49:20 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Kinetis-K65-interrupt-nesting/m-p/842801#M50801</guid>
      <dc:creator>kishorebolisett</dc:creator>
      <dc:date>2019-01-05T03:49:20Z</dc:date>
    </item>
    <item>
      <title>Re: Kinetis K65 interrupt nesting</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Kinetis-K65-interrupt-nesting/m-p/842802#M50802</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;That sounds right. Simplest thing to do is try it and then you can be sure.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mark&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Jan 2019 03:56:49 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Kinetis-K65-interrupt-nesting/m-p/842802#M50802</guid>
      <dc:creator>mjbcswitzerland</dc:creator>
      <dc:date>2019-01-07T03:56:49Z</dc:date>
    </item>
    <item>
      <title>Re: Kinetis K65 interrupt nesting</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Kinetis-K65-interrupt-nesting/m-p/842803#M50803</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have already tested the sequence, but I did not succeed in getting a overrun of the interrupt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Kishore&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Jan 2019 05:22:47 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Kinetis-K65-interrupt-nesting/m-p/842803#M50803</guid>
      <dc:creator>kishorebolisett</dc:creator>
      <dc:date>2019-01-07T05:22:47Z</dc:date>
    </item>
    <item>
      <title>Re: Kinetis K65 interrupt nesting</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Kinetis-K65-interrupt-nesting/m-p/842804#M50804</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Kishore&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Unfortunately I was probably wrong about the interrupt vector priority being able to interrupt itself.&lt;BR /&gt;When the PIT channel fires and its vector is taken the processor sets its "active interrupt vector" to its reference and although it is possible to get the second (higher priority) vector as a "pending vector" (see System Control Block's ICSR register where both are shown) the Cortex M4 doesn't look to allow a pending vector to be taken that is the &lt;EM&gt;same as the presently active vector&lt;/EM&gt;.&lt;BR /&gt;As long as the pending vector is &lt;EM&gt;not equal&lt;/EM&gt; to the active vector and the pending source's priority is higher than the active vector it is then indeed taken.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The only way that I can see the second being taken is to exit from its interrupt context, which sets the active vector back to zero and then it immediately re-enters.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Therefore it looks like you need to leave the initial interrupt context eg. using BX LR, which means that it is more complicated and requires a more traditional context switch where you swap the stacks beforehand.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As Kerry pointed out, the PIT has 4 channels, each with its own interrupt vector and so if you run multiple PITS in parallel you can then allow a second one to interrupt a first one's interrupt context by controlling the interrupt priorities of each channel.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The question is whether this is a good base for a scheduler or not?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mark&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 08 Jan 2019 00:49:12 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Kinetis-K65-interrupt-nesting/m-p/842804#M50804</guid>
      <dc:creator>mjbcswitzerland</dc:creator>
      <dc:date>2019-01-08T00:49:12Z</dc:date>
    </item>
    <item>
      <title>Re: Kinetis K65 interrupt nesting</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Kinetis-K65-interrupt-nesting/m-p/842805#M50805</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Mark &amp;amp; Kerry – Definitely this behavior is not so friendly to be used for preemptive based schedulers which use single interrupt. I have used similar feature successfully on power-pc cores.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But thanks for all your guidance and support on this topic. I will try to figure out a way to handle overrun.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Kishore&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 08 Jan 2019 03:36:40 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Kinetis-K65-interrupt-nesting/m-p/842805#M50805</guid>
      <dc:creator>kishorebolisett</dc:creator>
      <dc:date>2019-01-08T03:36:40Z</dc:date>
    </item>
  </channel>
</rss>

