home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
HomeWare 14
/
HOMEWARE14.bin
/
comms
/
commo60.arj
/
MOSTHOST.MAC
< prev
next >
Wrap
Text File
|
1994-04-09
|
26KB
|
795 lines
MOSTHOST.MAC
by Shad Muegge,
{COMMO} registration number 24
{:setup} * Set up MOSTHOST options
-------------------------------------------------------------------------------
-Configuration Items--------------Description----------------------------------
-------------------------------------------------------------------------------
{LIGH Y} Modem signal lights
{SETV dospassword,PASSWORD} Password to access the DOS menu
{SETV filedir,%_home%MHFILE\} Directory for file transfer files
{SETV datadir,%_home%MHDATA\} Directory for host data files (passwords)
{SETV hotkeys,n} Hot keys (y/n)
{SETV autobaud,n} Autobaud (set to no for locked serial port)
{SETV inact_time,120} Inactivity timer, seconds, 0=none
{SETV attention_string,AT|} String to get the modem's attention
{SETV ring_string,RING} String sent from modem to indicate a ring
{SETV connect_string,CONNECT} Result string for a successfull connection
-------------------------------------------------------------------------------
{SETV pr_alarm,0} * Turn off protocol alarms
{SETV pr_down,%filedir} * Protocol download path
{SETV pr_up,%filedir} * Protocol upload path
{CLEA}
{LOCA n}
{SPOC y}
{DISP 1,1,7,Setup|}
{SETE WF5}
{SEND %attention_string} * Make sure the PARAM takes effect
{IFEX %datadir%DATA.MHS,ST2} * Check for data file
{SETV userno,0}
{CALL write_data}
{:ST2}
{local y}
{RETURN}
--------------------------------------------* General functions ---------------
{:cls} * Clear the screen
{SEND ^L}
{RETURN}
{:press_any_key} * Pause until a key is pressed
{SEND ^J^MPress Any Key:}
{SETG %inact_time,time_out}
{GETS-H temp,1,PK}
{:PK} {setv temp}
{SEND ^J^M}
{RETURN}
{:dsp_file} * Display a file
{IFEX %dump_file,,DF5} * IN: %dump_file
{SETV count,0}
{ROPE %dump_file,DF3}
{:DF1} {READ dline}
{SEND ^M%dline^J^M}
{INCR count}
{COMP count,23} {IFCO DF4}
{GOTO DF1}
{:DF2} {RCLOSE}
{:DF3} {SETV dline}
{SETV ch}
{SETV count}
{RETURN}
{:DF4} {SETV count,0}
{SEND ^MMore [Y],N,C: }
{CALL get_key}
{IFCO DF1}
{COMP ch,n} {IFCO DF2}
{COMP ch,y} {IFCO DF1}
{COMP ch,c} {IFCO ,DF4}
{SETV count,26}
{GOTO DF1}
{:DF5} {SEND ^J^M^GError: File not found: %dump_file}
{CALL press_any_key}
{RETURN}
{:menu} * Get menu selection
{SEND %prompt [%_tim]: } * OUT: %ch
{SETG %inact_time,time_out} * %ch = ~, if user hit CR at prompt
{CALL get_key}
{IFCO MN1}
{SEND ^J^M}
{COMP ch,*} {IFCO time_out}
{GOTO MN2}
{:MN1} {SETV ch,~}
{SEND ^J^M}
{:MN2} {RETURN}
{:get_key}
{COMP hotkeys,y} {IFCO GK1}
{GETS ch,1}
{GOTO GK2}
{:GK1} {GETS-H ch,1}
{:GK2} {COMP ch}
{RETURN}
{:get_protocol} * Get protcol selection
{PAUS-T 2}
{CALL cls} * OUT: %protocol
{SEND ┌───────────────────────────────────────────────────┐^J^M}
{SEND │ Protocols │^J^M}
{SEND └───────────────────────────────────────────────────┘^J^M}
{SEND [Y] Ymodem^J^M}
{SEND [G] Ymodem-G^J^M}
{SEND [X] Xmodem^J^M}
{SEND [Z] Zmodem^J^M}
{SEND [H] HS/Link^J^M^J^M}
{SETV prompt,Protocol:}
{CALL menu}
{COMP ch,~} {IFCO PG2}
{COMP ch,z} {IFCO PG1}
{COMP ch,y} {IFCO PG1}
{COMP ch,g} {IFCO PG1}
{COMP ch,x} {IFCO PG1}
{COMP ch,h} {IFCO ,PG2}
{:PG1} {SETV protocol,%ch}
{:PG2} {RETURN}
{:send_hslink} * HSLINK download subroutine
{SEND ^J^MStart your HS/Link download now.^J^M}
{CALL h_send}
{COMP %_err,0}
{RETURN}
{:send_zmodem} * ZMODEM download subroutine
{SEND ^J^MStart your Zmodem download now.^J^M}
{CALL z_send}
{COMP %_err,0}
{RETURN}
{:send_ymodem} * YMODEM download subroutine
{SEND ^J^MStart your Ymodem download now.^J^M}
{CALL yb_send}
{COMP %_err,0}
{RETURN}
{:send_xmodem} * XMODEM-1K download subroutine
{SEND ^J^MStart your Xmodem download now.^J^M}
{IFEX %pr_file,,SX1}
{CALL xk_send}
{COMP %_err,0}
{:SX1} {RETURN}
{:recv_hslink} * HSLINK upload subroutine
{SEND ^J^MStart your HS/Link upload now.^J^M}
{CALL h_recv}
{COMP %_err,0}
{RETURN}
{:recv_zmodem} * ZMODEM upload subroutine
{SEND ^J^MStart your Zmodem upload now.^J^M}
{CALL z_recv}
{COMP %_err,0}
{RETURN}
{:recv_ymodem} * YMODEM upload subroutine
{SEND ^J^MStart your Ymodem upload now.^J^M}
{CALL yb_recv}
{COMP %_err,0}
{RETURN}
{:recv_yg} * YMODEM-G upload subroutine
{SEND ^J^MStart your Ymodem-G upload now.^J^M}
{CALL yg_recv}
{COMP %_err,0}
{RETURN}
{:recv_xmodem} * XMODEM-1K upload subroutine
{SEND ^J^MStart your Xmodem upload now.^J^M}
{CALL xc_recv}
{COMP %_err,0}
{RETURN}
{:transfer_file} * Transfer a file upload & download
{PUSH DL2}
{COMP proto,sz} {IFCO send_zmodem} * IN: %proto
{COMP proto,sy} {IFCO send_ymodem} * s + %protocol for downloads
{COMP proto,sg} {IFCO send_ymodem} * r + %protocol for uploads
{COMP proto,sx} {IFCO send_xmodem}
{COMP proto,sh} {IFCO send_hslink}
{COMP proto,rz} {IFCO recv_zmodem}
{COMP proto,ry} {IFCO recv_ymodem}
{COMP proto,rg} {IFCO recv_yg}
{COMP proto,rx} {IFCO recv_xmodem}
{COMP proto,rh} {IFCO recv_hslink}
{SEND ^J^MInvalid protocol ^J^M}
{CALL press_any_key}
{COMP proto,sz} * Set a bad condition for return
{:DL1} {SETV proto}
{POPS}
{RETURN}
{:DL2} {PAUS 2}
{RETURN}
{:get_name}
{:GN1} {SEND ^J^MEnter your real name: } * Get a name from user
{SETG %inact_time,time_out} * OUT: %lname
{GETS lname,16,GN1}
{RETURN}
{:get_password} * Get a password
{SETG %inact_time,time_out}
{:GP1} {GETS-P pass,8}
{RETURN}
{:time_out} * Time out user
{POPS-C} * Clear the stack
{GOTO gby}
{:write_user} * Write the user file
{WOPE %datadir%%password.MHS} * IN: %login_name
{WRIT %login_name} * IN: %userno
{WRIT %userno} * IN: %new_start
{WRIT %new_start} * IN: %protocol
{WRIT %protocol}
{WCLO}
{RETURN}
{:read_user} * Read the user file
{ROPE %datadir%%password.MHS,RU1} * OUT: %login_name
{READ %login_name} * OUT: %userno
{READ %userno} * OUT: %new_start
{READ %new_start} * OUT: %protocol
{READ %protocol}
{RCLOSE}
{:RU1} {RETURN}
{:write_data} * Write data file
{WOPE %datadir%DATA.MHS} * IN: %userno
{WRIT %userno} * IN: %mhigh
{WRIT %mhigh}
{WCLO}
{RETURN}
{:read_data} * Read data file
{ROPE %datadir%DATA.MHS,RD1} * OUT: %userno
{READ %userno} * OUT: %mhigh
{READ %mhigh}
{RCLO}
{:RD1} {RETURN}
--------------------------------------------* Login functions -----------------
{:new_user} * Get new user information
{CALL cls} * OUT: %login_name
{:NU4} * OUT: %password
* OUT: %userno
{SEND Welcome to the host with the most. Enter your name and password.^J^M}
{:NU0} {CALL get_name} * OUT: %new_start
{SETV login_name,%lname} * OUT: %protocol
{SETV lname}
{:NU1} {SEND ^J^MEnter your password: }
{GETS password,8,NU0}
{IFEX %datadir%%password.MHS,,NU3}
{SEND ^J^MInvalid password, try something different.}
{GOTO NU1}
{:NU3} {INCR userno}
{SETV new_start,1}
{CALL get_protocol}
{SEND ^J^MSaving user information.}
{CALL write_user}
{SEND ^J^MRe-enter your name and password for verification.}
{RETURN}
{:login_user} * Login user
{PUSH} * OUT: %SUCCESS
{SETV SUCCESS} * OUT: %login_name
{SETV tries,0} * OUT: %password
{:LU0} {INCR tries} * OUT: %userno
{COMP tries,3} {IFCO-G LU4} * OUT: %new_start
* OUT: %protocol
{SEND ^J^Mlogin: }
{SETG %inact_time,time_out}
{GETS lname,16,LU0}
{COMP lname,new} {IFCO new_user}
{SEND ^J^Mpassword: }
{CALL get_password}
{SETV password,%pass}
{:LU2} {SEND ^J^M}
{IFEX %datadir%%password.MHS,,LU0}
{CALL read_user}
{COMP login_name,%lname}
{IFCO ,LU0}
{SETV SUCCESS,true}
{:LU4} {SETV tries}
{SETV lname}
{SETV pass}
{POPS}
{RETURN}
--------------------------------------------* Dos functions--------------------
{:change_dir} * Change Dir
{SEND ^J^MCD }
{SETG %inact_time,time_out}
{GETS cd,70,CD1}
{EXEC-N CD %cd}
{:CD1} {SETV cd}
{RETURN}
{:do_dir} * Directory
{CALL cls}
{SEND ^J^MDIR }
{SETG %inact_time,time_out}
{GETS dir,70}
{EXEC-N DIR %dir > %datadir%DIR.TMP}
{SETV dump_file,%datadir%DIR.TMP}
{CALL dsp_file}
{CALL press_any_key}
{SETV dir}
{RETURN}
{:type_file} * Type a file
{CALL cls}
{SEND ^J^MTYPE }
{SETG %inact_time,time_out}
{GETS type,70,TF1}
{SEND ^J^M}
{SETV dump_file,%type}
{CALL dsp_file}
{CALL press_any_key}
{:TF1} {SETV type}
{RETURN}
{:erase_file} * Erase a file
{SEND ^J^M^J^M(CR to abort)}
{SEND ^J^MERASE }
{SETG %inact_time,time_out}
{GETS erase,70,EF1}
{COMP erase,*.*}
{IFCO ,EF4}
{SEND ^J^M*.* not allowed!}
{CALL press_any_key}
{GOTO EF1}
{:EF4} {IFEX %erase,,EF2}
{SEND ^J^MErase %erase (Y/N): }
{:EF3} {CALL get_key}
{IFCO EF3}
{COMP ch,y} {IFCO ,erase_file}
{EXEC-N ERASE %erase > nul}
{GOTO EF1}
{:EF2} {SEND ^J^MFile not found.}
{GOTO erase_file}
{:EF1} {SETV erase}
{RETURN}
{:copy_file} * Copy a file
{SEND ^J^MCOPY }
{SETG %inact_time,time_out}
{GETS copy,70,CF1}
{EXEC-N COPY %copy > nul}
{:CF1} {SETV copy}
{RETURN}
{:rename_file} * Rename a file
{SEND ^J^MREN }
{SETG %inact_time,time_out}
{GETS ren,70,RF1}
{EXEC-N REN %ren > nul}
{:RF1} {SETV ren}
{RETURN}
{:exit_to_dos} * Exit to dos with DOORWAY.EXE
{COMP mspeed,local}
{IFCO EX1}
{EXEC-S DOORWAY PORT:%_pad:%_irq /M:60 /G:ON /A:ON /V:D^U /O:T /S:* /C:DOS}
{GOTO EX2}
{:EX1} {SHELL}
{:EX2} {RETURN}
{:dos_download} * Download a file
{SETV proto} * IN: %protocol
{COMP protocol,}
{IFCO ,DD1}
{CALL get_protocol}
{:DD1} {SEND ^J^MFile: }
{SETG %inact_time,time_out}
{GETS pr_file,70,DD2}
{SETV proto,s%protocol}
{SETV save_filedir,%filedir}
{SETV filedir}
{CALL transfer_file}
{CALL cls}
{SETV filedir,%save_filedir}
{SETV save_filedir}
{IFCO DD2}
{SEND ^J^MUnsuccessfull download}
{CALL press_any_key}
{:DD2} {SETV pr_file}
{RETURN}
{:dos_upload} * Upload a file
{SETV proto} * IN: %protocol
{COMP protocol,}
{IFCO ,DU1}
{CALL get_protocol}
{:DU1} {COMP protocol,x}
{IFCO ,DU2}
{SEND ^J^MFile: }
{SETG %inact_time,time_out}
{GETS pr_file,70,DU3}
{:DU2} {SETV proto,r%protocol}
{SETV save_filedir,%filedir}
{SETV filedir}
{CALL transfer_file}
{CALL cls}
{SETV filedir,%save_filedir}
{SETV save_filedir}
{IFCO DU3}
{SEND ^J^MUnsuccessfull upload}
{CALL press_any_key}
{:DU3} {SETV pr_file}
{RETURN}
{:log_drive} * Log a drive
{SEND ^J^MChange to which drive (A:, B:, C:, etc): }
{SETG %inact_time,time_out}
{GETS log,2,LD2}
{:LD1} {SEND ^J^MChange to drive %log (Y/N)? }
{SETG %inact_time,time_out}
{CALL get_key}
{IFCO LD1}
{COMP ch,n} {IFCO LD2}
{COMP ch,y} {IFCO ,LD1}
{EXEC-N %log}
{:LD2} {SETV log}
{RETURN}
{:dos_stuff} * Dos Menu
{SEND ^J^MDos password: }
{CALL get_password}
{COMP pass,%dospassword}
{IFCO ,DS3}
{PUSH}
{:DS1}
{PAUS-T 2}
{CALL cls}
{SEND ┌───────────────────────────────────────────────────┐^J^M}
{SEND │ DOS Commands │^J^M}
{SEND └───────────────────────────────────────────────────┘^J^M}
{SEND [A] Log New Drive^J^M}
{SEND [C] Change Dir [U] Upload to current dir^J^M}
{SEND [D] Directory [V] Download from current dir^J^M}
{SEND [E] Erase File^J^M}
{SEND [K] Copy File [Z] Run DOORWAY program (shell^J^M}
{SEND [T] Type File to DOS in local mode)^J^M}
{SEND [R] Rename File^J^M^J^M}
{SETV prompt,DOS (CR to return)}
{CALL menu}
{COMP ch,~} {IFCO DS2}
{COMP ch,a} {IFCO log_drive}
{COMP ch,c} {IFCO change_dir}
{COMP ch,d} {IFCO do_dir}
{COMP ch,e} {IFCO erase_file}
{COMP ch,k} {IFCO copy_file}
{COMP ch,r} {IFCO rename_file}
{COMP ch,t} {IFCO type_file}
{COMP ch,u} {IFCO dos_upload}
{COMP ch,v} {IFCO dos_download}
{COMP ch,z} {IFCO exit_to_dos}
{GOTO DS1}
{:DS2} {POPS}
{:DS3} {SETV pass}
{SETV prompt}
{RETURN}
--------------------------------------------* Xfer functions-------------------
{:dfiles} * Download a file
{SETV proto} * IN/OUT: %protocol
{COMP protocol,}
{IFCO ,DX1}
{CALL get_protocol}
{:DX1} {SEND ^J^MFile: }
{SETG %inact_time,time_out}
{GETS pr_file,70,DX2}
{SETV pr_file,%filedir%%pr_file}
{SETV proto,s%protocol}
{CALL transfer_file}
{CALL cls}
{IFCO DX2}
{SEND ^J^MUnsuccessfull download}
{CALL press_any_key}
{:DX2} {SETV pr_file}
{RETURN}
{:ufiles} * Upload a file
{SETV proto} * IN/OUT: %protocol
{SETV pr_file,%filedir}
{COMP protocol,}
{IFCO ,UF1}
{CALL get_protocol}
{:UF1} {COMP protocol,x}
{IFCO ,UF2}
{SEND ^J^MFile: }
{SETG %inact_time,time_out}
{GETS dfiles,70,UF3}
{SETV pr_file,%pr_file%%dfiles}
{IFEX %pr_file,,UF2}
{SEND ^J^MFile already exists!^J^M}
{CALL Press_Any_Key}
{GOTO UF3}
{:UF2} {SETV proto,r%protocol}
{CALL transfer_file}
{CALL cls}
{IFCO UF3}
{SEND ^J^MUnsuccessfull upload}
{CALL press_any_key}
{:UF3} {SETV pr_file}
{SETV dfiles}
{RETURN}
-------------------------------------------------------------------------------
{:chat} * Chat w/word wrap
{SETG inact_time,time_out}
{BEEP} {BEEP} {BEEP}
{SETV chatc,3}
{SEND ^J^M^J^M(Type 'bye' to exit chat mode)^J^M}
{SEND ^J^M1> Hi %login_name, what's up?}
{SEND ^J^M2>}
{:CT1} {SETV chatl}
{:CT2} {SEND ^J^M%chatc> %chatl}
{INCR chatc}
{GETS-AH chatl,70}
{COMP chatl,bye} {IFCO CT5}
{LENGTH %chatl}
{COMP %_len,69} {IFCO-LE CT1}
{SETV x,71}
{:CT3} {DECR x}
{COMP x,50} {IFCO-LE CT1}
{SUBS ch,%x,1,%chatl}
{COMP ch, } {IFCO ,CT3}
{INCR x}
{SUBS chatl,%x,255,%chatl}
{:CT4} {COMP x,%_len} {IFCO-G CT2}
{SEND ^H ^H}
{INCR x}
{GOTO CT4}
{:CT5} {RETURN}
-------------------------------------------------------------------------------
{:time_online} * Elapsed time
{SEND ^J^MTime online: %_elap^J^M}
{CALL Press_Any_Key}
{RETURN}
--------------------------------------------* User info------------------------
{:chg_name} * Get new login name
{SEND ^J^M} * OUT: %lname
{:CN1} {CALL get_name}
{RETURN}
{:chg_password} * Get new password
{SEND ^J^M} * OUT: %pass
{:CP1} {SEND ^J^MNew password: }
{SETG %inact_time,time_out}
{GETS pass,8,CP1}
{COMP pass,%password} {IFCO CP2}
{IFEX %datadir%%pass.MHS,,CP2}
{SEND ^J^MInvalid password, try again.}
{GOTO CP1}
{:CP2} {RETURN}
{:chg_protocol} * Get new protocol
{CALL cls} * OUT: %protocol
{CALL get_protocol}
{RETURN}
{:save_user} * Save new information
{SEND ^J^MSaving} * IN: %lname,%pass,%protocol
{IFEX %datadir%%password.MHS,,SU1} * OUT: %login_name,%password
{EXEC-N DEL %datadir%%password.MHS} * OUT: %new_start,%uport
{:SU1} {SETV login_name,%lname}
{SETV password,%pass}
{SETV uprot,%protocol}
{CALL write_user}
{RETURN}
{:fil_dir}
{EXEC-N DIR %filedir%*.* > %datadir%DIR.TMP}
{SETV dump_file,%datadir%DIR.TMP}
{CALL dsp_file}
{CALL press_any_key}
{RETURN}
{:update_info} * User info menu
{SETV lname,%login_name}
{SETV pass,%password}
{SETV uprot,%protocol}
{PUSH}
{:UI1} {CALL cls}
{SEND ^J^M}
{SEND ^J^M1. User name: %lname}
{SEND ^J^M2. Password: %pass}
{SEND ^J^M3. Protocol: %protocol}
{SEND ^J^M}
{SEND ^J^MCommand (CR to return) [%_tim]: }
{SETG %inact_time,time_out}
{CALL get_key}
{IFCO UI2}
{COMP ch,1} {IFCO chg_name}
{COMP ch,2} {IFCO chg_password}
{COMP ch,3} {IFCO chg_protocol}
{GOTO UI1}
{:UI2} {SEND ^J^MSave changes (Y/N)? }
{CALL get_key}
{IFCO UI3}
{COMP ch,n} {IFCO UI3}
{COMP ch,y} {IFCO ,UI2}
{CALL save_user}
{:UI3} {POPS}
{SETV ch}
{SETV lname}
{SETV pass}
{SETV protocol,%uprot}
{RETURN}
-------------------------------------------------------------------------------
{:main_menu} * Main menu
{PUSH}
{:MM1}
{PAUS-T 2}
{CALL cls}
{SEND ┌───────────────────────────────────────────────────┐^J^M}
{SEND │ Main Menu │^J^M}
{SEND └───────────────────────────────────────────────────┘^J^M}
{SEND [D] Download Files [T] Time online^J^M}
{SEND [U] Upload Files [G] Goodbye^J^M}
{SEND [F] File List [S] DOS Menu^J^M}
{SEND [C] Chat [I] User Info^J^M}
{SEND [P] Protocol (%protocol)^J^M^J^M}
{SETV prompt,Main Menu}
{CALL menu}
{COMP ch,c} {IFCO chat}
{COMP ch,f} {IFCO fil_dir}
{COMP ch,s} {IFCO dos_stuff}
{COMP ch,g} {IFCO MM3}
{COMP ch,t} {IFCO time_online}
{COMP ch,i} {IFCO update_info}
{COMP ch,d} {IFCO dfiles}
{COMP ch,p} {IFCO get_protocol}
{COMP ch,u} {IFCO ufiles}
{GOTO MM1}
{:MM3} {SEND ^J^MAre you sure (Y/N)? }
{CALL get_key}
{IFCO MM1}
{COMP ch,y} {IFCO ,MM1}
{:MM2} {POPS}
{RETURN}
--------------------------------------------* Waiting for a call funcs--------
{:view_scroll}
{SCROLL}
{GOTO wait_for_call}
{:shell_dos}
{SHELL}
{GOTO wait_for_call}
{:wait_for_call}
{SPOC n}
{CLEAR}
{DISP 1,29,4E, HOST MODE }
{DISP 3,29,0E,The Host with the Most}
{DISP 4,29,0E, By Shad Muegge}
{DISP 8,29,0E, 1 - Login locally}
{DISP 9,29,0E, 2 - View Scrollback}
{DISP 10,29,0E, 3 - Shell to DOS}
{DISP 11,29,0E, Q - Quit}
{DISP 22,1,0E, Last user: %login_name (%mspeed)}
{DISP 24,29,4e, Waiting for a Call }
{DISP 20,1,, }
{DISP 20,1,0E, Command: }
{SETG 0,,l}
{:WF1} {GETS mring,10,WF1}
{DISP 24,29,07, }
{COMP mring,1} {IFCO WF4}
{COMP mring,2} {IFCO view_scroll}
{COMP mring,3} {IFCO shell_dos}
{COMP mring,q} {IFCO WF5}
{COMP mring,%ring_string} {IFCO ,Wait_for_call}
{SPOC y}
{DISP 24,29}
{SEND ~ATA^M~}
{SETL 45,wait_for_call}
{DISP 20,1,7, Waiting for connect: }
{COMP autobaud,y} {IFCO WF2}
{LOOK %connect_string}
{PAUS 1}
{RETURN}
{:WF2} {GOLO C012,%connect_string 1200^M}
{GOLO C024,%connect_string 2400^M}
{GOLO C048,%connect_string 4800^M}
{GOLO C096,%connect_string 9600^M}
{GOLO C192,%connect_string 19200^M}
{GOLO C384,%connect_string 38400^M}
{GOLO C576,%connect_string 57600^M}
{LOOK %connect_string^M}
{SETV mspeed,300}
{GOTO WF3}
{:C012} {SETV mspeed,1200} {GOTO WF3}
{:C024} {SETV mspeed,2400} {GOTO WF3}
{:C048} {SETV mspeed,4800} {GOTO WF3}
{:C096} {SETV mspeed,9600} {GOTO WF3}
{:C192} {SETV mspeed,19200} {GOTO WF3}
{:C384} {SETV mspeed,38400} {GOTO WF3}
{:C576} {SETV mspeed,57600}
{:WF3} {PARM %mspeed}
{PAUS 1}
{RETURN}
{:WF4} {SETV mspeed,LOCAL}
{local y}
{SPOC n}
{RETURN}
{:WF5} {CLEAR}
Clean up variables
{SETV userno} {SETV mring} {SETV filedir} {SETV mspeed}
{SETV new_start} {SETV login_name} {SETV password} {SETV dump_file}
{SETV password} {SETV protocol} {SETV prompt} {SETV ch}
{SETV datadir} {SETV dospassw} {SETV protodir} {SETV autobaud}
{SETV mhigh} {SETV chatc} {SETV chatl} {SETV x}
{SETV inact_time} {SETV proto} {SETV uprot} {SETV hotkeys}
{SETV connect_string} {SETV attention_string} {SETV ring_string}
{LOCA n}
{UNLOad}
--------------------------------------------* Main BBS loop ------------------
{:BBS}
{CALL setup}
{CALL Wait_For_Call}
{CALL cls}
{SETV userno}
{SEND ^J^M HOST MODE^J^M^J}
{SEND Written in ^(COMMO^) macro language^J^M^J^J}
{SEND New users type 'NEW'^J^M^J^M}
{CALL read_data}
{CALL login_user}
{COMP success,TRUE}
{IFCO ,gby}
{:BB0} {ELAP}
{CALL main_menu}
{:gby}
{SEND ^J^M^JThanks for calling...^J^M}
{HANG y}
{COMP success,TRUE}
{IFCO ,hng}
{SEND Saving}
{CALL write_user}
{CALL write_data}
{:hng} {SETV success}
{GOTO BBS}
- end -