<?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 How to calculate the ADC Clock? in Kinetis Software Development Kit</title>
    <link>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/How-to-calculate-the-ADC-Clock/m-p/540822#M5571</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN&gt;Hello, I'm trying use ADC at FRDM-K22F, it's working, but I didn't get success on calculate the ADC clock. I'm using &lt;/SPAN&gt;&lt;A _jive_internal="true" href="https://community.nxp.com/external-link.jspa?url=http%3A%2F%2Fwww.nxp.com%2Fproducts%2Fmicrocontrollers-and-processors%2Farm-processors%2Fkinetis-cortex-m-mcus%2Fadc-calculator%3AADC_CALCULATOR" rel="nofollow" target="_blank"&gt;http://www.nxp.com/products/microcontrollers-and-processors/arm-processors/kinetis-cortex-m-mcus/adc-calculator:ADC_CALCULATOR&lt;/A&gt;&lt;SPAN&gt; for calculate the ADC clock, but the result the calculator don't is equal at result of conversion.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm setting my ADC clock this way:&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; adcUserConfig.resolution = kAdc16ResolutionBitOf16;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; adcUserConfig.highSpeedEnable = false;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; adcUserConfig.clkSrc = kAdc16ClkSrcOfBusClk;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; adcUserConfig.lowPowerEnable = false;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; adcUserConfig.asyncClkEnable = false;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; adcUserConfig.longSampleTimeEnable = false;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; adcUserConfig.longSampleCycleMode = kAdc16LongSampleCycleOf24;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; adcUserConfig.clkDividerMode = kAdc16ClkDividerOf8;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ADC16_DRV_Init(ADC16_INSTANCE, &amp;amp;adcUserConfig);&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What's the result of ADC clock for this example?&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 05 Jul 2016 19:47:50 GMT</pubDate>
    <dc:creator>adrianocasimiro</dc:creator>
    <dc:date>2016-07-05T19:47:50Z</dc:date>
    <item>
      <title>How to calculate the ADC Clock?</title>
      <link>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/How-to-calculate-the-ADC-Clock/m-p/540822#M5571</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN&gt;Hello, I'm trying use ADC at FRDM-K22F, it's working, but I didn't get success on calculate the ADC clock. I'm using &lt;/SPAN&gt;&lt;A _jive_internal="true" href="https://community.nxp.com/external-link.jspa?url=http%3A%2F%2Fwww.nxp.com%2Fproducts%2Fmicrocontrollers-and-processors%2Farm-processors%2Fkinetis-cortex-m-mcus%2Fadc-calculator%3AADC_CALCULATOR" rel="nofollow" target="_blank"&gt;http://www.nxp.com/products/microcontrollers-and-processors/arm-processors/kinetis-cortex-m-mcus/adc-calculator:ADC_CALCULATOR&lt;/A&gt;&lt;SPAN&gt; for calculate the ADC clock, but the result the calculator don't is equal at result of conversion.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm setting my ADC clock this way:&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; adcUserConfig.resolution = kAdc16ResolutionBitOf16;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; adcUserConfig.highSpeedEnable = false;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; adcUserConfig.clkSrc = kAdc16ClkSrcOfBusClk;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; adcUserConfig.lowPowerEnable = false;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; adcUserConfig.asyncClkEnable = false;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; adcUserConfig.longSampleTimeEnable = false;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; adcUserConfig.longSampleCycleMode = kAdc16LongSampleCycleOf24;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; adcUserConfig.clkDividerMode = kAdc16ClkDividerOf8;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ADC16_DRV_Init(ADC16_INSTANCE, &amp;amp;adcUserConfig);&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What's the result of ADC clock for this example?&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Jul 2016 19:47:50 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/How-to-calculate-the-ADC-Clock/m-p/540822#M5571</guid>
      <dc:creator>adrianocasimiro</dc:creator>
      <dc:date>2016-07-05T19:47:50Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate the ADC Clock?</title>
      <link>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/How-to-calculate-the-ADC-Clock/m-p/540823#M5572</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, Adriano,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regarding your question about the ADC clock frequency, from hardware perspective, I suggest you should check the following register setting.&lt;/P&gt;&lt;P&gt;1)pls check the ADCx_CFG1[ADICLK], which selects the clock source of ADC.&lt;/P&gt;&lt;P&gt;For K22, I copied the part here:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_0.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/36377i5AF75D67A4F136DC/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_0.png" alt="pastedImage_0.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2)there is divider set up in the ADCx_CFG[ADIV], I copy it here.&lt;/P&gt;&lt;P&gt;Clock Divide Select&lt;/P&gt;&lt;P&gt;Selects the divide ratio used by the ADC to generate the internal clock ADCK.&lt;/P&gt;&lt;P&gt;00 The divide ratio is 1 and the clock rate is input clock.&lt;/P&gt;&lt;P&gt;01 The divide ratio is 2 and the clock rate is (input clock)/2.&lt;/P&gt;&lt;P&gt;10 The divide ratio is 4 and the clock rate is (input clock)/4.&lt;/P&gt;&lt;P&gt;11 The divide ratio is 8 and the clock rate is (input clock)/8.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For your code, I think you select bus clock as ADC clock source with ADICLK bit=00 in binary, the divider is 8 with ADIV bits=11 in binary, the ADC clock frequency is (bus clock)/8. I do not know your bus clock frequency, it is dependent on the MCG mode, and SIM_CLKDIV1 register setting.&lt;/P&gt;&lt;P&gt;Hope it can help you.&lt;/P&gt;&lt;P&gt;B R&lt;/P&gt;&lt;P&gt;Xiangjun Rong&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Jul 2016 05:34:47 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/How-to-calculate-the-ADC-Clock/m-p/540823#M5572</guid>
      <dc:creator>xiangjun_rong</dc:creator>
      <dc:date>2016-07-06T05:34:47Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate the ADC Clock?</title>
      <link>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/How-to-calculate-the-ADC-Clock/m-p/540824#M5573</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi &lt;SPAN style="color: #51626f; font-family: arial, helvetica, 'helvetica neue', verdana, sans-serif; font-size: 14px;"&gt;Xiangjun,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My bus clock is 60 MHz divided for 8, so, my ADC Clock is 7,5 MHz. Now, I want find the conversion time per sample, I have to use this formula&amp;nbsp; (ConversionTime = SFCAdder + AVGNUM x (BCT + LSTAdder + HSCAdder)) ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you very much.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Jul 2016 14:22:38 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/How-to-calculate-the-ADC-Clock/m-p/540824#M5573</guid>
      <dc:creator>adrianocasimiro</dc:creator>
      <dc:date>2016-07-07T14:22:38Z</dc:date>
    </item>
  </channel>
</rss>

