<?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>topic Re: Configure ADC Sampling from PDB in MCUXpresso Config Tools</title>
    <link>https://community.nxp.com/t5/MCUXpresso-Config-Tools/Configure-ADC-Sampling-from-PDB/m-p/949319#M799</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Felipe,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We are currently targeting the MKV31F512VLL12.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Eric&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 20 Sep 2019 15:46:42 GMT</pubDate>
    <dc:creator>ewilliams</dc:creator>
    <dc:date>2019-09-20T15:46:42Z</dc:date>
    <item>
      <title>Configure ADC Sampling from PDB</title>
      <link>https://community.nxp.com/t5/MCUXpresso-Config-Tools/Configure-ADC-Sampling-from-PDB/m-p/949317#M797</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm trying to determine how to configure an ADC0 conversion trigger from the PDB peripheral in the Peripherals too. I'm attempting capture BLDC motor phase current based on PWM edges, and it's my understanding that this is possible, however I don't see this option in the ADC16 Configuration options.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="ADC_Configuration.PNG"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/83341i1525E0BA5232D5C3/image-size/large?v=v2&amp;amp;px=999" role="button" title="ADC_Configuration.PNG" alt="ADC_Configuration.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any guidance or suggestions on reading material would be greatly appreciated.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Eric&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 19 Sep 2019 14:54:21 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-Config-Tools/Configure-ADC-Sampling-from-PDB/m-p/949317#M797</guid>
      <dc:creator>ewilliams</dc:creator>
      <dc:date>2019-09-19T14:54:21Z</dc:date>
    </item>
    <item>
      <title>Re: Configure ADC Sampling from PDB</title>
      <link>https://community.nxp.com/t5/MCUXpresso-Config-Tools/Configure-ADC-Sampling-from-PDB/m-p/949318#M798</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Eric,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Could you please let me know which device are you working on?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Felipe&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 19 Sep 2019 19:43:37 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-Config-Tools/Configure-ADC-Sampling-from-PDB/m-p/949318#M798</guid>
      <dc:creator>FelipeGarcia</dc:creator>
      <dc:date>2019-09-19T19:43:37Z</dc:date>
    </item>
    <item>
      <title>Re: Configure ADC Sampling from PDB</title>
      <link>https://community.nxp.com/t5/MCUXpresso-Config-Tools/Configure-ADC-Sampling-from-PDB/m-p/949319#M799</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Felipe,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We are currently targeting the MKV31F512VLL12.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Eric&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 Sep 2019 15:46:42 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-Config-Tools/Configure-ADC-Sampling-from-PDB/m-p/949319#M799</guid>
      <dc:creator>ewilliams</dc:creator>
      <dc:date>2019-09-20T15:46:42Z</dc:date>
    </item>
    <item>
      <title>Re: Configure ADC Sampling from PDB</title>
      <link>https://community.nxp.com/t5/MCUXpresso-Config-Tools/Configure-ADC-Sampling-from-PDB/m-p/949320#M800</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Eric,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Unfortunately, there is no way to do that using the Config Tools. However, you can do that by writing to the SIM_SOPT7 register. Please check &lt;A href="https://www.nxp.com/webapp/Download?colCode=KV31P100M120SF7RM"&gt;reference manual&lt;/A&gt; chapter 12.2.6.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In addition, I recommend you to check the mc_bldc example from the SDK, I think this may be helpful as a starting point to your application.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I hope it helps!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;BR /&gt;Have a great day,&lt;BR /&gt;Felipe&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-------------------------------------------------------------------------------&lt;BR /&gt;Note:&lt;BR /&gt;- If this post answers your question, please click the "Mark Correct" button. Thank you!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- We are following threads for 7 weeks after the last post, later replies are ignored&lt;BR /&gt; Please open a new thread and refer to the closed one, if you have a related question at a later point in time.&lt;BR /&gt;-------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Sep 2019 20:56:01 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-Config-Tools/Configure-ADC-Sampling-from-PDB/m-p/949320#M800</guid>
      <dc:creator>FelipeGarcia</dc:creator>
      <dc:date>2019-09-23T20:56:01Z</dc:date>
    </item>
    <item>
      <title>Re: Configure ADC Sampling from PDB</title>
      <link>https://community.nxp.com/t5/MCUXpresso-Config-Tools/Configure-ADC-Sampling-from-PDB/m-p/949321#M801</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Eric,&lt;/P&gt;&lt;P&gt;Routing of the ADC triggers SIM_SOPT7 can be easily setup in Pins tool (on picture are both set to the PDB0_CH0 A and B - only PDB option allows to use more than 1 HW trigger in ADC):&lt;span class="lia-inline-image-display-wrapper" image-alt="Pins_tool_part.PNG"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/81043iE7070AA8AF9610E8/image-size/large?v=v2&amp;amp;px=999" role="button" title="Pins_tool_part.PNG" alt="Pins_tool_part.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Peripherals tool:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;Inside the ADC component:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;You have to set Use hardware trigger and specify asignement of the channel to the Conversion group (Group 0 = SC1A, Group 1 = SC1B register) and set initialize channel to write to this register selected setting:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="Peripherals_tool_part_ADC.PNG"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/81363i7DE40314A2DEF245/image-size/large?v=v2&amp;amp;px=999" role="button" title="Peripherals_tool_part_ADC.PNG" alt="Peripherals_tool_part_ADC.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Inside PDB component set the appropriate input trigger for the PDB in Trigger input source (here Trigger 8 - &lt;SPAN class=""&gt;FTM0 initialization trigger and channel triggers, as programmed in the FTM external trigger register (EXTTRIG)&lt;/SPAN&gt;) for other options please see &lt;SPAN class=""&gt;3.8.1.1.2 PDB Input Trigger Connections in &lt;SPAN class=""&gt;KV31F Sub-Family Reference Manual , Rev. 4, 02/2016.&lt;/SPAN&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Then add ADC triggering configurations (+ button), select Triggered device (ADC0 by default), then add&amp;nbsp; Pre-trigger&amp;nbsp; (+ button) and set up Pre-triggers configuration (delays are available only with Output source set to Delayed trigger):&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="Peripherals_tool_part_PDB.PNG"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/81454i2D550FEFFF4F7334/image-size/large?v=v2&amp;amp;px=999" role="button" title="Peripherals_tool_part_PDB.PNG" alt="Peripherals_tool_part_PDB.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Inside the FTM component (I expect that you use FTM for the PWM outputs generation) you need to setup the sources of the PDB trigger:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="Peripherals_tool_part_FTM.PNG"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/81517i7EA9FCB4538CB0A9/image-size/large?v=v2&amp;amp;px=999" role="button" title="Peripherals_tool_part_FTM.PNG" alt="Peripherals_tool_part_FTM.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;This is the main trigger thread which satisfies all your needs.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you have other questions do not hesitate to ask us - your Config tools team.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Have a nice day&lt;/P&gt;&lt;P&gt;Jiri&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 24 Sep 2019 11:51:03 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-Config-Tools/Configure-ADC-Sampling-from-PDB/m-p/949321#M801</guid>
      <dc:creator>jch</dc:creator>
      <dc:date>2019-09-24T11:51:03Z</dc:date>
    </item>
  </channel>
</rss>

