Re: Not able to change baud rate



On 03/26/10 13:43, Joe Pfeiffer wrote:
Joe Beanfish<joe@xxxxxxxxxx> writes:

On 03/25/10 00:52, Hari Prasath wrote:
Hi all,

I have a video streaming device running Linux. when i change the baud
rate using the 'stty' command,it changes temporarily for few seconds.
Then again it changes to 115200 automatically.

Please find below the /etc/inittab file& the /etc/init.d/rcS file for
reference.

Not sure how those files matter since there's no reference to stty.

A serial port will revert to default settings when closed. So your
settings will only last as long as stty has the port open to set them
unless something else also has the port open. In general programs
should not assume anything about the port settings and should set
everything explicitly.

I've seen this claim from two different responders now; where is
itdocumented? I ask because, as a test, I used stty (inside a script)
to set a serial terminal speed, and it has remained at the new speed for
hours after the termination of the script.

I don't know where it's documented (reset serial params on close). I just
remember it being true for the last 20 years on *nix.

Perhaps something has that port open? Use "fuser" or "lsof" on the device
to see what processes may have it open.
.



Relevant Pages

  • Re: HP-UX: ssh connections ignore CTRL+C interrupts
    ... When I ssh from HPUX to another HPUX box and I type 'stty' I get the ... The only way to Ctrl-C working is to start the sshd from an interactive ... stty settings should probably be considered "uninitialized variables". ... The proper way for stty settings to be established is by the client. ...
    (SSH)
  • Re: Not able to change baud rate
    ... I have a video streaming device running Linux. ... when i change the baud ... rate using the 'stty' command,it changes temporarily for few seconds. ... A serial port will revert to default settings when closed. ...
    (comp.os.linux.development.apps)
  • Re: Not able to change baud rate
    ... Not sure how those files matter since there's no reference to stty. ... A serial port will revert to default settings when closed. ... I ask because, as a test, I used stty (inside a script) ... As we enjoy great advantages from the inventions of others, ...
    (comp.os.linux.development.apps)
  • Re: ctrl-l in bash
    ... > How do I echo ctrl-l in bash? ... if you haven't changed your default settings ... using stty.) ...
    (comp.os.linux.misc)
  • Re: Stty question
    ... POSIX compliance might be. ... stty -a returns in part: ... POSIX stty does not define options to alter these settings. ... So, are we talking hardware terminals, software terminals, or xterms? ...
    (comp.os.linux.misc)