TDBS Host and Application Extention Interface ÖÄÒÄ¿ ÖÄ¿ ÖÄ¿ Ò ÖÄÒÄ¿ ÖÄ¿ ÒÄÄ¿ Ä· ÖÄ¿ ÖÄ¿ ÒÄ¿ ÄÒÄ º º ³ º ³ º ³ º º º ³ ÇÄÂÙ º º ³ ÇÄ´ ÇÄÙ º Ð Ð Á ÓÄÙ Ð Á Ð Ð ÓÄÙ Ð Á ÄÐÄßÓÄÙ Ð Á Ð ÄÐÄ The TSR that couldn't be done! Written by: Alan McNamee A PRODUCT OF ADVANCED SYSTEMS RESEARCH This API is just a short introduction to the MONITOR TSR Application Host Interface. This is not a complete API at this time. A full API will be released once the work on the Line Patching features have been completed. Included with this file are 2 Program Source Codes. One is an example of the use of the other. The ASR_HOST.PRG file is a set of procedures that can be linked into your applications with the SET PROCEDURE TO command. This will allow you to initialize its public variables and then allow you access to the Monitor interface procedures. This is not required, but it will make understanding and using the TSR interface much easier. The EXAMPLE.PRG is a simple WHOSON Line program that uses the ASR_HOST interface procedures for its information. All of this requires the MONITOR1.ZIP file that contains the TSR and its associated datafiles. It is important to note that all updating of the TSR's databases is done without TBBS' knowledge. This means that if you open a datafile and read it, and then read it again without reopening it again, the values will not have changed. This is because TBBS has buffered the contents and since it is unaware of the updating it will not flush its buffer and reread the data. Also, with any keyboard handling of the console, you must be sure to always return the console back to panel 1 if the operation required a pagedown to another panel. Database field descriptions of the MONITOR TSR files: KEYBOARD.DBF ------------ SCANCODE C 254 Keybaord characters sent to the TBBS console. To send a function key, first send CHR(1), then the scancode. Use the scancodes returned by int 16h. Before writing to the KEYBOARD database, make sure that SCANCODE is empty. e.g. USE keyboard DO WHILE .NOT. EMPTY(scancode) USE keyboard ENDDO LINES.DBF --------- RELIABLE L 1 Does the line have a reliable connection? Reliable connections, usually is achieved with some form of error correction. CALLER C 17 Current user logged onto the line. BPS C 4 Connected baud rate. MENU C 4 Menu user is currently at. FUNCTION C 5 Function being run. The record number is the line number. MONITOR.DBF ----------- BBS C 34 Your BBS name. SNAPSHOT L 1 Are the performance monitors paused? IDLE N 3 System idle percent \ CPU N 3 System CPU usage percent > Should equal 100%. DISK N 3 System disk usage percent / RESP N 5 System response time in ms. TURN N 5 System turn around time in ms. THPT N 5 System throughput time in ms. TOTMSGS N 6 Total number of messages in system. LASTMSG N 6 Number of last messages. DELMSGS N 6 Number of deleted messages. NEXTCALL N 6 Number of the next call. SYSONDATE C 8 Last date SYSOP was on. SYSONTIME C 5 Last time SYSOP was on. LASTREAD N 6 Last message read by SYSOP. MSGSLEFT N 6 Number of messages left since SYSOP logon. CALLSCON N 6 Number of call since SYSOP logon. BASEMEM N 8 TBBS base memory in bytes. MSGINDEX N 8 Message index table memory in bytes. USERMEM N 8 User memory in bytes. USEREMS N 4 User EMS memory in K bytes. OMUDATA N 8 Option module user data in bytes. OMEMS N 4 Option module EMS memory in K bytes. UDLINE1 N 2 User line from in EMS memory. UDLINE2 N 2 User line to in EMS memory. OMLINE1 N 2 Option module line from in EMS memory. OMLINE2 N 2 Option module line to in EMS memory. QUANTA1 C 4 Quanta offset QUANTA2 C 4 Quanta offset QUANTA3 C 4 Quanta offset QUANTA4 C 4 Quanta offset QUANTA5 C 4 Quanta offset QUANTA6 C 4 Quanta offset QUANTA7 C 4 Quanta offset QUANTA8 C 4 Quanta offset QUANTA9 C 4 Quanta offset QUANTA10 C 4 Quanta offset QUANTAMS1 N 6 2 Quanta time in ms. QUANTAMS2 N 6 2 Quanta time in ms. QUANTAMS3 N 6 2 Quanta time in ms. QUANTAMS4 N 6 2 Quanta time in ms. QUANTAMS5 N 6 2 Quanta time in ms. QUANTAMS6 N 6 2 Quanta time in ms. QUANTAMS7 N 6 2 Quanta time in ms. QUANTAMS8 N 6 2 Quanta time in ms. QUANTAMS9 N 6 2 Quanta time in ms. QUANTAMS10 N 6 2 Quanta time in ms. PERLINE N 2 Performance line. PERCPU N 3 Performance CPU percent for line. PERDISK N 3 Performance disk percent for line. PERRESP N 5 Performance response in ms for line. PERTURN N 5 Performance turn around time in ms for line. PERTHPT N 5 Performance throughput time in ms for line. LINECPU N 8 2 Total CPU time used by line in seconds. LINEDISK N 8 2 Total disk time used by line in seconds. SYSIDLE N 8 2 System total idle time in seconds SYSCPU N 8 2 System total CPU time in seconds SYSDISK N 8 2 System total disk time in seconds TSRESET C 8 Time since reset. OVERVIEW C 64 Line overview. If the character is blinking (Sysop page), then the character is incremented by one. If the data cannot be monitored, or is not available the databases are blanked.