<?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: Using the MKL17Z256VLH4 processor.  Can you switch from the internal clock to an external clock and then back? in Kinetis Microcontrollers</title>
    <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-the-MKL17Z256VLH4-processor-Can-you-switch-from-the/m-p/483601#M29628</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;OK, I figured the problem out.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the code from Keil the “when loop” is looking for which clock is&lt;/P&gt;&lt;P&gt;selected.  When I change the when loop to look to at the “OSX clock is&lt;/P&gt;&lt;P&gt;ready” bit, every thing works.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;From:&lt;/STRONG&gt; jeremyzhou &lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Sent:&lt;/STRONG&gt; Wednesday, May 25, 2016 9:52 PM&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;To:&lt;/STRONG&gt; George Weatherford&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Subject:&lt;/STRONG&gt; Re:  - Using the MKL17Z256VLH4&lt;/P&gt;&lt;P&gt;processor.  Can you switch from the internal clock to an external clock and&lt;/P&gt;&lt;P&gt;then back?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;NXP Community&lt;/P&gt;&lt;P&gt;&amp;lt;https://community.freescale.com/resources/statics/1000/35400-NXP-Community-Email-banner-600x75.jpg&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Using the MKL17Z256VLH4 processor.  Can you switch from the internal clock&lt;/P&gt;&lt;P&gt;to an external clock and then back?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;reply from jeremyzhou&lt;/P&gt;&lt;P&gt;&amp;lt;https://community.nxp.com/people/jeremyzhou?et=watches.email.thread&amp;gt;&lt;/P&gt;&lt;P&gt;in *Kinetis&lt;/P&gt;&lt;P&gt;Microcontrollers* - View the full discussion&lt;/P&gt;&lt;P&gt;&amp;lt;https://community.nxp.com/message/654472?et=watches.email.thread#comment-654472&amp;gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 26 May 2016 14:45:34 GMT</pubDate>
    <dc:creator>georgeweatherfo</dc:creator>
    <dc:date>2016-05-26T14:45:34Z</dc:date>
    <item>
      <title>Using the MKL17Z256VLH4 processor.  Can you switch from the internal clock to an external clock and then back?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-the-MKL17Z256VLH4-processor-Can-you-switch-from-the/m-p/483593#M29620</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;When the processor boots, it is using the internal clock.&amp;nbsp; After a while an external oscillator is turned on and the processor switches to using that.&amp;nbsp; When the app is finished for the day, it switches back to the internal clock.&amp;nbsp; When trying to switch the command "MCG-&amp;gt;SC = 0x02;"&amp;nbsp; When this is performed, the processor goes off into the weeds (starts executing in an invalid memory space (0x4004XXXX).&amp;nbsp; I use the same code when booting up and when switching back to the internal clock.&lt;/P&gt;&lt;P&gt;Can the processor switch from the internal clock to the external clock and back?&amp;nbsp; If so, how?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you for any assistance,&lt;/P&gt;&lt;P&gt;George Weatherford&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 18 May 2016 13:30:57 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-the-MKL17Z256VLH4-processor-Can-you-switch-from-the/m-p/483593#M29620</guid>
      <dc:creator>georgeweatherfo</dc:creator>
      <dc:date>2016-05-18T13:30:57Z</dc:date>
    </item>
    <item>
      <title>Re: Using the MKL17Z256VLH4 processor.  Can you switch from the internal clock to an external clock and then back?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-the-MKL17Z256VLH4-processor-Can-you-switch-from-the/m-p/483594#M29621</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi George,&lt;/P&gt;&lt;P&gt;Before answer your question, I was wondering if you can share the code that transits the MCG_Lite to the LIRC mode or HIRC mode from the EXT mode.&lt;/P&gt;&lt;P&gt;Then I can investigate the code to find out the root cause.&lt;/P&gt;&lt;P&gt;I'm looking forward to your reply.&lt;BR /&gt;Have a great day,&lt;BR /&gt;Ping&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-----------------------------------------------------------------------------------------------------------------------&lt;BR /&gt;Note: If this post answers your question, please click the Correct Answer button. Thank you!&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 19 May 2016 07:09:17 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-the-MKL17Z256VLH4-processor-Can-you-switch-from-the/m-p/483594#M29621</guid>
      <dc:creator>jeremyzhou</dc:creator>
      <dc:date>2016-05-19T07:09:17Z</dc:date>
    </item>
    <item>
      <title>Re: Using the MKL17Z256VLH4 processor.  Can you switch from the internal clock to an external clock and then back?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-the-MKL17Z256VLH4-processor-Can-you-switch-from-the/m-p/483595#M29622</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Here is the code use to go from internal clock source to external clock&lt;/P&gt;&lt;P&gt;source (set_ext_clk) and from external clock source to internal clock&lt;/P&gt;&lt;P&gt;source (set_int_clk).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you for you assistance,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;George&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;From:&lt;/STRONG&gt; jeremyzhou &lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Sent:&lt;/STRONG&gt; Thursday, May 19, 2016 2:10 AM&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;To:&lt;/STRONG&gt; George Weatherford&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Subject:&lt;/STRONG&gt; Re:  - Using the MKL17Z256VLH4&lt;/P&gt;&lt;P&gt;processor.  Can you switch from the internal clock to an external clock and&lt;/P&gt;&lt;P&gt;then back?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;NXP Community&lt;/P&gt;&lt;P&gt;&amp;lt;https://community.freescale.com/resources/statics/1000/35400-NXP-Community-Email-banner-600x75.jpg&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Using the MKL17Z256VLH4 processor.  Can you switch from the internal clock&lt;/P&gt;&lt;P&gt;to an external clock and then back?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;reply from jeremyzhou&lt;/P&gt;&lt;P&gt;&amp;lt;https://community.freescale.com/people/jeremyzhou?et=watches.email.thread&amp;gt;&lt;/P&gt;&lt;P&gt;in &lt;STRONG&gt;Kinetis Microcontrollers&lt;/STRONG&gt; - View the full discussion&lt;/P&gt;&lt;P&gt;&amp;lt;https://community.freescale.com/message/652058?et=watches.email.thread#comment-652058&amp;gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 19 May 2016 12:17:16 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-the-MKL17Z256VLH4-processor-Can-you-switch-from-the/m-p/483595#M29622</guid>
      <dc:creator>georgeweatherfo</dc:creator>
      <dc:date>2016-05-19T12:17:16Z</dc:date>
    </item>
    <item>
      <title>Re: Using the MKL17Z256VLH4 processor.  Can you switch from the internal clock to an external clock and then back?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-the-MKL17Z256VLH4-processor-Can-you-switch-from-the/m-p/483596#M29623</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi George,&lt;/P&gt;&lt;P&gt;Please give a shot again with the modified code.&lt;/P&gt;&lt;PRE __default_attr="c#" __jive_macro_name="code" class="jive_macro_code _jivemacro_uid_14637275241883038 jive_text_macro" data-renderedposition="60_8_1192_240" jivemacro_uid="_14637275241883038" modifiedtitle="true"&gt;&lt;P&gt;//Sets internal clock source&lt;/P&gt;&lt;P&gt;void set_int_clk(void)&lt;/P&gt;&lt;P&gt;{&lt;/P&gt;&lt;P&gt;&amp;nbsp; //SIM-&amp;gt;COPC = (uint32_t)0x00u;&lt;/P&gt;&lt;P&gt;&amp;nbsp; //SIM-&amp;gt;SOPT2 &amp;amp;= ~SIM_SOPT2_USBSRC_MASK; /* USB_CLKIN is clock source for USB FS&amp;nbsp; (applicable only for derivatived with USB)*/&lt;/P&gt;&lt;P&gt;&amp;nbsp; //SIM-&amp;gt;CLKDIV1 = SIM_CLKDIV1_OUTDIV1(0x00) |&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // SIM_CLKDIV1_OUTDIV4(0x01); /* Update system prescalers */&lt;/P&gt;&lt;P&gt; // OSC0-&amp;gt;CR = (uint32_t)0x00u;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* Disable External reference */&lt;/P&gt;&lt;P&gt;&amp;nbsp; MCG-&amp;gt;C2 |= MCG_C2_IRCS_MASK;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* Enable LIRC 8MHz */&lt;/P&gt;&lt;P&gt;&amp;nbsp; MCG-&amp;gt;C1 |=MCG_C1_IRCLKEN_MASK;&lt;/P&gt;&lt;P&gt;&amp;nbsp; MCG-&amp;gt;SC |=MCG_SC_FCRDIV(0x00);&lt;/P&gt;&lt;P&gt;&amp;nbsp; MCG-&amp;gt;C1 |=MCG_C1_IRCLKEN_MASK;&lt;/P&gt;&lt;P&gt;&amp;nbsp; while((MCG-&amp;gt;S &amp;amp; MCG_S_CLKST_MASK) != 0x04u) {} /* Check that the clock source is the LIRC clock. */&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;/PRE&gt;&lt;P&gt;&lt;BR /&gt;Have a great day,&lt;BR /&gt;Ping&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-----------------------------------------------------------------------------------------------------------------------&lt;BR /&gt;Note: If this post answers your question, please click the Correct Answer button. Thank you!&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 May 2016 06:58:58 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-the-MKL17Z256VLH4-processor-Can-you-switch-from-the/m-p/483596#M29623</guid>
      <dc:creator>jeremyzhou</dc:creator>
      <dc:date>2016-05-20T06:58:58Z</dc:date>
    </item>
    <item>
      <title>Re: Using the MKL17Z256VLH4 processor.  Can you switch from the internal clock to an external clock and then back?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-the-MKL17Z256VLH4-processor-Can-you-switch-from-the/m-p/483597#M29624</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sorry, I didn’t get back to you sooner.  I was out of the office Friday.&lt;/P&gt;&lt;P&gt;Anyway, I put your code in and it does not work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The code hangs at:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;while((MCG-&amp;gt;S &amp;amp; MCG_S_CLKST_MASK) != 0x04u) {} /* Check that the clock&lt;/P&gt;&lt;P&gt;source is the LIRC clock. */&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your  help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;George&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;From:&lt;/STRONG&gt; jeremyzhou &lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Sent:&lt;/STRONG&gt; Friday, May 20, 2016 2:00 AM&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;To:&lt;/STRONG&gt; George Weatherford&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Subject:&lt;/STRONG&gt; Re:  - Using the MKL17Z256VLH4&lt;/P&gt;&lt;P&gt;processor.  Can you switch from the internal clock to an external clock and&lt;/P&gt;&lt;P&gt;then back?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;NXP Community&lt;/P&gt;&lt;P&gt;&amp;lt;https://community.freescale.com/resources/statics/1000/35400-NXP-Community-Email-banner-600x75.jpg&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Using the MKL17Z256VLH4 processor.  Can you switch from the internal clock&lt;/P&gt;&lt;P&gt;to an external clock and then back?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;reply from jeremyzhou&lt;/P&gt;&lt;P&gt;&amp;lt;https://community.freescale.com/people/jeremyzhou?et=watches.email.thread&amp;gt;&lt;/P&gt;&lt;P&gt;in &lt;STRONG&gt;Kinetis Microcontrollers&lt;/STRONG&gt; - View the full discussion&lt;/P&gt;&lt;P&gt;&amp;lt;https://community.freescale.com/message/652506?et=watches.email.thread#comment-652506&amp;gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 May 2016 21:11:25 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-the-MKL17Z256VLH4-processor-Can-you-switch-from-the/m-p/483597#M29624</guid>
      <dc:creator>georgeweatherfo</dc:creator>
      <dc:date>2016-05-23T21:11:25Z</dc:date>
    </item>
    <item>
      <title>Re: Using the MKL17Z256VLH4 processor.  Can you switch from the internal clock to an external clock and then back?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-the-MKL17Z256VLH4-processor-Can-you-switch-from-the/m-p/483598#M29625</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi George,&lt;/P&gt;&lt;P&gt;I've adjusted the code again, then it works on the FRDM-KL27 board.&lt;/P&gt;&lt;PRE __default_attr="c++" __jive_macro_name="code" class="_jivemacro_uid_1464079329069518 jive_macro_code jive_text_macro" data-renderedposition="60_8_1192_352" jivemacro_uid="_1464079329069518" modifiedtitle="true"&gt;&lt;P&gt;void CLOCK_SetExtMode(void)&lt;/P&gt;&lt;P&gt;{&lt;/P&gt;&lt;P&gt; // enable OSC&lt;/P&gt;&lt;P&gt;&amp;nbsp; SIM_SCGC5 |= SIM_SCGC5_PORTA_MASK;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp; PORTA_PCR18 &amp;amp;= (uint32_t)~(uint32_t)((PORT_PCR_ISF_MASK | PORT_PCR_MUX(0x07)));&lt;/P&gt;&lt;P&gt;&amp;nbsp; PORTA_PCR19 &amp;amp;= (uint32_t)~(uint32_t)((PORT_PCR_ISF_MASK | PORT_PCR_MUX(0x07)));&lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp; MCG-&amp;gt;C2 |= MCG_C2_EREFS0_MASK;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* Enable LIRC 8MHz */&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp; MCG-&amp;gt;C1 |=MCG_C1_IRCLKEN_MASK;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp; MCG-&amp;gt;SC |=MCG_SC_FCRDIV(0x00);&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp; if (((MCG_C2) &amp;amp; MCG_C2_EREFS0_MASK) != 0U) {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; while((MCG-&amp;gt;S &amp;amp; MCG_S_OSCINIT0_MASK) == 0x00U) { /* Check that the oscillator is running */&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; MCG-&amp;gt;C1 |=MCG_C1_CLKS(0x02);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; while((MCG-&amp;gt;S &amp;amp; MCG_S_CLKST_MASK) != 0x08U) { /* Wait until external reference clock is selected as MCG_Lite output */&lt;/P&gt;&lt;P&gt;&amp;nbsp; }&lt;/P&gt; }&lt;/PRE&gt;&lt;P&gt;&lt;BR /&gt;Have a great day,&lt;BR /&gt;Ping&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-----------------------------------------------------------------------------------------------------------------------&lt;BR /&gt;Note: If this post answers your question, please click the Correct Answer button. Thank you!&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 24 May 2016 08:43:27 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-the-MKL17Z256VLH4-processor-Can-you-switch-from-the/m-p/483598#M29625</guid>
      <dc:creator>jeremyzhou</dc:creator>
      <dc:date>2016-05-24T08:43:27Z</dc:date>
    </item>
    <item>
      <title>Re: Using the MKL17Z256VLH4 processor.  Can you switch from the internal clock to an external clock and then back?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-the-MKL17Z256VLH4-processor-Can-you-switch-from-the/m-p/483599#M29626</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you for your code Jeremy,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This code appears to be to switch to the external clock.  The code I have&lt;/P&gt;&lt;P&gt;seems to be doing that ok now.  We are trying to switch back from external&lt;/P&gt;&lt;P&gt;clock to internal clock.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do you have anything on that?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you again,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;George&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;From:&lt;/STRONG&gt; jeremyzhou &lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Sent:&lt;/STRONG&gt; Tuesday, May 24, 2016 3:44 AM&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;To:&lt;/STRONG&gt; George Weatherford&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Subject:&lt;/STRONG&gt; Re:  - Using the MKL17Z256VLH4&lt;/P&gt;&lt;P&gt;processor.  Can you switch from the internal clock to an external clock and&lt;/P&gt;&lt;P&gt;then back?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;NXP Community&lt;/P&gt;&lt;P&gt;&amp;lt;https://community.freescale.com/resources/statics/1000/35400-NXP-Community-Email-banner-600x75.jpg&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Using the MKL17Z256VLH4 processor.  Can you switch from the internal clock&lt;/P&gt;&lt;P&gt;to an external clock and then back?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;reply from jeremyzhou&lt;/P&gt;&lt;P&gt;&amp;lt;https://community.freescale.com/people/jeremyzhou?et=watches.email.thread&amp;gt;&lt;/P&gt;&lt;P&gt;in &lt;STRONG&gt;Kinetis Microcontrollers&lt;/STRONG&gt; - View the full discussion&lt;/P&gt;&lt;P&gt;&amp;lt;https://community.freescale.com/message/653488?et=watches.email.thread#comment-653488&amp;gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 24 May 2016 12:07:51 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-the-MKL17Z256VLH4-processor-Can-you-switch-from-the/m-p/483599#M29626</guid>
      <dc:creator>georgeweatherfo</dc:creator>
      <dc:date>2016-05-24T12:07:51Z</dc:date>
    </item>
    <item>
      <title>Re: Using the MKL17Z256VLH4 processor.  Can you switch from the internal clock to an external clock and then back?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-the-MKL17Z256VLH4-processor-Can-you-switch-from-the/m-p/483600#M29627</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi George,&lt;/P&gt;&lt;P&gt;For instance, the following code will illustrate the procedure of switching to the HIRC mode.&lt;/P&gt;&lt;PRE __default_attr="c++" __jive_macro_name="code" class="jive_macro_code _jivemacro_uid_14642310223617109 jive_text_macro" data-renderedposition="86_8_1192_144" jivemacro_uid="_14642310223617109" modifiedtitle="true"&gt;&lt;P&gt;void CLOCK_HAL_SetHircMode(void)&lt;/P&gt;&lt;P&gt;{&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; MCG-&amp;gt;MC |= MCG_C2_HIRCEN_MASK;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; MCG-&amp;gt;C1 =MCG_C1_CLKS(0x0);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; while((MCG-&amp;gt;S &amp;amp; MCG_S_CLKST_MASK) != 0x00U) { &lt;/P&gt;&lt;P&gt;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; /* Enable the IRC source*/&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; MCG_C1 |= MCG_C1_IRCLKEN_MASK;&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;/PRE&gt;&lt;P&gt;Have a great day,&lt;/P&gt;&lt;P&gt;Ping&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-----------------------------------------------------------------------------------------------------------------------&lt;BR /&gt;Note: If this post answers your question, please click the Correct Answer button. Thank you!&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 26 May 2016 02:50:44 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-the-MKL17Z256VLH4-processor-Can-you-switch-from-the/m-p/483600#M29627</guid>
      <dc:creator>jeremyzhou</dc:creator>
      <dc:date>2016-05-26T02:50:44Z</dc:date>
    </item>
    <item>
      <title>Re: Using the MKL17Z256VLH4 processor.  Can you switch from the internal clock to an external clock and then back?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-the-MKL17Z256VLH4-processor-Can-you-switch-from-the/m-p/483601#M29628</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;OK, I figured the problem out.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the code from Keil the “when loop” is looking for which clock is&lt;/P&gt;&lt;P&gt;selected.  When I change the when loop to look to at the “OSX clock is&lt;/P&gt;&lt;P&gt;ready” bit, every thing works.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;From:&lt;/STRONG&gt; jeremyzhou &lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Sent:&lt;/STRONG&gt; Wednesday, May 25, 2016 9:52 PM&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;To:&lt;/STRONG&gt; George Weatherford&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Subject:&lt;/STRONG&gt; Re:  - Using the MKL17Z256VLH4&lt;/P&gt;&lt;P&gt;processor.  Can you switch from the internal clock to an external clock and&lt;/P&gt;&lt;P&gt;then back?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;NXP Community&lt;/P&gt;&lt;P&gt;&amp;lt;https://community.freescale.com/resources/statics/1000/35400-NXP-Community-Email-banner-600x75.jpg&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Using the MKL17Z256VLH4 processor.  Can you switch from the internal clock&lt;/P&gt;&lt;P&gt;to an external clock and then back?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;reply from jeremyzhou&lt;/P&gt;&lt;P&gt;&amp;lt;https://community.nxp.com/people/jeremyzhou?et=watches.email.thread&amp;gt;&lt;/P&gt;&lt;P&gt;in *Kinetis&lt;/P&gt;&lt;P&gt;Microcontrollers* - View the full discussion&lt;/P&gt;&lt;P&gt;&amp;lt;https://community.nxp.com/message/654472?et=watches.email.thread#comment-654472&amp;gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 26 May 2016 14:45:34 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Using-the-MKL17Z256VLH4-processor-Can-you-switch-from-the/m-p/483601#M29628</guid>
      <dc:creator>georgeweatherfo</dc:creator>
      <dc:date>2016-05-26T14:45:34Z</dc:date>
    </item>
  </channel>
</rss>

