Short: Phonebook/dialer for VLT Uploader: rick@emma.panam.wimsey.com (Rick Younie) Author: rick@emma.panam.wimsey.com (Rick Younie) Type: comm/term Replaces: comm/term/VLTele1p0.lha Requires: ral3p3.lha, arp40_2.lha Version: 1.1 VLTele is a gadget-based phonebook and dialer, in ARexx, for VLT. It requires rexxarplib.library (ral3p3.lha) and arp.library (arp40_2.lha). arp40_2.lha is an arp.library replacement and only works on 2.0+ systems as it redirects calls to their equivalent functions in the 2.0+ asl.library. Main features: - gadget selection of phone numbers - on connection, all gadgets for that system are deselected - phonebook is easily edited - automatic name/password sending - easy scripting INDEX ----- I. To Test II. Installing for real III. Usage IV. The Phonebook V. Script Pairs VI. Control Gadgets VII. Odds and Ends VIII. Disclaimer/Contact Info I. To Test ------- To see if VLTele is something you might like, and that you have the proper libraries and so on, you can try the following. VLT should _not_ be running for this. - make sure rexxarplib.library, rexxsupport.library and arp.library are in LIBS: - move VLTele.phones to VLT:phonebook/ - RX VLTele.vlt VLTele should come up on the workbench in a few seconds. NOTE: Press the QUI gadget _only_. VLTele wants to use VLT's message function for some other gadgets and it will get unhappy that it's not there. If it doesn't come up, some possible problems are: - RX is not in your path. (You can find it in SYS:REXXC/). - ARexx isn't running and rexxmast isn't in the path (RX will start ARexx for you, if it can find rexxmast). [To use VLTele for real, ARexx _must_ being running or VLT won't be able to run VLTele (or any other ARexx script). Putting SYS:System/Rexxmast in SYS:WBSTARTUP and rebooting will start ARexx for you.] - If you get the error "Error return from function", you've got library trouble. Remember that you need arp.library for rexxarplib.library to work. You also need to have rexxsupport.library and rexxarplib.library in LIBS: (VLTele will load these for you). If you can't get it up, I may be able to help in email. II. Installing for real ------------------- A. Put these files on your system: VLTele.vlt ==> VLT:rexx/ VLTele.phones ==> VLT:phonebook/ rexxsupport.library ==> LIBS: rexxarplib.library ==> LIBS: arp.library ==> LIBS: B. Make sure ARexx is running. Drag REXXMAST to SYS:WBSTARTUP and reboot. C. Do a key assignment in VLT. Go into Program Mode (in the first VLT drop-down menu). Press the desired function key. Enter this in the requester: ~@VLTele.vlt #Phone Book (VLTele) Remember to turn Program Mode off afterwards. III. Usage ----- I start VLT and VLTele with the following alias. (Substitute VLT for VLTjr if you're using the full version.): Alias VLT "run >NIL: VLT:VLTjr +c ~@VLTele.vlt" IV. The Phonebook ------------- NOTE: don't use tabs in the phonebook. The phonebook is in the following format: # BBS Name #Phone #Baud #Par#Script Pairs {[]=[]} # # # # # System1 555-1234 38400 8N1 {[login:]=[yourname*R]} {[password:]=[yourpass*R]} The #'s in the first line tell VLTele where each field in the phonebook starts. (If there are tabs it gets confused. Don't use them.) V. Script Pairs ------------ Format: {[ ]=[ ]} ^ ^ | | | second argument first argument The script pairs are parsed on three 'characters': '{[', ']=[', and ']}'. So it's ok to use {, [, = and so on as pairs arguments. There are two types of script pairs: A. If the first argument is given, it is an expect/send pair. The first argument, xxx, is quoted and sent to VLT as the argument of a 'wait' command. The second argument is quoted and sent as the argument of a 'send' command. {[xxx]=[yyy]} translates to wait "xxx"; send "yyy" e.g. {[login:]=[yourname*R]} translates to wait "login:";send "yourname*R" B. If there is no first argument, the second argument is sent to VLT directly. {[]=[yyy]} e.g. {[]=[delay 3;send "*R"]} - tells VLT to wait 3 seconds, then send a CR e.g. {[]=[capture append t:cap]} - open a capture file e.g. {[]=[@script.rexx]} - execute the ARexx script 'script.rexx' NOTE: The ESC key aborts pairs matching and script file execution. You'll want to use this if, for example, the login fails or a script hangs. The ESC belongs to VLT so you have to be off the VLTele window when you use it. If the script field has no {[]=[]} skeletons or if the field begins with a # character, the whole field is ignored. VI. Control Gadgets --------------- DIA CNL CON HID EDI LOA HLP QUI DIA - dial the phone numbers that are lit CNL - if VLT has carrier, it hangs up; if not it causes VLTele to stop dialing CON - if lit, it continues to dial after the current call is completed; if not, the current call is the last one HID - hides VLTele -- that is it closes VLTele's gadget window. VLTele stays in memory and can be popped up by sending it a message -- see Odds and Ends below. EDI - edit the phonebook. The default editor is Ed, the editor that comes with the system software. You can change this in the program. The editor must be set to cling to the cli. LOA - brings up a requester so you can load another phonebook HLP - shows this information in a message window on VLT QUI - causes VLT to quit; removes it completely. You have to quit VLTele before VLT can go away. Use ESC key (with cursor off VLTele window) to abort hung scripts. VII. Odds and Ends ------------- VLTele opens a message port (VLTELE) and stays in memory, sitting on a waitpkt() waiting for something to do. This costs almost nothing in terms of cpu cycles. The only real cost is the memory that VLTele takes up. When it appears to come in and out, it is just the gadget window opening and closing. The '~@VLTele.vlt' function key assignment mentioned in II. C. starts a second copy of VLTele. This second copy sees that another copy is already running, send it a POPUP command and then exits. A more elegant way to popup the gadget window is to send VLTele's port a POPUP message directly. You can do this by assigning the following to a VLT function key (see II. C.): ~RX "address VLTELE POPUP The VLTele window re-opens after a call by setting a trap for "NO CARRIER". If you use an Amiga-h VLT hangup, the trap doesn't trip and you will have to send the popup message described above. A way to do both a hangup and popup together is: ~RX "address VLTELE POPUP;hangup VIII. Disclaimer/Contact Info ----------------------- Disclaimer: I've used the program for over a year and it has been solid. But you're going to have to satisfy yourself that it works ok for you. If you use this, please email me at rick@emma.panam.wimsey.com (Rick Younie) rick@freenet.vancouver.bc.ca (Rick Younie)