[comp.lang.fortran] Help! How to read SUN keyboard chars in SUN FORTRAN

sbs@csc.fi (08/02/90)

In article <2587.26b69a29@csc.anu.oz>, kjm100@csc.anu.oz writes:
> 
> 31 July 1990
> 
> *** Attention: SUN FORTRAN/C/OS gurus ***
> 
> I would be very grateful if anyone could tell me how to read keyboard 
> characters --- one at a time without echoing those characters to the 
> terminal --- within a SUN FORTRAN program.  One would think that using 
> the integer function GETC would do the trick but no ...
> 


Well, I have done this once under SYSTEM V Silicon Graphics by using C.
And as under UNIX calling C-programs from Fortran is easy matter,
I will suggest to use C-interface.

Basic idea is to change in file <termio.h> (at /usr/include)
c_lflag to correct value so that echoing is controlled by the programmer.
Also ioctl-command should be used.

I will give more detailed answer as get back my book in "Advanced UNIX
programming".

----

Sami Saarinen
Centre for Scientific Computing (CSC) , Finland
Mail: sbs@csc.fi