<?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>LPC MicrocontrollersのトピックRe: CMSIS GPIO driver - potential bug</title>
    <link>https://community.nxp.com/t5/LPC-Microcontrollers/CMSIS-GPIO-driver-potential-bug/m-p/520648#M3750</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by Marc Crandall on Wed Aug 17 13:14:00 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Hi Dave,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If you have a second you should post this bug you found in the bug tracker system they have setup.&amp;nbsp; I've posted a few more there as well.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Marc&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 15 Jun 2016 17:46:19 GMT</pubDate>
    <dc:creator>lpcware</dc:creator>
    <dc:date>2016-06-15T17:46:19Z</dc:date>
    <item>
      <title>CMSIS GPIO driver - potential bug</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/CMSIS-GPIO-driver-potential-bug/m-p/520645#M3747</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by Marc Crandall on Wed Aug 03 14:13:01 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Hello, &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I wanted to let you know about a potential driver problem for the CMSIS GPIO LPC178x_8x. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;In the file "lpc177x_8x_gpio.c" &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I believe this function should be modified as follows. (Note the case 5 addition) &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This took me a very long time to track down - hope this is useful to someone else.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;(Note I sent this message to NXP support as well)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;code&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;static LPC_GPIO_TypeDef *GPIO_GetPointer(uint8_t portNum) &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{ &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;LPC_GPIO_TypeDef *pGPIO = NULL; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;switch (portNum) &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{ &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;case 0: &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;pGPIO = LPC_GPIO0; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;break; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;case 1: &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;pGPIO = LPC_GPIO1; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;break; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;case 2: &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;pGPIO = LPC_GPIO2; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;break; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;case 3: &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;pGPIO = LPC_GPIO3; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;break; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;case 4: &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;pGPIO = LPC_GPIO4; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;break; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;case 5: &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;pGPIO = LPC_GPIO5; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;break; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;default: &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;break; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;} &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;return pGPIO; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;}&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;/code&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 17:46:17 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/CMSIS-GPIO-driver-potential-bug/m-p/520645#M3747</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T17:46:17Z</dc:date>
    </item>
    <item>
      <title>Re: CMSIS GPIO driver - potential bug</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/CMSIS-GPIO-driver-potential-bug/m-p/520646#M3748</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by Dave on Sun Aug 07 22:04:00 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Here's another one to be aware of (I haven't contacted NXP to let them know):&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;File is SYSTEM_LPC177X_8X.C, line 406 reads as follows:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;code&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; if(LPC_SC-&amp;gt;CLKSRCSEL &amp;amp; 0x01)//pll1_clk_in = main_osc&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; USBClock = (OSC_CLK * ((LPC_SC-&amp;gt;PLL1STAT &amp;amp; 0x1F) + 1));&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; else //pll1_clk_in = irc_clk&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; USBClock = (IRC_OSC * ((LPC_SC-&amp;gt;PLL0STAT &amp;amp; 0x1F) + 1));&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;/code&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I believe it should be as follows:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;code&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; USBClock = (OSC_CLK * ((LPC_SC-&amp;gt;PLL1STAT &amp;amp; 0x1F) + 1)) / __USB_DIV;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; else //pll1_clk_in = irc_clk&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; USBClock = (IRC_OSC * ((LPC_SC-&amp;gt;PLL0STAT &amp;amp; 0x1F) + 1)) / __USB_DIV;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;/code&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;where __USB_DIV is defined as follows (up around line 284):&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;code&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;#define __USB_DIV&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; (USBCLKSEL_Val &amp;amp; 0x1F)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;/code&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Hope this helps,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 17:46:17 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/CMSIS-GPIO-driver-potential-bug/m-p/520646#M3748</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T17:46:17Z</dc:date>
    </item>
    <item>
      <title>Re: CMSIS GPIO driver - potential bug</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/CMSIS-GPIO-driver-potential-bug/m-p/520647#M3749</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by wellsk on Mon Aug 08 12:46:20 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt;As an FYI, you can also post these in the bug tracker at &lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="https://community.nxp.com/external-link.jspa?url=http%3A%2F%2Fwww.lpcware.com%2Fnode%2Fadd%2Fct-plus-task" rel="nofollow" target="_blank"&gt;http://www.lpcware.com/node/add/ct-plus-task&lt;/A&gt;&lt;SPAN&gt;. Then they issue can be tracked and you'll know if/when the issue has been fixed.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 17:46:18 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/CMSIS-GPIO-driver-potential-bug/m-p/520647#M3749</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T17:46:18Z</dc:date>
    </item>
    <item>
      <title>Re: CMSIS GPIO driver - potential bug</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/CMSIS-GPIO-driver-potential-bug/m-p/520648#M3750</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by Marc Crandall on Wed Aug 17 13:14:00 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Hi Dave,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If you have a second you should post this bug you found in the bug tracker system they have setup.&amp;nbsp; I've posted a few more there as well.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Marc&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 17:46:19 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/CMSIS-GPIO-driver-potential-bug/m-p/520648#M3750</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T17:46:19Z</dc:date>
    </item>
  </channel>
</rss>

