head     1.1;
access   ;
symbols  ;
locks    ; strict;
comment  @# @;


1.1
date     89.07.18.12.51.30;  author sarah;  state Exp;
branches ;
next     ;


desc
@@



1.1
log
@Initial revision
@
text
@			    SPRITE DEMO

     These programs demonstrate the use of SUN's Remote Procedure  Calls  on
VxWorks  and  SunOS  UNIX.   The  programs  implement a set of "sprites", or
"balls", which bounce around in a suntools window.  The demo is comprised of
three distinct entities which communicate with each other using RPC.

(1)  drawServer - run from the SUN workstation in  a  suntools  window.   It
     erases  and draws "sprites" in the window upon receipt of draw requests
     from ramaServer.  Must started before any of the corresponding  VxWorks
     programs.

	 % drawServer &

(2)  ramaServer - run on VxWorks or UNIX system.   It  keeps  track  of  all
     active  sprites.   Any  time a sprite update's its position, it informs
     ramaServer; it checks to see if the sprite has collided with any  other
     sprite  or  with  a  wall,  and  if so, informs the sprite.  ramaServer
     redraws the sprite by making requests to drawServer.

	 -> ld < hostname:/usr/vw/demo/sprites/sprites.o
	 -> sp ramaServer, "drawServerHostName"
     or
	 % ramaServer ["drawServerHostName"] &

     where drawServerHostName is the hostname of the UNIX system  where  the
     drawServer  is  running.  The hostname is optional for UNIX version, it
     defaults to the same host.  On VxWorks the UNIX host may be added with:

             -> hostAdd "drawServerHostName", "90.3"

(3)  simpleSprite  -  run  on  VxWorks  or  UNIX  system.   Any  number   of
     simpleSprite's may be spawned on any VxWorks or UNIX system on the net-
     work.  The routine moves a sprite in drawServer's  window  by  periodi-
     cally updating its position with ramaServer.

	 -> sp simpleSprite, "ramaHostName", xVel, yVel
     or
	 % simpleSprite ["ramaHostName"] xVel yVel

     where ramaHostName is the hostname of the VxWorks or UNIX system  where
     ramaServer is running.  Using "localhost" is fine, otherwise on VxWorks
     use:
             -> hostAdd "ramaHostName", "90.50"

     xVel is the initial X velocity of the sprite, and yVel is the initial Y
     velocity of the sprite.  Reasonable values range between -20 and 20.

@
