<?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>Kinetis MicrocontrollersのトピックFRDM-KL25Z I2C0 doesn't Work</title>
    <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/FRDM-KL25Z-I2C0-doesn-t-Work/m-p/458156#M27344</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hii all,&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am working on frdm-kl25z EVM and i need I2C0 communication protocol for my task.&lt;/P&gt;&lt;P&gt;I need to communicate with CAT24M01 EEPROM which is I2C based using KEIL IDE. &lt;/P&gt;&lt;P&gt;I used PORTB0 - SCL and PORTB1 - SDA line for my task.&lt;/P&gt;&lt;P&gt;EEPROM has been configured with 4.7k Pull-Up at Vcc side .(I also tried 10k and 1k)&lt;/P&gt;&lt;P&gt;I have configured I2C to work with 100Khz then i tried 400Khz and 1Mhz , my clock freq. is 24 Mhz .&lt;/P&gt;&lt;P&gt;i configured I2Cx_F register to get above baud rate as following.&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I2C_F = 0X1E // For 100 Khz &lt;/P&gt;&lt;P&gt;I2C_F = 0x0E // For 400Khz&lt;/P&gt;&lt;P&gt;I2C_F = 0X02 // For 1Mhz respectively.&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Now my problem is as below,&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I observed following results in my implementation.&lt;/P&gt;&lt;P&gt;1) Sometime it works and writes one byte properly.&lt;/P&gt;&lt;P&gt;2) Sometime it works only after unplugging the power cable of FRDM-KL25Z.&lt;/P&gt;&lt;P&gt;3) Sometime it gets stuck into the getting acknowledgement phase in which i m polling for IICIF flag from I2C_S to be reset (0 value) (The brief is given into code).&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I measured the voltages at pin MCU side and EEPROM side and i got 3.3V .&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;the brief code is attached here. &lt;/P&gt;&lt;P&gt;Please go through it.&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any help on this would be great appreciable.&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards,&lt;/P&gt;&lt;P&gt;Rutvij.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Original Attachment has been moved to: &lt;A _jive_internal="true" href="https://community.nxp.com/docs/DOC-337677"&gt;I2C_sample.c.zip&lt;/A&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 22 Aug 2015 09:59:11 GMT</pubDate>
    <dc:creator>rutvijtrivedi</dc:creator>
    <dc:date>2015-08-22T09:59:11Z</dc:date>
    <item>
      <title>FRDM-KL25Z I2C0 doesn't Work</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/FRDM-KL25Z-I2C0-doesn-t-Work/m-p/458156#M27344</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hii all,&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am working on frdm-kl25z EVM and i need I2C0 communication protocol for my task.&lt;/P&gt;&lt;P&gt;I need to communicate with CAT24M01 EEPROM which is I2C based using KEIL IDE. &lt;/P&gt;&lt;P&gt;I used PORTB0 - SCL and PORTB1 - SDA line for my task.&lt;/P&gt;&lt;P&gt;EEPROM has been configured with 4.7k Pull-Up at Vcc side .(I also tried 10k and 1k)&lt;/P&gt;&lt;P&gt;I have configured I2C to work with 100Khz then i tried 400Khz and 1Mhz , my clock freq. is 24 Mhz .&lt;/P&gt;&lt;P&gt;i configured I2Cx_F register to get above baud rate as following.&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I2C_F = 0X1E // For 100 Khz &lt;/P&gt;&lt;P&gt;I2C_F = 0x0E // For 400Khz&lt;/P&gt;&lt;P&gt;I2C_F = 0X02 // For 1Mhz respectively.&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Now my problem is as below,&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I observed following results in my implementation.&lt;/P&gt;&lt;P&gt;1) Sometime it works and writes one byte properly.&lt;/P&gt;&lt;P&gt;2) Sometime it works only after unplugging the power cable of FRDM-KL25Z.&lt;/P&gt;&lt;P&gt;3) Sometime it gets stuck into the getting acknowledgement phase in which i m polling for IICIF flag from I2C_S to be reset (0 value) (The brief is given into code).&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I measured the voltages at pin MCU side and EEPROM side and i got 3.3V .&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;the brief code is attached here. &lt;/P&gt;&lt;P&gt;Please go through it.&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any help on this would be great appreciable.&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards,&lt;/P&gt;&lt;P&gt;Rutvij.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Original Attachment has been moved to: &lt;A _jive_internal="true" href="https://community.nxp.com/docs/DOC-337677"&gt;I2C_sample.c.zip&lt;/A&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 22 Aug 2015 09:59:11 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/FRDM-KL25Z-I2C0-doesn-t-Work/m-p/458156#M27344</guid>
      <dc:creator>rutvijtrivedi</dc:creator>
      <dc:date>2015-08-22T09:59:11Z</dc:date>
    </item>
    <item>
      <title>Re: FRDM-KL25Z I2C0 doesn't Work</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/FRDM-KL25Z-I2C0-doesn-t-Work/m-p/458157#M27345</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Rutvij:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I checked your code and it seems OK to me, except for the Pause() calls. EEPROM memories have a write cycle time and it seems that you are not providing enough time for it to finish the write process before sending a new command.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try increasing the pause between write and read.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If this does not work, then it would be useful if you have a scope or logic analyzer to inspect what is going on in the I2C bus. That is the easiest way to debug I2C problems.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Regards!,&lt;BR /&gt;Jorge Gonzalez&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, 25 Aug 2015 22:11:19 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/FRDM-KL25Z-I2C0-doesn-t-Work/m-p/458157#M27345</guid>
      <dc:creator>Jorge_Gonzalez</dc:creator>
      <dc:date>2015-08-25T22:11:19Z</dc:date>
    </item>
  </channel>
</rss>

