<?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: USB virtual com issue</title>
    <link>https://community.nxp.com/t5/LPC-Microcontrollers/USB-virtual-com-issue/m-p/570223#M18110</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by pra18 on Wed Oct 22 01:51:29 MST 2014&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I finally found that this Unknown Device can also come up if the USB clock configuration and initialisation is not correct and this was the case on my side.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I have corrected the clock initialisation sequence and now it seems to recognise the device and device comes up as a Virtual COM port on Device manager in the PC.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;so my advice to anyone who face this kind of problem is that&amp;nbsp; apart from other things that can cause this problem , doubly make sure that you have intialised and configured the USB clock and PLL properly.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;seems that this unknown device problem is of a multitude scope - right from&amp;nbsp; USB clocking and config not proper and upto any of the problems like things on the PC side, wrong .inf flle and so on .. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks and Regards,&lt;/SPAN&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 15 Jun 2016 18:53:24 GMT</pubDate>
    <dc:creator>lpcware</dc:creator>
    <dc:date>2016-06-15T18:53:24Z</dc:date>
    <item>
      <title>USB virtual com issue</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/USB-virtual-com-issue/m-p/570219#M18106</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by pra18 on Fri Oct 17 05:56:28 MST 2014&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Hi all,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;When I do a single stepping of the CDC VCOM example&amp;nbsp; for LPCOpen 2_12 for ngx 4330 ,I see a USB device not recognised message in my PC and also there is an Unknown driver showing up in the&amp;nbsp; PC's Device manager's&amp;nbsp; USB controllers option&amp;nbsp; and the VID/PID both are shown as 0.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;On the other hand if I remove all breakpointsand run the code, then a LPC USB VCOM COM4 is shown up in ports and LPT option in the Device manager.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;also the VID PID shows up correctly.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Can anyone help and explain why this occurs ? &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;does it occur because there is a delay introduced when stepping ? &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This appears to be the same on my custom board when I try to adapt and integrate this VCOM example into my custom firmware. I see this problem even when the firmware is running continously and there is an unknown device shoing up in the PC and unrecognised device.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Again here, from the time the firmware starts up and the time the USB is initialised , there are many things done for device firmware , and this adds to a delay ( as above case)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;But when I remove the USB cable and connect it back this Unknown driver disappears and appears in the Device manager.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I have also attached my USB initialisation code so anyone can help if i am initilaising my USB1 correctly or not and I am missing some critical step in my USB1 initialisation &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;that might be causing the problem.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks in advance, &lt;/SPAN&gt;&lt;BR /&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-338132"&gt;USBInit.txt.zip&lt;/A&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 18:53:22 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/USB-virtual-com-issue/m-p/570219#M18106</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T18:53:22Z</dc:date>
    </item>
    <item>
      <title>Re: USB virtual com issue</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/USB-virtual-com-issue/m-p/570220#M18107</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by capiman on Fri Oct 17 07:25:03 MST 2014&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Yes, the PC has certain timeouts, when single stepping, the MCU is too slow or not answering on PC's requests.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Even when doing debug prints on an UART, it is sometimes too slow.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Solution could be to create an array, put debug strings into this array (which is fast, must be non-blocking)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;and print out char by char when MCU just has nothing else to do. The reaction time for USB is then &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;not influenced or at least so less, that USB is still running.&lt;/SPAN&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 18:53:23 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/USB-virtual-com-issue/m-p/570220#M18107</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T18:53:23Z</dc:date>
    </item>
    <item>
      <title>Re: USB virtual com issue</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/USB-virtual-com-issue/m-p/570221#M18108</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by NXP_Paul on Fri Oct 17 08:09:59 MST 2014&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Hello&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;The issue is probably caused by single-stepping.&amp;nbsp; When the USB host sends a control transfer, it expects a handshake.&amp;nbsp; If it doesn't receive the handshake, it will retry.&amp;nbsp; The host will typically abandon the transfer after three retries, and the enumeration will fail.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If you have a lot of initialization to do, then you can delay the USB enumeration process until you have completed the microcontroller's&amp;nbsp; initialization.&amp;nbsp; This can be accomplished by waiting for the initialization to complete before the 1.5kOhm pull-up resistor is enabled.&amp;nbsp; Enabling the 1.5k resistors tells the host that a USB device has been plugged into the USB port.&amp;nbsp; If the USB device is plugged in, but the resistor is not enabled, the host will not detect the device.&amp;nbsp; This pull-up is enabled when software sets the RS bit (Bit 0) in the USBCMD register.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;In the LPCOpen code, the connection of the 1.5kOhm resistor is accomplished with the&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;USBD_API-&amp;gt;hw-&amp;gt;Connect(g_hUsb, 1) function.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Paul&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 18:53:23 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/USB-virtual-com-issue/m-p/570221#M18108</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T18:53:23Z</dc:date>
    </item>
    <item>
      <title>Re: USB virtual com issue</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/USB-virtual-com-issue/m-p/570222#M18109</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by pra18 on Fri Oct 17 12:15:26 MST 2014&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Hi, &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Firstly thanks for trying to explain what might be happening in the firmware. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I am doing exactly the same sequence as the example and as you told I am invoking this connect API by the call USBD_API-&amp;gt;hw-&amp;gt;Connect(g_hUsb, 1) just after enabling the interrupts. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;When I run the code without breakpoints , still I observe the unknown device coming&amp;nbsp; in device manager . I have observed that control is going into the ISR and everytime I disconnect the USB cable and reconnect back when firmare is running, upon disconnecting USB cable and reconnecting back , the control goes into the USB ISR and the Unknown device is getting installed into Device manager and gets uninstalled if I remove the cable respectively.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;does it mean that there is too much&amp;nbsp; delay that is&amp;nbsp; interfereing from the point of firmware startup and the time USB is initialised and&amp;nbsp; the connect API&amp;nbsp; is invoked . &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Any workaround for this thing and ovecome this problem?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The VCOM port somehow should show up in the ports and not as an unknown device. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I was first figuring&amp;nbsp; out it could be due to&amp;nbsp; a incorrect .INF file on Host side , I made sure it is not that thing and later I doubted whether USB initialisation is not proper.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks in advance, &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 18:53:24 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/USB-virtual-com-issue/m-p/570222#M18109</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T18:53:24Z</dc:date>
    </item>
    <item>
      <title>Re: USB virtual com issue</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/USB-virtual-com-issue/m-p/570223#M18110</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by pra18 on Wed Oct 22 01:51:29 MST 2014&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I finally found that this Unknown Device can also come up if the USB clock configuration and initialisation is not correct and this was the case on my side.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I have corrected the clock initialisation sequence and now it seems to recognise the device and device comes up as a Virtual COM port on Device manager in the PC.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;so my advice to anyone who face this kind of problem is that&amp;nbsp; apart from other things that can cause this problem , doubly make sure that you have intialised and configured the USB clock and PLL properly.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;seems that this unknown device problem is of a multitude scope - right from&amp;nbsp; USB clocking and config not proper and upto any of the problems like things on the PC side, wrong .inf flle and so on .. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks and Regards,&lt;/SPAN&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 18:53:24 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/USB-virtual-com-issue/m-p/570223#M18110</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T18:53:24Z</dc:date>
    </item>
  </channel>
</rss>

