<?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: ADC clock speed. in LPCXpresso IDE</title>
    <link>https://community.nxp.com/t5/LPCXpresso-IDE/ADC-clock-speed/m-p/550196#M11315</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by NXP_Europe on Wed Aug 29 14:13:46 MST 2012&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Hello micrio,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I think you are right. The value of 4.8MHz is a little out of spec.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;In User Manual UM10398:&lt;/SPAN&gt;&lt;BR /&gt;&lt;HR /&gt;&lt;SPAN style="color: #0000ff;"&gt;&lt;STRONG&gt;Quote: &lt;/STRONG&gt;&lt;BR /&gt;&lt;BR /&gt;[SIZE=1][FONT=Arial][SIZE=1][FONT=Arial][B][FONT=Arial][SIZE=1][COLOR=#005042][FONT=Arial][SIZE=1][COLOR=#005042][FONT=Arial][SIZE=1][COLOR=#005042]Table 363. A/D Control Register (AD0CR - address 0x4001 C000) bit description[/COLOR][/SIZE][/FONT][/COLOR][/SIZE][/FONT][/COLOR][/SIZE][/FONT][/B]&lt;BR /&gt;[LEFT][/FONT][/SIZE][/FONT][/SIZE][SIZE=1][FONT=Arial][SIZE=1][FONT=Arial]15:8 CLKDIV [/FONT][/SIZE][/FONT][/SIZE]&lt;BR /&gt;[SIZE=1][FONT=Arial][SIZE=1][FONT=Arial]The APB clock (PCLK) is divided by CLKDIV +1 to produce the clock for the ADC, which[/FONT][/SIZE][/FONT][/SIZE]&lt;BR /&gt;[SIZE=1][FONT=Arial][SIZE=1][FONT=Arial]should be less than or equal to 4.5 MHz. Typically, software should program the smallest[/FONT][/SIZE][/FONT][/SIZE]&lt;BR /&gt;[SIZE=1][FONT=Arial][SIZE=1][FONT=Arial]value in this field that yields a clock of 4.5 MHz or slightly less, but in certain cases (such[/FONT][/SIZE][/FONT][/SIZE][SIZE=1][FONT=Arial]&lt;BR /&gt;[SIZE=1][FONT=Arial]as a high-impedance analog source) a slower clock may be desirable.[/FONT][/SIZE][/LEFT]&lt;BR /&gt;[/FONT][/SIZE]&lt;/SPAN&gt;&lt;HR /&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Noticed well! We will correct that.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 15 Jun 2016 22:09:40 GMT</pubDate>
    <dc:creator>lpcware</dc:creator>
    <dc:date>2016-06-15T22:09:40Z</dc:date>
    <item>
      <title>ADC clock speed.</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/ADC-clock-speed/m-p/550195#M11314</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by micrio on Mon Aug 27 09:37:17 MST 2012&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;While doing some ADC code I noticed that the CLKDIV seems to be wrong.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;This is for a LPC1114 running at 48 MHz on the internal oscillator.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD bgcolor="#cacaca"&gt; &lt;PRE&gt;
LPC_ADC-&amp;gt;CR = ((SystemCoreClock/LPC_SYSCON-&amp;gt;SYSAHBCLKDIV)/ADC_CLK - 1) &amp;lt;&amp;lt; 8;
&lt;/PRE&gt; &lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;BR /&gt;&lt;SPAN&gt; [SIZE=2]I copied this code from the examples.[/SIZE]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[SIZE=2]This piece of code sets CLKDIV to a value of 9.&amp;nbsp;&amp;nbsp; The actual divisor ends up being 10&amp;nbsp; (9 + 1).&amp;nbsp;&amp;nbsp; [/SIZE]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[SIZE=2]Since [/SIZE][SIZE=2]the system is running at 48 MHz the ADC clock will be 4.8 MHz which exceeds[/SIZE]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[SIZE=2]the spec of 4.5 MHz.&amp;nbsp;&amp;nbsp; Is this correct?&amp;nbsp;&amp;nbsp; Should the CLKDIV actually be 10?[/SIZE]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[SIZE=2]Thanks,[/SIZE]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[SIZE=2]Pete.[/SIZE]&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 22:09:39 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/ADC-clock-speed/m-p/550195#M11314</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T22:09:39Z</dc:date>
    </item>
    <item>
      <title>Re: ADC clock speed.</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/ADC-clock-speed/m-p/550196#M11315</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by NXP_Europe on Wed Aug 29 14:13:46 MST 2012&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Hello micrio,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I think you are right. The value of 4.8MHz is a little out of spec.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;In User Manual UM10398:&lt;/SPAN&gt;&lt;BR /&gt;&lt;HR /&gt;&lt;SPAN style="color: #0000ff;"&gt;&lt;STRONG&gt;Quote: &lt;/STRONG&gt;&lt;BR /&gt;&lt;BR /&gt;[SIZE=1][FONT=Arial][SIZE=1][FONT=Arial][B][FONT=Arial][SIZE=1][COLOR=#005042][FONT=Arial][SIZE=1][COLOR=#005042][FONT=Arial][SIZE=1][COLOR=#005042]Table 363. A/D Control Register (AD0CR - address 0x4001 C000) bit description[/COLOR][/SIZE][/FONT][/COLOR][/SIZE][/FONT][/COLOR][/SIZE][/FONT][/B]&lt;BR /&gt;[LEFT][/FONT][/SIZE][/FONT][/SIZE][SIZE=1][FONT=Arial][SIZE=1][FONT=Arial]15:8 CLKDIV [/FONT][/SIZE][/FONT][/SIZE]&lt;BR /&gt;[SIZE=1][FONT=Arial][SIZE=1][FONT=Arial]The APB clock (PCLK) is divided by CLKDIV +1 to produce the clock for the ADC, which[/FONT][/SIZE][/FONT][/SIZE]&lt;BR /&gt;[SIZE=1][FONT=Arial][SIZE=1][FONT=Arial]should be less than or equal to 4.5 MHz. Typically, software should program the smallest[/FONT][/SIZE][/FONT][/SIZE]&lt;BR /&gt;[SIZE=1][FONT=Arial][SIZE=1][FONT=Arial]value in this field that yields a clock of 4.5 MHz or slightly less, but in certain cases (such[/FONT][/SIZE][/FONT][/SIZE][SIZE=1][FONT=Arial]&lt;BR /&gt;[SIZE=1][FONT=Arial]as a high-impedance analog source) a slower clock may be desirable.[/FONT][/SIZE][/LEFT]&lt;BR /&gt;[/FONT][/SIZE]&lt;/SPAN&gt;&lt;HR /&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Noticed well! We will correct that.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 22:09:40 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/ADC-clock-speed/m-p/550196#M11315</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T22:09:40Z</dc:date>
    </item>
  </channel>
</rss>

