home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / unix / question / 10023 < prev    next >
Encoding:
Internet Message Format  |  1992-08-12  |  1.3 KB

  1. Path: sparky!uunet!auspex-gw!guy
  2. From: guy@Auspex.COM (Guy Harris)
  3. Newsgroups: comp.unix.questions
  4. Subject: Re: How to stty cbreak ?
  5. Keywords: terminal, tty,
  6. Message-ID: <14029@auspex-gw.auspex.com>
  7. Date: 13 Aug 92 03:07:09 GMT
  8. References: <1992Aug13.000728.412@eng.ufl.edu>
  9. Sender: news@auspex-gw.auspex.com
  10. Distribution: usa
  11. Organization: Auspex Systems, Santa Clara
  12. Lines: 26
  13. Nntp-Posting-Host: bootme.auspex.com
  14.  
  15. >>stty cbreak
  16. >
  17. >but it doesn't seem work.
  18. >
  19. >I can't tell whether the cbreak
  20. >mode is on or not.
  21. >(I used: stty all, stty -a.
  22. >nothing appropriate shows.)
  23.  
  24. If your system's "stty" command supports "stty -a", it probably has a
  25. System V/POSIX-ish "stty" command, and probably has a System V/POSIXish
  26. tty driver as well.  (For example, it might be SunOS 4.x.)
  27.  
  28. If so, there probably *is* no "cbreak" mode; that's what the old
  29. V7/BSD-style tty driver had.
  30.  
  31. There is, instead, "icanon" mode.
  32.  
  33. The "stty" command probably supports "stty cbreak" and "stty -cbreak"
  34. for backwards compatibility; however, "stty cbreak" probably turns
  35. "icanon" mode *OFF*, and "stty -cbreak" probably turns it on.
  36.  
  37. If "stty -a" says "icanon" is on, then it's as if "cbreak" mode were
  38. off.  If it says that "icanon"is not on, then it's as if "cbreak" mode
  39. were on (roughly; there's also "min" and "time" to worry about, but you
  40. probably don't want to have to worry about that...).
  41.