Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!caen!ox.com!math.fu-berlin.de!fauern!unido!rwthinf!cip-s02!wolfram From: wolfram@cip-s02.informatik.rwth-aachen.de (Wolfram Roesler) Newsgroups: comp.sys.atari.st Subject: Re: SIMPLE terminal emulator Keywords: terminal program Message-ID: Date: 18 Apr 91 08:17:05 GMT References: <747@uqcspe.cs.uq.oz.au> Sender: news@rwthinf.UUCP Lines: 31 warwick@cs.uq.oz.au (Warwick Allison) writes: >Is there a SIMPLE terminal emulator at atari.archive? The Okami Shell has a built-in command named `te' which will do exactly this. However, if you have a C compiler, it's not hard to write: terminal() { int c; long w; for(;;) { c=Bconin(1); /* read from aux */ Cconout(c); /* output read char */ if (Cconis()) /* only if key was pressed */ { w=Cnecin(); /* read from con */ if ((w>>16)==EXIT) break; /* terminal exit condition */ Bconout(1,(int)w);/* output to aux */ } } } EXIT should be #defined to be the scancode of the key you want to exit the terminal with (UNDO for instance). I am using Gemdos for console I/O so it can be redirected. CU Wolfram