Re: XON/XOFF communication problem

From: Tauno Voipio (tauno.voipio_at_iki.fi.NOSPAM.invalid)
Date: 10/22/03

  • Next message: Floyd Davidson: "Re: concatenate 2 files ... please help :-("
    Date: Wed, 22 Oct 2003 18:34:13 GMT
    
    

    "Andrej Trobentar" <andrej@rikom.si> wrote in message
    news:59127cb2.0310220133.790b719e@posting.google.com...
    > Grant Edwards <grante@visi.com> wrote in message
    news:<slrnbpbeut.4on.grante@isis.visi.com>...
    >
    > Hello all!
    >
    > First of all thanks for your help, I appriciate the quick response.
    >
    > > As long as he did an "stty" to set the port, it should work fine. I
    suggest
    > > something like this:
    > >
    > > (stty <whatever options you like>; cat foobar;) </dev/ttyS0
    >/dev/ttyS0
    > > or
    > > (stty <whatever options you like>; while true; do echo "foobar\n";
    done;) </dev/ttyS0 >/dev/ttyS0
    > >
    > > You can do it in two redirections, but the port will get closed/opened
    > > between the commands and the control lines (DTR, RTS) will glitch:
    > >
    > > stty <options> </dev/ttyS0
    > > cat foobar >/dev/ttyS0
    >
    > This is that I did now :
    >
    > stty -F /dev/ttyS0 -crtscts ixon ixoff 115200
    >
    > stty -a </dev/ttyS0 returns now :
    >
    > speed 115200 baud; rows 0; columns 0; line = 0;
    > intr = ^C; quit = ^\; erase = ^?; kill = ^U; eof = ^D; eol = <undef>;
    > eol2 = <undef>; start = ^Q;
    > stop = ^S; susp = ^Z; rprnt = ^R; werase = ^W; lnext = ^V; flush = ^O;
    > min = 1; time = 0;
    > -parenb -parodd cs8 hupcl -cstopb cread clocal -crtscts
    > -ignbrk -brkint -ignpar -parmrk -inpck -istrip -inlcr -igncr icrnl
    > ixon ixoff -iuclc -ixany -imaxbel
    > opost -olcuc -ocrnl onlcr -onocr -onlret -ofill -ofdel nl0 cr0 tab0
    > bs0 vt0 ff0
    > isig icanon iexten echo echoe echok -echonl -noflsh -xcase -tostop
    > -echoprt echoctl echoke
    >
    > Then I created a script with this in it :
    >
    > #!/bin/bash
    >
    > while true
    > do
    > echo "foobardjashdkjasdghasjddgajsdg" >/dev/ttyS0
    > done
    >
    > and run it. After 2 seconds or so I still get the errors on the
    > terminal as before. Any ideas what else can I try?
    >
    > MJT suggested :
    > > .... rather than correcting Paul and espousing your serial
    > > ability, why not go back to the OP and correct THEIR stty
    > > entry (check orig post).
    >
    > So I guess there is a problem with my stty setup, or?
    >
    > Sorry for my poor english.
    >

    No problem - it's not my native language, either.

    The difference between Linux and Windows may be caused by Windows not
    sending at full speed, but keeping short pauses between the bytes sent. The
    data stream can be looked at with an oscilloscope to verify. My experience
    is that Windows is not able to feed 115200 bit/s (not baud) at full speed,
    but Linux can on the same host.

    You need a fast feedback from the terminal - it's not able to follow a
    continuous stream of data at that speed. The feedback needs to be fast to
    cope with the receiver buffer getting full before the extra slack in the
    receiving FIFO is used up: the data is piling in a byte each 90 us.

    IMHO, the hardware handshake may be better here - no interrupt latency is
    involved in getting the feedback signal in, so we win at least one character
    time.

    Is is obligatory to pour the data at such high speed? I'd seriously
    condsider lowering the speed if ever possible.

    HTH

    Tauno Voipio
    tauno voipio @ iki fi


  • Next message: Floyd Davidson: "Re: concatenate 2 files ... please help :-("

    Relevant Pages

    • Re: Explicitly specializing std::min() on VC++ 2005 Express Edition
      ... have an excellent chance of getting feedback into the system. ... English Chinese Simplified Chinese Traditional French German Italian ... Windows Vista Windows XP Professional Windows XP Embedded Windows XP Home ... static const T& minimum( ...
      (microsoft.public.vc.language)
    • Re: Explicitly specializing std::min() on VC++ 2005 Express Edition
      ... asking to reopen the report if the problem persists: ... Open a new case on connect, referencing the original feedback and adding ... You need an account with Microsoft in order to report a problem to them, ... (includes Windows Presentation, Communication and Workflow Foundation) ...
      (microsoft.public.vc.language)
    • Re: OE Status (bottom right) - also no new email icon
      ... Please deliver feedback to the newsgroup, so that others can be helped. ... Didn't change anything in OE, as a matter of fact, I checked the version of OE on the old laptop where it behaves normally and it's the same version as the one on this laptop that is misbehaving - the updates didn't touch OE it seems. ... When did you last visit Windows Update? ...
      (microsoft.public.windows.inetexplorer.ie6_outlookexpress)
    • Re: gforth dos/win
      ... The way to create Gforth from CVS on Windows is the same way as on Unix - ... I've never seen a program under windoze do that. ... does Linux even let you use the modem ... feedback comes from Linux users. ...
      (comp.lang.forth)
    • Re: Editor?
      ... > What do all of you embedded systems guys use these days? ... > cutting it for me due to the fact it can't handle long pathnames or PATH ... > environment variables under Windows, and I'd like something more modern with ... tauno voipio iki fi ...
      (comp.arch.embedded)