; segments note when we are done we are in CODE ;============================================================= stack segment stack ; keep MS link happy by providing null stack stack ends ;============================================================== CODE segment PARA ; start off in code. ;============================================================== data segment word ; provide a separate DATA segment ; Even though it appears in the source ; before the code, it the COM file it ; will appear at the end. This is as dodge ; to avoid forward references that confuse ; MASM. FirstData label Word data ends ;============================================================== ; M A S T E R C O N T R O L T A B L E ; ; Controls which commands will be accepted and which routines will ; handle them. ; To add new commands to NEED, you simply must add a line to this table ; and write a handler routine. You can share the error messages with another ; class of commands or provide your own. All commands in a class share a ; common pair of error messages and a common testing routine. ; The class name provides the link. ; ; The Classname must be mentioned as the first parameter on each of the ; ACCEPT macros. In addition, your corresponding TEST routine ; must be called 'Testxxxx' where xxxx is the class name. ; You must also write a routine calld 'Displayxxxx' to display the current ; state of the test. ; ; - Aux input is just a number passed to the test routine. It is primarily ; used when many comands all share the same test routine. It lets the routine ; know in a quick way which command was used. It is mainly used to pass the ; drive letter to the free disk space routine. The same slot is also used ; for an unrelated purpose, to encode an implied level wanted -- e.g. ; that an SX is the same as asking for a level 300 CPU. ; ; - Bang,Plus,Minus are bit masks that say whether this command ; accepts each of ! + or - suffixes. The parser checks ; for the presence of switches and validates them. It applies defaults then ; it summarizes their presence in OkMask. ; ; - CapacityStyle says a 32 bit Capacity suffix may follow, separated by a ; colon, and trailed by an M, K or MB e.g. /EXT:2,304K ; Commas ignored (dots ignored in Norway). ; Parser stores this in 32-bit 'TheCapacity' for the handler routine. ; ; - VersionStyle says trailing digits e.g. DOS3.2 should be converted to ; integer with implied two decimal places, e.g. 320. ; Parser stores this in 16-bit 'TheVersion' for the handler routine. ; ; - The ExtNames are stored separately from the main MCT. The ACCEPT macro ; handles this for you automatically. ; ; - the name of the testroutine is generated automatically as TestXXX where ; XXX is the class name. Table segment public MCTStart label word ; start of master control table Table ends ;============================================================== String segment public ; Strings come next String ends ;============================================================== com group code,data,Table,String ; force data segments to go at the end! assume CS:com,DS:com,ES:nothing,SS:com ; seg regs cover everything org 100H ; in Code segment ;==============================================================