(FILECREATED "24-Dec-85 16:20:11" {ERIS}<LISPCORE>LIBRARY>RS232CHAT.;18 3473   

      changes to:  (FNS RS232CHAT.SET.PARAMETERS)

      previous date: " 8-Sep-85 18:17:10" {ERIS}<LISPCORE>LIBRARY>RS232CHAT.;17)


(* Copyright (c) 1985 by Xerox Corporation. All rights reserved.)

(PRETTYCOMPRINT RS232CHATCOMS)

(RPAQQ RS232CHATCOMS ((FNS RS232CHAT.HOST.FILTER RS232CHAT.OPEN RS232CHAT.SET.PARAMETERS)
			(ADDVARS (CHAT.PROTOCOLTYPES (RS232 . RS232CHAT.HOST.FILTER)))
			(INITVARS (RS232CHAT.OPTION.MENU (create MENU ITEMS ←
								 (QUOTE (("Set Line Parameters"
									   (RS232CHAT.SET.PARAMETERS)
									   "Modify RS232 parameters"))
									)
								 TITLE ← "RS232 Options")))
			(GLOBALVARS RS232CHAT.OPTION.MENU)
			(DECLARE: DONTCOPY (FILES (LOADCOMP FROM VALUEOF LISPUSERSDIRECTORIES)
						  CHATDECL))
			(FILES (SYSLOAD FROM VALUEOF LISPUSERSDIRECTORIES)
			       DLRS232C CHAT)))
(DEFINEQ

(RS232CHAT.HOST.FILTER
  (LAMBDA (NAME)                                             (* ejs: "27-Aug-85 13:12")
    (COND
      ((FMEMB (U-CASE NAME)
	      (QUOTE (RS232 RS232C MODEM)))
	(COND
	  ((NULL \RS232FLG)
	    (RS232C.INIT RS232C.DEFAULT.INIT.INFO)))
	(LIST (QUOTE RS232)
	      (FUNCTION RS232CHAT.OPEN))))))

(RS232CHAT.OPEN
  (LAMBDA (HOST)                                             (* ejs: " 2-Jul-85 13:09")

          (* * Return a pair of SPP streams for a chat connection, or NIL. Add CHAT specific operations to the STREAM via 
	  STREAMPROP.)


    (PROG (OUTSTREAM STREAM)
          (SETQ STREAM (OPENSTREAM (QUOTE {RS232})
				   (QUOTE INPUT)))
          (SETQ OUTSTREAM (RS232C.OUTPUTSTREAM))
          (STREAMPROP STREAM (QUOTE SETDISPLAYTYPE)
		      (FUNCTION NILL))
          (STREAMPROP STREAM (QUOTE READPEVENT)
		      (RS232C.READP.EVENT STREAM))
          (STREAMPROP STREAM (QUOTE LOGINFO)
		      (FUNCTION NILL))
          (STREAMPROP STREAM (QUOTE FLUSH&WAIT)
		      (FUNCTION NILL))
          (STREAMPROP STREAM (QUOTE SENDSCREENPARAMS)
		      (FUNCTION NILL))
          (STREAMPROP STREAM (QUOTE OPTIONMENU)
		      RS232CHAT.OPTION.MENU)
          (RETURN (CONS STREAM OUTSTREAM)))))

(RS232CHAT.SET.PARAMETERS
  (LAMBDA NIL                                                (* ejs: "24-Dec-85 14:57")
    (LET* ((WINDOW WINDOW)
	   (PWINDOW (GETPROMPTWINDOW WINDOW)))
          (COND
	    ((FNTYP (QUOTE RS232CMENU.SET.PARAMETERS))
	      (ALLOW.BUTTON.EVENTS)
	      (RESETFORM (CURSOR WAITINGCURSOR)
			   (RS232CMENU.SET.PARAMETERS WINDOW))
	      (printout PWINDOW T "Select desired parameters.  Choose Apply! when done."))
	    (T (printout PWINDOW T "You must load RS232CMENU to use this function"))))))
)

(ADDTOVAR CHAT.PROTOCOLTYPES (RS232 . RS232CHAT.HOST.FILTER))

(RPAQ? RS232CHAT.OPTION.MENU (create MENU ITEMS ← (QUOTE (("Set Line Parameters" (
RS232CHAT.SET.PARAMETERS)
										   
									"Modify RS232 parameters")))
				       TITLE ← "RS232 Options"))
(DECLARE: DOEVAL@COMPILE DONTCOPY

(GLOBALVARS RS232CHAT.OPTION.MENU)
)
(DECLARE: DONTCOPY 
(FILESLOAD (LOADCOMP FROM VALUEOF LISPUSERSDIRECTORIES)
	   CHATDECL)
)
(FILESLOAD (SYSLOAD FROM VALUEOF LISPUSERSDIRECTORIES)
	   DLRS232C CHAT)
(PUTPROPS RS232CHAT COPYRIGHT ("Xerox Corporation" 1985))
(DECLARE: DONTCOPY
  (FILEMAP (NIL (915 2885 (RS232CHAT.HOST.FILTER 925 . 1291) (RS232CHAT.OPEN 1293 . 2319) (
RS232CHAT.SET.PARAMETERS 2321 . 2883)))))
STOP