lkml.org 
[lkml]   [2001]   [Mar]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Serial port latency
On Thu, Mar 22, 2001 at 07:21:28PM +0100, Geir Thomassen wrote:
> My program controls a device (a programmer for microcontrollers) via the
> serial port. The program sits in a tight loop, writing a few (typical 6)
> bytes to the port, and waits for a few (typ. two) bytes to be returned from
> the programmer.

Check out the man page for the "low_latency" configuration parameter
in the setserial man page. This will cause the serial driver to burn
a small amount of additional CPU overhead when processing characters,
but it will lower the time between when characters arrive at the
RS-232 port and when they are made available to the user program. The
preferable solution is to use a intelligent windowing protocol that
isn't heavily latency dependent (all modern protocols, such as kermit,
zmodem, tcp/ip, etc. do this). But if you can't, using setserial to
set the "low_latency" flag will allow you to work around a dumb
communications protocol.

- Ted
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:29    [W:0.088 / U:1.112 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site