[comp.terminals] Set WY-60 clock from software?

tbetz@dasys1.UUCP (TOM BETZ) (04/14/89)

I've RTFM and can't find a hint... has anyone figured out how to
set the WY-60's internal clock from software, using date(C), say,
as a time source?

Be kinda nice if I could stick something into my .profile that
would do this at login.


-- 
    "Still I sing bonny boys, bonny mad boys,       |  Tom Betz, 114 Woodworth 
           Bedlam boys are bonny,                   |  Yonkers, NY 10701-2509
  For they all go bare, and they live by the air,   |      (914) 375-1510
And they want nor drink nor money." - Steeleye Span | cmcl2!hombre!dasys1!tbetz

pme@io.UUCP (Paul English x3168) (04/15/89)

In article <9330@dasys1.UUCP> tbetz@dasys1.UUCP (TOM BETZ) writes:
>I've RTFM and can't find a hint... has anyone figured out how to
>set the WY-60's internal clock from software, using date(C), say,
>as a time source?

date|awk -F: '{printf("^[c8%s%s", substr($1,length($1)-1,2), substr($2,1,2))}'

That is `ESC c' in the printf.
-- 
Paul English
  Interleaf: pme@ileaf.com, ...!{sun!sunne,mit-eddie}!ileaf!pme
  UMass/Boston: pme@umb.edu, ...!harvard!umb!pme
(umb has better email service)

dan@wyse.wyse.com (Dan Weaver x1321) (04/18/89)

In article <9330@dasys1.UUCP> tbetz@dasys1.UUCP (TOM BETZ) writes:
>I've RTFM and can't find a hint... has anyone figured out how to
>set the WY-60's internal clock from software, using date(C), say,
>as a time source?
>
>Be kinda nice if I could stick something into my .profile that
>would do this at login.
>
>

The following script will set the time on a WY-60:

#!/bin/sh
#
date "+^[c8%H%M"
#

Note:  ^[ should be the escape character.

Be careful not to send this sequence to an ANSI terminal such as the
VT-100.  <ESC> c is a hard reset that may not only trash your display
but may log you off.

The Fine Manual describes this sequence in the section on
"Communicating with the Computer" in Appendix D page 6.

Dan Weaver

logan@vsedev.VSE.COM (James Logan III) (04/18/89)

In article <9330@dasys1.UUCP> tbetz@dasys1.UUCP (TOM BETZ) writes:
# I've RTFM and can't find a hint... has anyone figured out how to
# set the WY-60's internal clock from software, using date(C), say,
# as a time source?
# 
# Be kinda nice if I could stick something into my .profile that
# would do this at login.

This script is for a Visual 630 terminal, but the escape sequences
may be the same:

----------------------------------------------------------------------------
#	clock.sh	Written by James Logan	Thu Nov  3 23:01:17 EST 1988
#		Sets the hardware clock on a Visual 603 terminal.
#
# $Revision$
#
# $Log$

set -- `date +"%H %M"`;
if test "$1" -gt 12; then
	FLAG="2";
else
	FLAG="1";
fi;
echo "\033P1;${FLAG}~${1}:${2}:00\033\\Clock set to $1$2";
exit 0;
----------------------------------------------------------------------------

			Hope this helps.
				-Jim

-- 
Jim Logan                           logan@vsedev.vse.com
VSE Software Development Lab        uucp:  ..!uunet!vsedev!logan
(703) 329-4654                      inet:  logan%vsedev.vse.com@uunet.uu.net