<?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: KE02 GPIO Strange Behavior in Kinetis Microcontrollers</title>
    <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/KE02-GPIO-Strange-Behavior/m-p/711727#M43685</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Jorge&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FGPIOx_PIDR defaults to 0xffffffff, which means that the pin is NOT configured as general purpose input. To use it as input you will need to set the bits to '0'. However, it doesn't look to have any effect on the high leakage that you presently have.&lt;BR /&gt;What happens when you hold the processor in RESET? All pins should then be in high impedance state during and immediately after reset - if you get high leakage it can only be the chip (or other circuitry).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mark&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 23 Sep 2017 22:55:33 GMT</pubDate>
    <dc:creator>mjbcswitzerland</dc:creator>
    <dc:date>2017-09-23T22:55:33Z</dc:date>
    <item>
      <title>KE02 GPIO Strange Behavior</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/KE02-GPIO-Strange-Behavior/m-p/711724#M43682</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello!&lt;/P&gt;&lt;P&gt;I'm fighting a strange behavior in what should be a very simple situation:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;MCU MKE02Z16VLD2;&lt;/LI&gt;&lt;LI&gt;I need to use 2 pins (PTB1, PTB2) alternately as Input and Output;&lt;/LI&gt;&lt;LI&gt;When using them as Inputs, my external drive&amp;nbsp;is very&amp;nbsp;low current, so I rely on the MCU having a very low leakage current. Datasheet say this current is typically 0.1uA, max 1uA;&lt;/LI&gt;&lt;LI&gt;When testing the circuit, the external drive was not capable of driving the MCU pins. Further search showed the port leaking a much higher current - in the order of 100uA;&lt;/LI&gt;&lt;LI&gt;For a test circuit, I connected each pin to a pair of resistors, 33k, to GND and VDD, making in effect a load near 100uA when driven High or Low;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&amp;nbsp;I compiled and ran this test code:&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'andale mono', monospace;"&gt; for (;;)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: 'andale mono', monospace;"&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;{&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: 'andale mono', monospace;"&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;FGPIO_PCOR_REG (portIO) = maskIO2 | maskIO3;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;// IO LO&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: 'andale mono', monospace;"&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;FGPIO_PDDR_REG (portIO) |= (maskIO2 | maskIO3);&amp;nbsp; &amp;nbsp; // IO Output&amp;nbsp;&amp;nbsp;0.008&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: 'andale mono', monospace;"&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;FGPIO_PDDR_REG (portIO) &amp;amp;= ~(maskIO2 | maskIO3);&amp;nbsp;&amp;nbsp;&amp;nbsp;// IO Input&amp;nbsp;&amp;nbsp;&amp;nbsp;0.187&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: 'andale mono', monospace;"&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;FGPIO_PSOR_REG (portIO) = maskIO2 | maskIO3;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;// IO HI&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: 'andale mono', monospace;"&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;FGPIO_PDDR_REG (portIO) |= (maskIO2 | maskIO3);&amp;nbsp; &amp;nbsp; // IO Output&amp;nbsp;&amp;nbsp;3.321&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: 'andale mono', monospace;"&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;FGPIO_PDDR_REG (portIO) &amp;amp;= ~(maskIO2 | maskIO3);&amp;nbsp;&amp;nbsp;&amp;nbsp;// IO Input&amp;nbsp;&amp;nbsp;&amp;nbsp;2.736&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: 'andale mono', monospace;"&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Single stepping through this code, I measured, after each line execution, the voltages shown at the right:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;After driving the pin Low and reverting it to Input, it remains at a very low voltage;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN&gt;After driving the pin High&amp;nbsp;and reverting it to Input, it remains at a very&amp;nbsp;high&amp;nbsp;voltage;&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN&gt;A short circuit to the opposite rail, by means of a current meter, show the current to be around 100uA, also.&lt;/SPAN&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I must say I'm stuck! No idea why this is happening. I would appreciate anyone pointing out where am I busting it!&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 22 Sep 2017 21:41:37 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/KE02-GPIO-Strange-Behavior/m-p/711724#M43682</guid>
      <dc:creator>jorged_avila</dc:creator>
      <dc:date>2017-09-22T21:41:37Z</dc:date>
    </item>
    <item>
      <title>Re: KE02 GPIO Strange Behavior</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/KE02-GPIO-Strange-Behavior/m-p/711725#M43683</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Jorge&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try setting the corresponding bits in FGPIOx_PIDR to '0'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mark&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jive-link-external-small" href="https://community.nxp.com/external-link.jspa?url=http%3A%2F%2Fwww.utasker.com%2Fkinetis.html" rel="nofollow" target="_blank"&gt;http://www.utasker.com/kinetis.html&lt;/A&gt;&lt;BR /&gt;&lt;A class="jive-link-external-small" href="https://community.nxp.com/external-link.jspa?url=http%3A%2F%2Fwww.utasker.com%2Fkinetis%2FFRDM-KE02Z.html" rel="nofollow" target="_blank"&gt;http://www.utasker.com/kinetis/FRDM-KE02Z.html&lt;/A&gt;&lt;BR /&gt;&lt;A class="jive-link-external-small" href="https://community.nxp.com/external-link.jspa?url=http%3A%2F%2Fwww.utasker.com%2Fkinetis%2FFRDM-KE02Z40M.html" rel="nofollow" target="_blank"&gt;http://www.utasker.com/kinetis/FRDM-KE02Z40M.html&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 22 Sep 2017 23:07:03 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/KE02-GPIO-Strange-Behavior/m-p/711725#M43683</guid>
      <dc:creator>mjbcswitzerland</dc:creator>
      <dc:date>2017-09-22T23:07:03Z</dc:date>
    </item>
    <item>
      <title>Re: KE02 GPIO Strange Behavior</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/KE02-GPIO-Strange-Behavior/m-p/711726#M43684</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;No results... :-(&lt;/P&gt;&lt;P&gt;Anyway I'd need the input function enabled.&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 23 Sep 2017 13:01:47 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/KE02-GPIO-Strange-Behavior/m-p/711726#M43684</guid>
      <dc:creator>jorged_avila</dc:creator>
      <dc:date>2017-09-23T13:01:47Z</dc:date>
    </item>
    <item>
      <title>Re: KE02 GPIO Strange Behavior</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/KE02-GPIO-Strange-Behavior/m-p/711727#M43685</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Jorge&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FGPIOx_PIDR defaults to 0xffffffff, which means that the pin is NOT configured as general purpose input. To use it as input you will need to set the bits to '0'. However, it doesn't look to have any effect on the high leakage that you presently have.&lt;BR /&gt;What happens when you hold the processor in RESET? All pins should then be in high impedance state during and immediately after reset - if you get high leakage it can only be the chip (or other circuitry).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mark&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 23 Sep 2017 22:55:33 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/KE02-GPIO-Strange-Behavior/m-p/711727#M43685</guid>
      <dc:creator>mjbcswitzerland</dc:creator>
      <dc:date>2017-09-23T22:55:33Z</dc:date>
    </item>
  </channel>
</rss>

