Subject: | |
From: | |
Reply To: | |
Date: | Thu, 2 Jul 1998 18:14:00 -0400 |
Content-Type: | text/plain |
Parts/Attachments: |
|
|
[log in to unmask] wrote:
>
> >Does anyone know if there is an escape sequence that could be used to
> >identify the version of reflections that is being used to connect to
> >our host?
> I have used the Esc&oC<cmd> string to pass a command to Reflection.
> The $SERIAL command seems to have the information you are looking for.
> So combining them into Esc&oC$SERIAL should give you the information
> you are looking for.
Here's a snippet from our system-wide logon UDC [with comments]:
We set 'utc_reflect_serial' to the Reflection serial number,
'UTCReflection' to a number 0=no Reflection, 1=Windows, 2=Mac, and
3=DOS (hey, it's an old script), and finally xdstermtype to 1 (a local
screen I/O variable not unlike unix's TERM environment variable) to
indicate it's an hpterm on the other end.
setvar utc_reflect_serial "X"
setjcw UTCReflection=0
comment ** If origin is a session (VT or otherwise) we will setup
comment ** some Reflection and local parameters. If this is a VT
comment ** session initiated by a job, we DON'T want to since the
comment ** status read will swallow the job's next $STDIN record.
comment ** Only way to test this is trying to set hptypeahead true
comment ** which fails if the origin is a batch job
setvar hpmsgfence 2
setvar hpcierr 0
setvar savetype hptypeahead
continue
setvar hptypeahead true
if hpinteractive and hpcierr = 0 then
set echo=off
pause 1
setvar hptypeahead savetype
continue
input utc_reflect_serial;prompt="![chr(27)+"*s12347^"]";wait=2
setvar hpmsgfence 0
set echo=on
[The Reflection platform can be deduced from the first char of the
serial number. The version number follows the platform code which
is what you are looking for (will leave that part to you!)]
if lft(utc_reflect_serial,1) = "W"
setjcw UTCReflection=1
elseif lft(utc_reflect_serial,1) = "M"
setjcw UTCReflection=2
elseif lft(utc_reflect_serial,1) = "I"
setjcw UTCReflection=3
endif
[Note that all 'real' hpterms will return the regular terminal type
in response to the Reflection status query, so you can check for a
leading 'HP' or '700' if you care that this is a real hpterm]
if UTCReflection > 0
setjcw xdstermtype 1
endif
else
setvar hpmsgfence 0
endif
(Anybody know how to do the above in HP-UX?)
Jeff Kell <[log in to unmask]>
|
|
|