home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Computerworld 1996 March
/
Computerworld_1996-03_cd.bin
/
idg_cd3
/
aplikace
/
komunika
/
telixwin
/
tfw.5
/
SETUP.SLT
< prev
next >
Wrap
Text File
|
1995-07-28
|
6KB
|
346 lines
/****************************************************************/
/* */
/* Demo of how to alter many of the configuration options of */
/* TFW from a SALT script. This one needs few comments. */
/* */
/* Copyright 1995 deltaComm Development, Inc. */
/* */
/****************************************************************/
main()
{
str ss[80]; // variable declarations
int cc;
prints();
prints("Just press <enter> for no change.");
prints();
printsc("Image File name: ");
gets(ss);
if (ss !="")
_image_file=ss;
prints();
printsc("Capture File name: ");
gets(ss);
if (ss !="")
_capture_fname=ss;
prints();
printsc("Usage Log File name: ");
gets(ss);
if (ss !="")
_usage_fname=ss;
prints();
printsc("Dialing Prefix 1: ");
gets(ss);
if (ss !="")
_dialpref=ss;
prints();
printsc("Dialing Prefix 2: ");
gets(ss);
if (ss !="")
_dialpref2=ss;
prints();
printsc("Dialing Prefix 3: ");
gets(ss);
if (ss !="")
_dialpref3=ss;
prints();
printsc("Dialing Suffix: ");
gets(ss);
if (ss !="")
_dialpost=ss;
prints();
printsc("Stop Dialing String: ");
gets(ss);
if (ss !="")
_redial_stop=ss;
prints();
printsc("Telix Directory: ");
gets(ss);
if (ss !="")
_telix_dir=ss;
prints();
printsc("Script Directory: ");
gets(ss);
if (ss !="")
_script_dir=ss;
prints();
printsc("Modem Answer String: ");
gets(ss);
if (ss !="")
_auto_ans_str=ss;
prints();
printsc("Modem Hangup String: ");
gets(ss);
if (ss !="")
_mdm_hang_str=ss;
prints();
printsc("Modem Connect String: ");
gets(ss);
if (ss !="")
_connect_str=ss;
prints();
printsc("Modem Init String: ");
gets(ss);
if (ss !="")
_mdm_init_str=ss;
prints();
printsc("No Connect String 1: ");
gets(ss);
if (ss !="")
_no_connect1=ss;
prints();
printsc("No Connect String 2: ");
gets(ss);
if (ss !="")
_no_connect2=ss;
prints();
printsc("No Connect String 3: ");
gets(ss);
if (ss !="")
_no_connect3=ss;
prints();
printsc("No Connect String 4: ");
gets(ss);
if (ss !="")
_no_connect3=ss;
prints();
printsc("Answer back String: ");
gets(ss);
if (ss !="")
_answerback_str=ss;
prints();
printsc("Wait for connect(sec): ");
gets(ss);
cc=stoi(ss);
if (ss !="")
_dial_time=cc;
prints();
printsc("Time between attempts(sec): ");
gets(ss);
cc=stoi(ss);
if (ss !="")
_dial_pause=cc;
prints();
prints();
prints(" (Y)es (N)o (C)ancel");
prints();
printsc("Add line feed to each line? ");
cc=inkeyw(); // Read in a keypress
toupper(cc); // Make sure it's upper case
if (cc=="Y")
_add_lf=1;
else if (cc=="N")
_add_lf=0;
prints();
printsc("Echo Terminal characters? ");
cc=inkeyw();
toupper(cc);
if (cc=="Y")
_local_echo=1;
else if (cc=="N")
_local_echo=0;
prints();
printsc("Strip High Terminal characters? ");
cc=inkeyw();
toupper(cc);
if (cc=="Y")
_strip_high=1;
else if (cc=="N")
_strip_high=0;
prints();
printsc("Destructive Backspace? ");
cc=inkeyw();
toupper(cc);
if (cc=="Y")
_dest_bs=1;
else if (cc=="N")
_dest_bs=0;
prints();
printsc("Swap BSP/Cntrl-BSP? ");
cc=inkeyw();
toupper(cc);
if (cc=="Y")
_swap_bs=1;
else if (cc=="N")
_swap_bs=0;
prints();
printsc("Allow Users to Cancel Scripts? ");
cc=inkeyw();
toupper(cc);
if (cc=="Y")
_scr_chk_key=1;
else if (cc=="N")
_scr_chk_key=0;
prints();
prints();
prints(" ASCII Transfer options:");
printsc("Echo Characters? ");
cc=inkeyw();
toupper(cc);
if (cc=="Y")
_asc_secho=1;
else if (cc=="N")
_asc_secho=0;
prints();
printsc("Expand blank lines? ");
cc=inkeyw();
toupper(cc);
if (cc=="Y")
_asc_sexpand=1;
else if (cc=="N")
_asc_sexpand=0;
prints();
printsc("Strip high character? ");
cc=inkeyw();
toupper(cc);
if (cc=="Y")
_asc_striph=1;
else if (cc=="N")
_asc_striph=0;
prints();
printsc("Allow Z-modem Auto-Downloads? ");
cc=inkeyw();
toupper(cc);
if (cc=="Y")
_zmod_auto=1;
else if (cc=="N")
_zmod_auto=0;
prints();
printsc("Z-modem Download Crash Recovery? ");
cc=inkeyw();
toupper(cc);
if (cc=="Y")
_zmod_rcrash=1;
else if (cc=="N")
_zmod_rcrash=0;
prints();
printsc("Z-modem Upload Crash Recovery? ");
cc=inkeyw();
toupper(cc);
if (cc=="Y")
_zmod_scrash=1;
else if (cc=="N")
_zmod_scrash=0;
prints();
prints();
prints(" <Enter> for no change:");
prints();
printsc(" Remote Abort Character:");
gets(ss);
if (ss !="")
_ASC_REMABORT=ss;
prints();
printsc(" Time Between Characters(ms):");
gets(ss);
if (ss !="")
_ASC_SCPACING=stoi(ss);
prints();
printsc(" Time Between Lines(Tenths/sec):");
gets(ss);
if (ss !="")
_ASC_SLPACING=stoi(ss);
prints();
printsc(" Response Between Lines Character:");
gets(ss);
if (ss !="")
_ASC_SPACECHR=ss;
prints();
prints();
prints(" For the following:");
prints(" 0:Do Nothing");
prints(" 1:Strip");
prints(" 2:Add Line");
prints(" Press <space> for no change");
prints();
printsc(" CR during ASCII Recieve:");
cc=inkeyw(); // Read character
if (not cc==" ") // Test if changes needed
{
cc=stoi(cc); // Convert to integer
_asc_rcrtrans=cc; // Update variable
}
prints();
printsc(" LF during ASCII Recieve:");
cc=inkeyw();
if (not cc==" ")
{
cc=stoi(cc);
_asc_rlftrans=cc;
}
prints();
printsc(" CR during ASCII Send:");
cc=inkeyw();
if (not cc==" ")
{
cc=stoi(cc);
_asc_scrtrans=cc;
}
prints();
printsc(" LF during ASCII Send:");
cc=inkeyw();
if (not cc==" ")
{
cc=stoi(cc);
_asc_slftrans=cc;
}
prints();
}