Re: elimination of intercharacter gap in RS232 stream?




"Grant Edwards" <grante@xxxxxxxx> wrote in message
news:13gq98pse15f4c9@xxxxxxxxxxxxxxxxxxxxx
On 2007-10-10, Bo <bo@xxxxxxxxxx> wrote:

Writing an Embbeded Linux app for a PC104/Versalogic board.
Linux 2.6.14.17.

Using write() to transmit data packets to another PC104 board.
If I write() 30 bytes, sometimes there is a 2-5mS gap in the
middle of the transmission, usually at about byte 15-20, but
sometimes at byte 29--as seen on a scope.

It sounds like either your serial driver is broken or you've
got interrupts disabled for a _long_ time. The serial driver
should get an interrupt when the tx fifo is low and have tons
of time to fill it before it underflows.

No-- no ISR being disabled--at least in the app. However, when we disable
our real-time signals during the wrote, the response time of the protocol
jumps from 10mS to 80-120mS!



Tried using low latency setting when opening the port--but
this made no difference. This is causing difficulties for the
receiving end-- and we have yet to add two more serial ports
to the application.

Any ideas on how to force continous transmission of the data?

Fix the serial driver or fix the other driver that's locking
out interrupts for so long. You could try raising the tx fifo
threshold so that the serial driver has more time to respond.
That will increase the tolerance for high interrupt latency,
but it will generate more frequent interrupts and result in
higher overhead.

You could also try fixing the receive end so that a gap between
bytes doesn't make it fall over.

We're working that issue with _some_ success.

THanks,

Bo


--
Grant Edwards grante Yow! FEELINGS are
cascading
at over me!!!
visi.com


.



Relevant Pages

  • Re: elimination of intercharacter gap in RS232 stream?
    ... It sounds like either your serial driver is broken or you've ... got interrupts disabled for a _long_ time. ... Any ideas on how to force continous transmission of the data? ... You could also try fixing the receive end so that a gap between ...
    (comp.arch.embedded)
  • Re: How to get physical address from vitrutal address-Linux serial driver
    ... > I am modifying the serial driver in linux for a custom PCI card. ... > The card has interrupts which has to be enabled and disable during open and close. ... > How to get the physical adderess form virtual addesss(output of ioremap()) ...
    (comp.os.linux.development.system)
  • Re: How to get physical address from vitrutal address-Linux serial driver
    ... >> I am modifying the serial driver in linux for a custom PCI card. ... >> The card has interrupts which has to be enabled and disable during open and close. ... If the address corresponds to serial port 1,then i need to enable the ...
    (comp.os.linux.development.system)
  • Re: Interrupts disabled for too long in printk
    ... that showed missing interrupts. ... tracer to solve this kind of problem which I presented at the CE Linux Form ... It shows that, when the serial console is activated, the following code disables ... serial driver getting interrupts to be able to display the message? ...
    (Linux-Kernel)
  • Re: Bug in X86 serial port driver in CE.NET 4.2 ?
    ... Unfortunately the OS finally hung now with our own serial driver, ... happen after enabling interrupts for transmission too.... ... be fun to find... ...
    (microsoft.public.windowsce.platbuilder)