Terminal Emulation?

Denys Duchier duchier at ps.uni-sb.de
Fri Jan 31 02:59:13 CET 2003


rlpowell at digitalkingdom.org (Robin Lee Powell) writes:

>> bash thinks it is talking to a regular stream because it IS.  You have
>> exactly the same issue with pipes when doing shell programming.  If
>> you need a PTY, it needs to be explicitly allocated.  
>
> OK.  Can you give me any pointers on doing that in Mozart?  8)

Native functors! openpty or something. then maybe back through Open.

>> I don't think that bash can do that.  On the other hand ssh has the -t
>> option for just this occasion (pretty convenient for tunelling a
>> regular terminal connection through several host indirections, btw).
>
> Ah.  That *almost* works.  It certainly works much better.  Thanks.

note this interisting tidbit in the ssh man page:

     -t      Force pseudo-tty allocation.  This can be used to execute arbi-
             trary screen-based programs on a remote machine, which can be
             very useful, e.g., when implementing menu services.  MULTIPLE -t
             OPTIONS FORCE TTY ALLOCATION, EVEN IF SSH HAS NO LOCAL TTY.

> Well, this would be part of a much larger program.  What I want is a way
> for users telnetted to a TCP/IP port that's run by a Mozart program to
> be able to interact with an arbitrary terminal-based program on the
> machine the Mozart program is running on.

The question is: why bother with a "terminal emulation"?  Most clients
will (I should hope) connect through a client that is slightly more
evolved than what we had back when I started in CS (actually, what we
had back then were teletypes - so, ok, non-descript terminals were an
improvement :-).

For truly minimal connections, why bother with a terminal at all?  All
old-time protocols permit clients with a completely trivial mostly
line oriented protocol.

Maybe there is a really good reason - for example, I am continuously
amazed at many typical "business" installations, that use really old
fashion terminal-type monitors and business applications that are
still living (thought fossilized) proof that, once, when dinosaurs
roamed the earth and messed up my front yard, they (the applications,
not the dinosaurs) were considered an improvement.  I think'll watch
Jurassic Park again and wax nostalgic.  Those were the times!

Cheers,

-- 
Dr. Denys Duchier
Iquipe Calligramme
LORIA, Nancy, FRANCE
-
Please send submissions to users at mozart-oz.org
and administriva mail to users-request at mozart-oz.org.
The Mozart Oz web site is at http://www.mozart-oz.org/.
Please send bug reports to bugs at mozart-oz.org.





More information about the mozart-users mailing list