<?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: CPU Clock configuration in Kinetis Design Studio</title>
    <link>https://community.nxp.com/t5/Kinetis-Design-Studio/CPU-Clock-configuration/m-p/314204#M253</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I've confirmed it, the code generated which configures the clocks has problems.&amp;nbsp; If I try to configure for FBE mode operation using an 8MHz crystal, the OSC_CR value it comes up with is 0x0, which is wrong, and the ICS_C1 value it comes up with is 0xC2, which is also wrong.&amp;nbsp; I'll try submitting a bug report, hopefully this will be fixed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edit:&amp;nbsp; I have found specifically what's wrong.&amp;nbsp; The CPU_Config.h that PE comes up with has the wrong values for CPU_ICS_C1_CONFIG_0, CPU_OSC_CR_CONFIG_0.&amp;nbsp; Not just a little wrong, but not even close.&amp;nbsp; Secondly, in CPU_Init.c, the initialization for CPU_ClockConfigDescriptors leaves out the initializer for OSC_CR_Value, so it will never populate the OSC_CR register properly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I try to configure the Kinetis for a 40 MHz core clock, 20 MHz bus clock, 40 MHz&amp;nbsp; running off an 8 MHz external crystal in FEE mode, the correct values should be:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;OSC_CR = 0xB4 (Oscillator enabled, Oscillator enabled in stop mode, Oscillator clock source selected, Oscillator high range enabled, low power mode enabled)&lt;/P&gt;&lt;P&gt;ISC_C1 = 0x18 (FLL output selected as clock source, Reference divider = 256, external reference selected for FLL, Internal reference clock disabled)&lt;/P&gt;&lt;P&gt;ISC_C2 = 0x00 (Divide clock by 1)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I try the same settings in PE, here is what it comes up with;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;OSC_CR = 0x14 ( oscillator disabled,&amp;nbsp; oscillator clock source selected, oscillator high range enabled, low power mode enabled) - note that 0x0 is what actually gets written to OSC_CR.&lt;/P&gt;&lt;P&gt;ISC_C1 = 0x42 (Internal reference selected as clock source, reference divider = 32, external reference selected for FLL, Internal reference clock enabled)&lt;/P&gt;&lt;P&gt;ISC_C2 = 0x0 (divide clock by 1) - correct&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 04 Jun 2014 20:36:37 GMT</pubDate>
    <dc:creator>davidsherman</dc:creator>
    <dc:date>2014-06-04T20:36:37Z</dc:date>
    <item>
      <title>CPU Clock configuration</title>
      <link>https://community.nxp.com/t5/Kinetis-Design-Studio/CPU-Clock-configuration/m-p/314203#M252</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello, I'm trying to configure the clock for a Kinetis MKE06Z128 on the FRDM-KE06 board.&amp;nbsp; I had an MQX-Lite application running using the default internal clock, but when I try to configure for the 8 MHz crystal, it doesn't work and the crystal is not oscillating.&amp;nbsp; Is there a separate component I need to add to control the OSC module?&amp;nbsp; I have these settings in the clock settings for the CPU module:&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;System Oscillator - checked&lt;/P&gt;&lt;P&gt;Clock Frequency - 8 MHz&lt;/P&gt;&lt;P&gt;Oscillator operating mode - low power&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Clock source settings:&lt;/P&gt;&lt;P&gt;ICS mode - FEE&lt;/P&gt;&lt;P&gt;FLL output - 40 MHz (only option)&lt;/P&gt;&lt;P&gt;ICS output clock - 10 MHz (also tried 40 MHz, doesn't work)&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have enabled the SetClockConfiguration method under the CPU component.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Jun 2014 15:16:02 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Design-Studio/CPU-Clock-configuration/m-p/314203#M252</guid>
      <dc:creator>davidsherman</dc:creator>
      <dc:date>2014-06-04T15:16:02Z</dc:date>
    </item>
    <item>
      <title>Re: CPU Clock configuration</title>
      <link>https://community.nxp.com/t5/Kinetis-Design-Studio/CPU-Clock-configuration/m-p/314204#M253</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I've confirmed it, the code generated which configures the clocks has problems.&amp;nbsp; If I try to configure for FBE mode operation using an 8MHz crystal, the OSC_CR value it comes up with is 0x0, which is wrong, and the ICS_C1 value it comes up with is 0xC2, which is also wrong.&amp;nbsp; I'll try submitting a bug report, hopefully this will be fixed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edit:&amp;nbsp; I have found specifically what's wrong.&amp;nbsp; The CPU_Config.h that PE comes up with has the wrong values for CPU_ICS_C1_CONFIG_0, CPU_OSC_CR_CONFIG_0.&amp;nbsp; Not just a little wrong, but not even close.&amp;nbsp; Secondly, in CPU_Init.c, the initialization for CPU_ClockConfigDescriptors leaves out the initializer for OSC_CR_Value, so it will never populate the OSC_CR register properly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I try to configure the Kinetis for a 40 MHz core clock, 20 MHz bus clock, 40 MHz&amp;nbsp; running off an 8 MHz external crystal in FEE mode, the correct values should be:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;OSC_CR = 0xB4 (Oscillator enabled, Oscillator enabled in stop mode, Oscillator clock source selected, Oscillator high range enabled, low power mode enabled)&lt;/P&gt;&lt;P&gt;ISC_C1 = 0x18 (FLL output selected as clock source, Reference divider = 256, external reference selected for FLL, Internal reference clock disabled)&lt;/P&gt;&lt;P&gt;ISC_C2 = 0x00 (Divide clock by 1)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I try the same settings in PE, here is what it comes up with;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;OSC_CR = 0x14 ( oscillator disabled,&amp;nbsp; oscillator clock source selected, oscillator high range enabled, low power mode enabled) - note that 0x0 is what actually gets written to OSC_CR.&lt;/P&gt;&lt;P&gt;ISC_C1 = 0x42 (Internal reference selected as clock source, reference divider = 32, external reference selected for FLL, Internal reference clock enabled)&lt;/P&gt;&lt;P&gt;ISC_C2 = 0x0 (divide clock by 1) - correct&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Jun 2014 20:36:37 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Design-Studio/CPU-Clock-configuration/m-p/314204#M253</guid>
      <dc:creator>davidsherman</dc:creator>
      <dc:date>2014-06-04T20:36:37Z</dc:date>
    </item>
    <item>
      <title>Re: CPU Clock configuration</title>
      <link>https://community.nxp.com/t5/Kinetis-Design-Studio/CPU-Clock-configuration/m-p/314205#M254</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi David,&lt;/P&gt;&lt;P&gt;I have submitted a ticket (ENGR00317168) so hopefully this can be addressed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Erich&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 06 Jun 2014 07:23:49 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Design-Studio/CPU-Clock-configuration/m-p/314205#M254</guid>
      <dc:creator>BlackNight</dc:creator>
      <dc:date>2014-06-06T07:23:49Z</dc:date>
    </item>
    <item>
      <title>Re: CPU Clock configuration</title>
      <link>https://community.nxp.com/t5/Kinetis-Design-Studio/CPU-Clock-configuration/m-p/314206#M255</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Erich, I appreciate it.&amp;nbsp; I have submitted a ticket as well.&amp;nbsp; FYI, CodeWarrior 10.6 has the same problem.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 07 Jun 2014 16:59:15 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Design-Studio/CPU-Clock-configuration/m-p/314206#M255</guid>
      <dc:creator>davidsherman</dc:creator>
      <dc:date>2014-06-07T16:59:15Z</dc:date>
    </item>
    <item>
      <title>Re: CPU Clock configuration</title>
      <link>https://community.nxp.com/t5/Kinetis-Design-Studio/CPU-Clock-configuration/m-p/314207#M256</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;I tried on my CW10.6, found the same issues, the problem is still remaining now. Can you help check whether this problem is fixed. Thanks.&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 24 Oct 2016 02:42:37 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Design-Studio/CPU-Clock-configuration/m-p/314207#M256</guid>
      <dc:creator>ConstYu</dc:creator>
      <dc:date>2016-10-24T02:42:37Z</dc:date>
    </item>
  </channel>
</rss>

