C++ Open Dev Tty

P: n/a
On Tue, 11 Nov 2003 11:25:04 +0100, Keeper <ke****@iosys.no-ip.org>
wrote in comp.lang.c:
Hi all,
Hi yourself.
I'm trying to send chars to the current console (currently having cursor
focus) - /dev/tty0 - in my program by:
I don't know about pl.comp.lang.c, because I don't read it, but I can
speak for comp.lang.c and comp.lang.c++, namely:
Your post is off-topic in these two groups at least. These groups
discuss, respectively, the standard C and C++ languages. And there is
no /dev/tty0 in either C or C++.
char st='K',ri='L',ng='J';
int tty;
tty = open('>/dev/tty0', O_WRONLY);
There is no open function in C or C++.
ioctl(tty, TIOCSTI, &st);
ioctl(tty, TIOCSTI, &ri);
ioctl(tty, TIOCSTI, &ng);
There is no ioctl function in C or C++.
I'm using RedHat 9, kde.
Everything is ok in the linux console (on tty1 chars are sending
properly - KLJ..), but in kde i see strange things (and not only for
those characters):
^[[D- on ttyp1
- on mozilla window
My question is: why chars are not properly sendt by ioctl call, is there
any additional settings to do (setting termios, keyboard driver?)??
thanks,
Keeper

Your question is about Linux, its system calls, and its file system,
not the C or C++ language. You will probably get excellent answers in
a group like news:comp.os.linux.development.aps.
--
Jack Klein
Home: http://JK-Technology.Com
FAQs for
comp.lang.c http://www.eskimo.com/~scs/C-faq/top.html
comp.lang.c++ http://www.parashift.com/c++-faq-lite/
alt.comp.lang.learn.c-c++ ftp://snurse-l.org/pub/acllc-c++/faq

C++ Open Dev Tty File

Oct 30, 2009  Re: SOLVED How To Read Data Over /dev/ttyUSB0 When in 'cooked' mode (which is the default), you wont see anything until it finds a LF in the stream Instead of '.

11 rows  v1.25 freeware Download: InstallXferOTT.exe OTT (VST AAX) for Windows (1.201) Same plugin as 1.2 (improved installer elevates permissions) v1.2 freeware Download: DeltaModulatorOSX.zip Delta Modulator (VST and AU) for Mac OSX (1.0) v1.0 freeware Download: DeltaModulatorPC.zip. Xfer records ott.

Tty

C Open Dev Tty Code

  1. If you open up another shell, say by using screen or xterm, you can run run echo spooky /dev/pts/2 in that shell to make the text appear on your original terminal, and the same for the other commands. All of this is just your shell opening a file without knowing it's a TTY.
  2. Metal paper clips can sometimes be bent to use as jumpers. Whatever you use as a jumper take care not to bend or excessively scratch the pins. To receive something from a port, you can go to a virtual terminal (for example Alt-F2 and login) and type something like 'cp /dev/ttyS2 /dev/tty'.
  3. When we can't open ptmx with specified index in most cases it means that the pts we're about to use is already used by someone else. Look, if you're migrating some application at least devpts filesystem should be mounted with newinstance option.
Comments are closed.