<?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 bug in lpc17xx hal nxpusblib in LPC Microcontrollers</title>
    <link>https://community.nxp.com/t5/LPC-Microcontrollers/bug-in-lpc17xx-hal-nxpusblib/m-p/522795#M5431</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by bthomas on Thu Jan 26 14:02:33 MST 2012&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Just a small bug report. I experienced today a microcontroller (LPC1764) blocking on HAL17XX_USBInit(). See the following lines:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;LPC_USB-&amp;gt;USBClkCtrl = 0x12;&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;&amp;nbsp;&amp;nbsp; /* Dev, PortSel, AHB clock enable */&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;while ((LPC_USB-&amp;gt;USBClkSt &amp;amp; 0x12) != 0x12);&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Values 0x12 are 0x1A in the distribution. I changed them to 0x12 because bit 3 in both registers should not be written and may be unpredicatable when read. I had never seen this blocking behaviour before on other devices so my first intuition was that there must have been a hardware problem. However, investigating this further revealed this problem and changing it as described above solved the problem.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Hope this helps someone.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Bert&lt;/SPAN&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 15 Jun 2016 17:58:03 GMT</pubDate>
    <dc:creator>lpcware</dc:creator>
    <dc:date>2016-06-15T17:58:03Z</dc:date>
    <item>
      <title>bug in lpc17xx hal nxpusblib</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/bug-in-lpc17xx-hal-nxpusblib/m-p/522795#M5431</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by bthomas on Thu Jan 26 14:02:33 MST 2012&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Just a small bug report. I experienced today a microcontroller (LPC1764) blocking on HAL17XX_USBInit(). See the following lines:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;LPC_USB-&amp;gt;USBClkCtrl = 0x12;&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;&amp;nbsp;&amp;nbsp; /* Dev, PortSel, AHB clock enable */&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;while ((LPC_USB-&amp;gt;USBClkSt &amp;amp; 0x12) != 0x12);&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Values 0x12 are 0x1A in the distribution. I changed them to 0x12 because bit 3 in both registers should not be written and may be unpredicatable when read. I had never seen this blocking behaviour before on other devices so my first intuition was that there must have been a hardware problem. However, investigating this further revealed this problem and changing it as described above solved the problem.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Hope this helps someone.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Bert&lt;/SPAN&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 17:58:03 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/bug-in-lpc17xx-hal-nxpusblib/m-p/522795#M5431</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T17:58:03Z</dc:date>
    </item>
    <item>
      <title>Re: bug in lpc17xx hal nxpusblib</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/bug-in-lpc17xx-hal-nxpusblib/m-p/522796#M5432</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Discovered the same issue today. For me, it only works this way:&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 14px; font-family: arial, helvetica, 'helvetica neue', verdana, sans-serif; color: #51626f;"&gt;LPC_USB-&amp;gt;USBClkCtrl = 0x1A;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 14px; font-family: arial, helvetica, 'helvetica neue', verdana, sans-serif; color: #51626f;"&gt;while ((LPC_USB-&amp;gt;USBClkSt &amp;amp; 0x12) != 0x12);&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 18 Aug 2016 13:17:29 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/bug-in-lpc17xx-hal-nxpusblib/m-p/522796#M5432</guid>
      <dc:creator>janblumenkamp</dc:creator>
      <dc:date>2016-08-18T13:17:29Z</dc:date>
    </item>
  </channel>
</rss>

