<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="bbPress/1.0.2" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>LeafLabs Garden &#187; Topic: serial interface</title>
		<link>http://forums.leaflabs.com/topic.php?id=637</link>
		<description>A place to share, learn, and grow...</description>
		<language>en-US</language>
		<pubDate>Fri, 22 Jan 2016 00:26:43 +0000</pubDate>
		<generator>http://bbpress.org/?v=1.0.2</generator>
		<textInput>
			<title><![CDATA[Search]]></title>
			<description><![CDATA[Search all topics from these forums.]]></description>
			<name>q</name>
			<link>http://forums.leaflabs.com/search.php</link>
		</textInput>
		<atom:link href="http://forums.leaflabs.com/rss.php?topic=637" rel="self" type="application/rss+xml" />

		<item>
			<title>poslathian on "serial interface"</title>
			<link>http://forums.leaflabs.com/topic.php?id=637#post-3544</link>
			<pubDate>Mon, 07 Feb 2011 15:58:06 +0000</pubDate>
			<dc:creator>poslathian</dc:creator>
			<guid isPermaLink="false">3544@http://forums.leaflabs.com/</guid>
			<description>&#60;p&#62;oh, btw, current Maple Rev5 and under are full speed USB 2.0 (not high speed usb 2.0)
&#60;/p&#62;</description>
		</item>
		<item>
			<title>poslathian on "serial interface"</title>
			<link>http://forums.leaflabs.com/topic.php?id=637#post-3543</link>
			<pubDate>Mon, 07 Feb 2011 15:57:36 +0000</pubDate>
			<dc:creator>poslathian</dc:creator>
			<guid isPermaLink="false">3543@http://forums.leaflabs.com/</guid>
			<description>&#60;p&#62;The short answer is what gbulmer has said. The polling frequency for USB should be on the order of a few ms (ostensibly 1ms). I imagine much of the latency youre seeing is due to the java VM. You can probably get faster responses by directly opening the serial port in C. The long answer is that I dont know the round trip latency of writing to the serial port in either python (pyserial) or java (rxtxlib) but this would be a very valuable test to run. If anyone has the data, please post! Ill throw this test on the queue of things to document. &#60;/p&#62;
&#60;p&#62;Thanks!
&#60;/p&#62;</description>
		</item>
		<item>
			<title>michu on "serial interface"</title>
			<link>http://forums.leaflabs.com/topic.php?id=637#post-3542</link>
			<pubDate>Mon, 07 Feb 2011 15:20:27 +0000</pubDate>
			<dc:creator>michu</dc:creator>
			<guid isPermaLink="false">3542@http://forums.leaflabs.com/</guid>
			<description>&#60;p&#62;I tested it with an arduino duemillanove and an arduino UNO - I use Mac OSX snow leopard. &#60;/p&#62;
&#60;p&#62;I also thought the arduino uno has a much better serial response time - but in my tests I couldn't measure a better serial response... maybe this is a os related driver issue. Using the Java rxtx lib, I measured around 30ms round trip time - which is way too much for my needs.I also played with the buffer size...&#60;/p&#62;
&#60;p&#62;So I'm interested, whats the serial buffer size of the maple is, and a &#34;typical&#34; serial response time...&#60;/p&#62;
&#60;p&#62;thanks for your information gbulmer!
&#60;/p&#62;</description>
		</item>
		<item>
			<title>gbulmer on "serial interface"</title>
			<link>http://forums.leaflabs.com/topic.php?id=637#post-3536</link>
			<pubDate>Sun, 06 Feb 2011 12:48:46 +0000</pubDate>
			<dc:creator>gbulmer</dc:creator>
			<guid isPermaLink="false">3536@http://forums.leaflabs.com/</guid>
			<description>&#60;p&#62;Are you using a newer Arduino UNO, or one of the slightly older Arduino's which use the FTDI USB to USART chip?&#60;/p&#62;
&#60;p&#62;1. The latency to send to an Arduino should be about a couple of milliseconds, unless:&#60;br /&#62;
a. the host is opening the connection everytime (sloooooow, so I don't think that's what is happening), or&#60;br /&#62;
b. only a few bytes are written and the host is not flushing the buffer.&#60;br /&#62;
AFAIK, the FTDI USB chips buffer has 16 bytes, and the host flushes when it is only part full periodically, but not every millisecond. I think, if you write 16 or more bytes it should be sent with less latency (try 64, 32, 16). Also, if you use Windows, there is an FTDI library available on Windows has extra API calls to control buffer flushing, but you'd have to change your host application.&#60;/p&#62;
&#60;p&#62;2. IMHO If your host side program *must* open the connection each time it sends data, it won't much matter much what is on the other end as the host operating system will waste lots of the time.&#60;/p&#62;
&#60;p&#62;3. USB latency, once you get down to the 'bare metal' is supposed to be a couple of milli-seconds (polled every millisecond) even for the slowest, 1.2Mbps USB, but it is a protocol polled by the host, so that determines a lot of the latency, not the device end.&#60;/p&#62;
&#60;p&#62;4. USB on the Maples STM32F is built-in. There is no intervening USB to serial converter, it's all on chip. STM32F USB is full-speed (12Mbs), which is theoretically the same as the old Arduino's FTDI, and the new UNO. The STM32F USB (like most USB interfaces) has its own memory buffer, and so the effective latency experienced by your program depends (somewhat) on how that USB receiver and buffer are configured.&#60;/p&#62;
&#60;p&#62;The actual USB throughput for the STM32F is significantly higher than the old Arduino FTDI chip, but I don't know if that is at the cost of latency. I have no measurements for latency.&#60;/p&#62;
&#60;p&#62;(I am not an employee of Leaf Labs)
&#60;/p&#62;</description>
		</item>
		<item>
			<title>michu on "serial interface"</title>
			<link>http://forums.leaflabs.com/topic.php?id=637#post-3533</link>
			<pubDate>Sun, 06 Feb 2011 07:25:44 +0000</pubDate>
			<dc:creator>michu</dc:creator>
			<guid isPermaLink="false">3533@http://forums.leaflabs.com/</guid>
			<description>&#60;p&#62;hey guys, I'm curious how the usb serial interface works with the Maple? Currently I use the Arduino to drive some led stripes using the SPI protocol. However the latency to send data to the Arduino is quite high (20-30ms) and the serial buffer is quite small. &#60;/p&#62;
&#60;p&#62;What is serial latency the Maple have? Is the serial interface a highspeed usb2.0 interface, or a regular usb serial convertor?&#60;/p&#62;
&#60;p&#62;cheers and thanks in advance!&#60;br /&#62;
michu
&#60;/p&#62;</description>
		</item>

	</channel>
</rss>
