<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>asyndetic.com &#187; uart</title>
	<atom:link href="http://www.asyndetic.com/blog/tag/uart/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.asyndetic.com/blog</link>
	<description></description>
	<lastBuildDate>Tue, 17 Jan 2012 06:49:42 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	
		<item>
		<title>FTDI USB Serial Port Enumeration on Windows</title>
		<link>http://www.asyndetic.com/blog/2010/04/11/ftdi-usb-serial-port-enumeration-on-windows/</link>
		<comments>http://www.asyndetic.com/blog/2010/04/11/ftdi-usb-serial-port-enumeration-on-windows/#comments</comments>
		<pubDate>Mon, 12 Apr 2010 01:10:56 +0000</pubDate>
		<dc:creator>Dan Savilonis</dc:creator>
				<category><![CDATA[troubleshooting]]></category>
		<category><![CDATA[ftdi]]></category>
		<category><![CDATA[serial]]></category>
		<category><![CDATA[uart]]></category>
		<category><![CDATA[usb]]></category>
		<category><![CDATA[windows]]></category>

		<guid isPermaLink="false">http://asyndetic.com/blog/?p=56</guid>
		<description><![CDATA[FTDI is one of the two major manufacturers of USB UART chips, and they provide regularly updated and reliable drivers. Most devices I&#8217;ve used don&#8217;t bother to implement a custom VID/PID, so you can just use the drivers directly from FTDI. When you connect a large number of USB serial ports, it is often difficult to determine [...]]]></description>
			<content:encoded><![CDATA[<p>FTDI is one of the two major manufacturers of USB UART chips, and they provide regularly updated and reliable drivers. Most devices I&#8217;ve used don&#8217;t bother to implement a custom VID/PID, so you can just use the drivers directly from FTDI.</p>
<p>When you connect a large number of USB serial ports, it is often difficult to determine which port belongs to which physical connector, so FTDI has implemented a mechanism that persists COM port enumeration on Windows. The mechanism works by uniquely identifying a port based on the serial number stored in an eeprom associated with the device. Unfortunately, it turns out to be <strong>really</strong> persistent and I spent half a day trying to unpersist the mapping after I plugged in a second device to test it. The result was my COM port which I wante to be COM3 &#8211; COM11 became COM21-COM29. While there&#8217;s nothing really wrong with this, I wanted the lower ports back.</p>
<h2>FTDI Workaround for a Single Device</h2>
<p>FTDI presents a workaround in the App Note <a href="http://www.ftdichip.com/Documents/AppNotes/AN_107_AdvancedDriverOptions_AN_000073.pdf">Advanced Driver Options</a> for using a single device. The Ignore Hardware Serial Number flag will force all devices to be treated as the same device and enumerate from the lowest available COM port. This is only an option if you want to connect just one device.</p>
<h2>Removing Persistent Enumeration Entirely</h2>
<p>Since I found no documentation on how to wipe out all persistent enumeration (ftclean doesn&#8217;t do it), I started searching the registry. The persistent enumeration appears to be stored by both the serenum driver and the ftdibus driver.</p>
<ol>
<li>Run <a href="http://www.ftdichip.com/Resources/Utilities.htm">FTClean</a> to remove the driver and existing COM ports</li>
<li>Delete the FTDI enumeration registry settings
<ol>
<li>Remove HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\FTDIBUS</li>
<li>Remove HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\FTDIBUS</li>
<li>Remove HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\FTSER2K</li>
</ol>
</li>
<li>Delete serenum enumeration only for the ports you wish to remove
<ol>
<li>Under HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\serenum\Enum, remove each REG_SZ entry for sequential COM ports you want to remove. Then, adjust the Count REG_DWORD and NextInstance REG_DWORD to point to the next available COM port.</li>
</ol>
</li>
</ol>
<p>I don&#8217;t know if all of these steps are strictly necessary, as I haven&#8217;t yet tried to reduce the procedure. However, this should eliminate all persistent mapping and the next time you install an FTDI device, the serial ports should start enumerating again from the number specified in the NextInstance value.</p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fwww.asyndetic.com%2Fblog%2F2010%2F04%2F11%2Fftdi-usb-serial-port-enumeration-on-windows%2F&amp;title=FTDI%20USB%20Serial%20Port%20Enumeration%20on%20Windows" id="wpa2a_2"><img class="colorbox-56"  src="http://asyndetic.com/blog/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://www.asyndetic.com/blog/2010/04/11/ftdi-usb-serial-port-enumeration-on-windows/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>
<!-- WP Super Cache is installed but broken. The path to wp-cache-phase1.php in wp-content/advanced-cache.php must be fixed! -->
