home *** CD-ROM | disk | FTP | other *** search
/ Audio 4.94 - Over 11,000 Files / audio-11000.iso / msdos / edit / modtech / modtech.doc < prev    next >
Encoding:
Text File  |  1994-03-16  |  4.1 KB  |  136 lines

  1.                     MODRES TECHNICAL INFORMATION
  2.             (C) Mark J Cox 1991
  3.             MODRES V2.00
  4.  
  5.  
  6. *** WATCH OUT FOR SLOW MACHINES! *** IF <12MHz then use with care ***
  7.  
  8. -----------------------------------------------------------------------
  9.  
  10. Uses functions 8220, 8221, 8222, 8223 etc.  on multiplex interrupt 02f
  11. All numbers in Hex except for the ones in decimal.
  12.  
  13. -----------------------------------------------------------------------
  14. ***** Installation check    
  15.  
  16. In:
  17. AX = 8220
  18.  
  19. Out:
  20. AX = 5722   if MODRES is installed,
  21. BX = version number (Version 1.10 would be 0110 )
  22. DX:CX
  23. Form a segment/offset pair, these point to the table of
  24. valid Output Devices which can be read (BUT NOT ALTERED) by
  25. the calling program.  See output struct.
  26. (0 is always the speaker, so can ignore DX and CX)
  27. -----------------------------------------------------------------------
  28.  
  29. ***** Service Module
  30.  
  31. Plays a module from memory, and returns - carries on playing
  32.  
  33. In:
  34. AX = 8220
  35. DX:CX = Segment/Offset of a structure called MODPARM
  36.  
  37. Out:
  38. AX = 5722 if there were no errors when initialising
  39.  
  40. --------------------------------------------------------------------------
  41.  
  42. ***** Whereami
  43.  
  44. Return details of where in MOD I am + if finished
  45.  
  46. In: AX = 08225
  47.  
  48. Out:
  49.  DL = [didi]      = 0 playing, 1 reached end or stopped
  50.  DH = [mp_speed]  = Speed of mod (6 isnormal etc)
  51.  BX = [pattpos]   = Position within pattern 0000-0400
  52.  CL = [songpos]   = Position within the song (Track 0,1,2,...)
  53.  
  54. --------------------------------------------------------------------------
  55.  
  56. ***** Stopme
  57.  
  58. Stops playing the MOD - you must do this before critical things like
  59. disk accesses etc.
  60.  
  61. In:
  62.  AX = 08266
  63.  
  64. -----------------------------------------------------------------------
  65.  
  66.  
  67. ***** OUTPUT DEVICE Structure
  68.  
  69. You can read this to determine what output device to use if you want to
  70. but you must never alter it.
  71.  
  72. 0 Output Device 0
  73. 33 Output Device 1
  74. ...
  75. Last output device has a 255 as its first character at +0.
  76.  
  77. +0..+18  String   String with the name of the output device.  Terminated with 0
  78. +19      Word     Ignore.  Always 0ffff
  79. +21      Word     If =0 then this means that this output device is not 
  80.                   available.
  81. +23..+32 String   Ignore
  82. +33 Next one
  83.  
  84. Example:
  85. 'PC SPEAKER         ',0, 0ffff, some word, ignore the rest.
  86. 'SOUNDBLASTER       ',.....
  87. 255
  88.  
  89. So the SOUNDBLASTER would be output device 1,  Check if +21=0 if not then
  90. you can make the default output device 1 by passing a 1 in the MODPARM
  91. routine.
  92.  
  93. -----------------------------------------------------------------------
  94.  
  95. ***** MODPARM Structure
  96.  
  97. Consists of 69 bytes
  98.  
  99. +0    Char    'M'
  100. +1     Char    'P'
  101. +2    Byte     Gives output device ( 0 = speaker, 3 = D/A stereo etc )
  102. +3/+4    Word     Segment of start of main module data
  103. +5/+6    Word    Segment of start of sample number 1
  104. ...
  105. +65/+66    Word     Segment of start of sample number 31
  106. +67    Byte    Which pattern to start playing from (0 to 127)
  107. +68    Byte     Function :  0 - play from pattern [+67] until end of song 
  108.                 1 - play pattern [+67] only 
  109. +69    Byte    Machine Speed:  0 - 10-12Mhz
  110.                 1 - 12-25Mhz (default)
  111.                 2 - 25Mhz+
  112.                 also            3 - Mixing speed 10kHz (fast 8Mhz machines)
  113.                                 4 - Mix speed 12kHz (10Mhz machines)
  114.                                 5 - Mix speed 13kHz
  115.                                 6 - Mix speed 8kHz (Test for 8Mhz machines)
  116.  
  117. +70     Byte    Allow >64k sample playing
  118.                                128 - Mod has samples >64k in it
  119.                               else - Mod has all samples <64k
  120.   
  121. The Segment that is passed as start of main module data must
  122. contain all the module (like when you load it normally) up to
  123. the start of the samples (ie from the name of the module, through
  124. to and including all the pattern data)
  125.  
  126. * Note:  ALL SAMPLES MUST START ON SEGMENT BOUNDARIES
  127.  
  128.  
  129.  
  130. ----------------------------------------------------------------------- 
  131.  
  132. THIS VERSION OF MODRES IS (C) MARK J COX 1991 AND MUST NOT BE DISTRIBUTED
  133. IN ANY FASHION BY ANY MEANS OR USED FOR ANYTHING COMMERCIAL WITHOUT PRIOR
  134. WRITTEN CONTRACT FROM MARK J COX.
  135.  
  136.