<?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: Using PIT channel 0 as a PDB trigger input source</title>
    <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-PIT-channel-0-as-a-PDB-trigger-input-source/m-p/469077#M28337</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Isaac,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for the answer. My program is working now. &lt;/P&gt;&lt;P&gt;Best Regards&lt;/P&gt;&lt;P&gt;Nadine,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 23 Feb 2016 12:06:32 GMT</pubDate>
    <dc:creator>nadine</dc:creator>
    <dc:date>2016-02-23T12:06:32Z</dc:date>
    <item>
      <title>Using PIT channel 0 as a PDB trigger input source</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-PIT-channel-0-as-a-PDB-trigger-input-source/m-p/469075#M28335</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Starting from the program pdb_dac_trigger.c available in the KSDK v2.0&amp;nbsp; driver_examples/pdb directory,&lt;/P&gt;&lt;P&gt;I'm trying to use the PIT Channel 0 as a trigger input source of the PDB instead of a trigger software.&lt;/P&gt;&lt;P&gt;To do so, I have made some unsuccessfully changes in the pdb_dac_trigger.c program. See joined file.&lt;/P&gt;&lt;P&gt;So, any help, or idea is welcome.&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best Regards&lt;/P&gt;&lt;P&gt;Nadine,&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Original Attachment has been moved to: &lt;A _jive_internal="true" href="https://community.nxp.com/docs/DOC-337428"&gt;pdb_dac_trigger.c.zip&lt;/A&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 18 Feb 2016 15:36:58 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-PIT-channel-0-as-a-PDB-trigger-input-source/m-p/469075#M28335</guid>
      <dc:creator>nadine</dc:creator>
      <dc:date>2016-02-18T15:36:58Z</dc:date>
    </item>
    <item>
      <title>Re: Using PIT channel 0 as a PDB trigger input source</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-PIT-channel-0-as-a-PDB-trigger-input-source/m-p/469076#M28336</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Nadine,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Some quick points:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;You were having hard fault interrupts when trying to write to DAC registers before initializing DAC module. You started the PIT timer, then, once it has an overflow, it triggers the PDB, on the PDB interrupt, you tried to write to DAC registers but at that time, DAC wasn't initialized and then a hard fault occurred. To avoid it, just start the PIT module just after PIT, PDB and DAC have been initialized:&lt;/LI&gt;&lt;/UL&gt;&lt;PRE __default_attr="c++" __jive_macro_name="code" class="jive_macro_code _jivemacro_uid_1455912185893673 jive_text_macro" data-renderedposition="170_8_1192_192" jivemacro_uid="_1455912185893673" modifiedtitle="true"&gt;&lt;P&gt;/* FIfo loading */&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; for (DACIndex = 0U; DACIndex &amp;lt; DAC_USED_BUFFER_SIZE; DACIndex++)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; DAC_BASE-&amp;gt;DAT[DACIndex].DATL = datl[sinusIndex]; /* Low 8-bit.&amp;nbsp; */&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; DAC_BASE-&amp;gt;DAT[DACIndex].DATH = dath[sinusIndex]; /* High 4-bit. */&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; sinusIndex++;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (sinusIndex &amp;gt;= SINUS_SIZE)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; sinusIndex = 0;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; DACIndex = 0;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; PIT_StartTimer(PIT, kPIT_Chnl_0);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/PRE&gt;&lt;UL&gt;&lt;LI&gt;PIT trigger is used to start PDB counting. If you select to use continuous mode (on PDB configuration), then once PIT has triggered PDB module, PDB will generate pulses according to its MOD and CNT registers (It will not use PIT anymore, due PDB has already been triggered and it is configured as continuous mode), on the other hand, if you want to be synchronized by PIT, you will have to disable continuous mode, so this way, PIT could start PDB once it has finish counting.&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope this can help you!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Isaac&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Feb 2016 20:09:00 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-PIT-channel-0-as-a-PDB-trigger-input-source/m-p/469076#M28336</guid>
      <dc:creator>isaacavila</dc:creator>
      <dc:date>2016-02-19T20:09:00Z</dc:date>
    </item>
    <item>
      <title>Re: Using PIT channel 0 as a PDB trigger input source</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-PIT-channel-0-as-a-PDB-trigger-input-source/m-p/469077#M28337</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Isaac,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for the answer. My program is working now. &lt;/P&gt;&lt;P&gt;Best Regards&lt;/P&gt;&lt;P&gt;Nadine,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 23 Feb 2016 12:06:32 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-PIT-channel-0-as-a-PDB-trigger-input-source/m-p/469077#M28337</guid>
      <dc:creator>nadine</dc:creator>
      <dc:date>2016-02-23T12:06:32Z</dc:date>
    </item>
  </channel>
</rss>

