X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fd588,9d6cec2b5f6a609b X-Google-Attributes: gidfd588,public X-Google-Thread: f996b,9d6cec2b5f6a609b X-Google-Attributes: gidf996b,public X-Google-Thread: 110f55,9d6cec2b5f6a609b X-Google-Attributes: gid110f55,public X-Google-ArrivalTime: 1994-02-28 16:34:45 PST Path: gmd.de!newsserver.jvnc.net!howland.reston.ans.net!cs.utexas.edu!uunet!ssw.vienna.itd.sterling.com!ssw.vienna.itd.sterling.com!ewiles From: ewiles@vienna.itd.sterling.com (Edwin Wiles) Newsgroups: alt.ascii-art,alt.binaries.pictures.ascii,alt.ascii-art.animation Subject: Re: Where can I find the control codes for VT100 terminal ? Date: 01 Mar 1994 00:34:45 GMT Organization: Sterling Software ITD, Inc. Lines: 31 Message-ID: References: NNTP-Posting-Host: ditds.vienna.itd.sterling.com In-reply-to: skwong@cuse1.se.cuhk.hk's message of Sun, 27 Feb 1994 08:48:27 GMT In article skwong@cuse1.se.cuhk.hk (Wong Sai Kee (Graduate Assistant)) writes: I am going to write a C program which ought to print characters on screen for an experiment on Short Term Memory test. Since the program need to place the char at random position on screen and then erase the char; I need to printf() some control codes. I don't have information on the control chars for terminal (I guess the vt100 is the most common one). Can anyone send me a pointer on "where can I ftp the necessary information" ? If you're writing it for use on Unix, you should be using either the termcap or terminfo libraries to obtain the desired command strings. DO NOT EMBED TERMINAL COMMAND CODES IN YOUR PROGRAM. That only causes trouble for everyone else who doesn't have whatever flavor of terminal you used as your model. The termcap and terminfo libraries provide very simple functions for obtaining and using the full range of terminal control strings. Use them, and your program will work on ANY terminal, for which a termcap or terminfo description exists. (I.e. nearly everything, or someone can easily create one.) Curses could be overkill, but you're welcome to try it if you like. The problem with it is that there are at least two incompatible versions of curses out there, and most vendor's implementations (to my experience) are buggy in various places. Good Luck! -- Edwin Wiles | Sterling Software, Inc. ITD | Vienna, VA, USA Preferred..: ewiles@vienna.itd.sterling.com GCS d--@ -p+ c++(++++) l u++ e- m+(++) s+/ n-(+) h--- f g+ w+ t+ r(+) y?