[comp.sys.handhelds] HP48: HYDE installer

jurjen@cwi.nl (Jurjen NE Bos) (11/20/90)

I wrote this HYDE installer, and realized it is a good example of the use
of the kermit server mode on the 48.
The program assumes Bill Wickes' library is installed in port 0, and sends,
installes, and actives the library in an HP48 that runs a kermit server.
(This can be used to fool your friends, but don't tell anyone I said that! :-)

(This program is typed in and verified 3 times. I hope it is all correct)

\<< :0: 998 RCL 'T'
STO 'T' DUP SEND
PURGE
C$ 77 T 0STO'T'PURGE
DATE TIME 1E-4 HMS+
\<<DELALARM"HYDE"OBJ\->\>>0
4 \->LIST STOALARM OFF
"C" PKT
\>>

It is fun to try to figure out how this works.  If you like to do this, stop
reading here.
(rest of the posting explains working of program)

It works as follows:
First, the library is stored in variable T, and sent to the other side.  When
it is arrived, the variable T can be purged, and the real fun begins.  The
following program is executed on the other side using the kermit remote host
command (using "C" PKT):
    Put the library in T into port 0.  Delete T.
    Make an alarm that is due in 1 second, executing:
	Delete this alarm, evaluate the string HYDE.  (This cannot be replaced
	by just command HYDE because it will be interpreted as a variable at
	parse time, while it will be a command at execution time!)
    Switch the calculator off.
    (The calculator will turn on in a second because of the alarm.  The
    library that is just installed will initialize, causing a system halt.
    This will kill the kermit server.  Now the library is installed, HYDE will
    be a command.  The alarm gets executed, deleting itself, and parsing HYDE,
    that causes the library to do its work.)