MGSDRV version 3.20+	Copyright(c) 1991-94 by Ain
			Copyright(c) 1997-2001 GIGAMIX
			Modified by Goripon & Influenza (GIGAMIX)
			Special tanks to Masaki Kiyono


* Preface *

 MGSDRV is a driver which allows you to play music (up to 17 voices) on
 MSX computers equipped with the following sound generators.

  - PSG
  - FM (MSX-MUSIC, YM-2413/OPLL)
  - SCC
   
 MGSDRV uses the VBLANK interrupt to play music alongside other processing that
 the MSX performs.

 This driver is free software. Anyone can enjoy it for free.

 There were widespread on Japanese networks in the 80s, many songs have been
 developed in this format.
 
 MGSDRV was developed by Ain and continued by Gigamix.

 Notes:
 - The SCC chip is a sound wave generator designed by Konami Corporation.
 - If you have any questions about MGSDRV, ask Gigamix.


* Required environment *

 - MSX1 (with 64kB or more), MSX2, MSX2+ or MSX turbo R
 - MSX-DOS 1, MSX-DOS 2 or Nextor DOS


* Method of use *

 MGSDRV (MGSDRV.COM) works under MSX-DOS 2 or newer.
 MGS files for driver v2.xx do not have the same format, they are not
 compatible.

 Under DOS1, the driver cannot be resident. An ancillary program (MGSEL, MGSC,
 etc.) can only be launched by specifying it at launch (as long as the version
 number is not verified).
 Under DOS2, you can use any of the following options.

  /Z .... Installs or removes the driver. Installation is only possible if the
          main memory mapper has 2 free pages. You can specify a DOS command
          just behind this option. By default, this is the REBOOT.BAT batch
          file. It will run right after installation or uninstallation.
          As options are interpreted and executed from left to right, so
          specify this option behind the others.

  /Dx ... Specifies the boot drive. This parameter is taken into account not
          only when MGSDRV restarts the DOS, but also after a DOS restart (for
          example, when _SYSTEM is executed under BASIC). x is the name of the
          boot drive (A to H).

  /Sx  .. Specifies the slot number in which the SCC should be used.
          The value must be specified in hexadecimal. It is calculated as
          follows: Extended slot number (0 if it is not) x 4 + number of the
          primary slot. If you enter a wrong slot, it will still be treated as
          if there is an SCC. Which will cause bugs, or even a crash. The SCC
          slot is auto-detected by default.

  /Bx  .. Reserves segments in the main Memory Mapper for loading music data.
          You can reserve up to 10 segments (x = 0-9). If you specify /B3,
          4 segments will be reserved. If you specify /B9 (the maximum),
          10 segments will be reserved because it necessarily reserves one
          segment for the program. It is therefore possible to reserve 176kb
          maximum. (Which is too much for an unmodified FS-A1ST)

  /Kx ... Specifies which key to press along with a numeric keypad key to play
          music, adjust volume, etc. By default, this will be the [CTRL] key.
          You can specify the following three values. 1 for SHIFT, 2 for CTRL,
          3 for GRAPH and 0 for no effect.


Examples of use :

 - MGSDRV /Z          Installs or removes the MGSDRV driver.
 - MGSDRV /ZAUTOEXE2  Installs or removes MGSDRV and then runs AUTOEXE2.BAT.
 - MGSDRV /DC /Z      Specify disk C as the boot disk, install MGSDRV and
                      then run REBOOT.BAT from the same disk.
 - MGSDRV /S5 /Z      Specifies that the SCC is in Slot 1-2 and installs
                      MGSDRV.
 - MGSDRV /DB:        Specify disk B as the boot disk without installing
                      MGSDRV.
 - MGSDRV /B4 /Z      Allocates 5 segments for music data and installs MGSDRV.


* Numeric keypad key functions *

 By pressing the key specified by the /K option with a keypad key, you will
 have access to the following functions.

  /    ... Pause
  *    ... Play music
  -    ... Lower the volume
  +    ... Turn up the volume
  .    ... Stop the music
  ,    ... Replay music
  0~9  ... Change of segments reserved by the /B option

 Since these processes are effected by interrupts, some programs may not work
 or cause inconvenience when executed while music is playing. The processing
 is particularly heavy at the beginning of the music. For example, this can
 cause loss characters with communication software. Keep this in mind when
 a program is running.

 When you press a key from 0 to 9, you change the segment, ie the music data
 storage area. If several segments have been reserved and you have loaded data
 in each of these segments, you will be able to change them freely (each
 change will stop the music). If you select an invalid segment (a segment that
 has not been allocated), the change will not take place, the music will be
 stopped. Do not change segments when a running program uses the same keys as
 those to change segments because most programs ignore segment changes made by
 MGSDRV.


 Examples of use with MGSQC:

 A>mgsdrv /b3 /z	<- Installs MGSDRV with 4 reserved segments
   (Press [CTRL]+[0])
 A>mgsqc ys200		<- Load YS200.MGS in the first reserved segment
   (Press [CTRL]+[1])
 A>mgsqc ys201		<- Load YS201.MGS in the second reserved segment
   (Press [CTRL]+[2])
 A>mgsqc ys202		<- Load YS202.MGS in the third reserved segment
   (Press [CTRL]+[3])
 A>mgsqc ys203		<- Load YS203.MGS in the fourth reserved segment

 Therefore, the segment containing ys200 can be selected by pressing [CTRL]+[0].
 Press [CTRL]+[1] to select the segment containing ys201, [CTRL]+[2] for the
 segment containing ys202, and [CTRL]+[3] for the segment of ys203.
  
 Press [CTRL]+[*] to play the music of the selected segment.

 Note: MGSQC is a free software created by Iita.


* Important *

 - This version supports turbo modes such as R800 mode and 5.37MHz mode of the
   Panasonic MSX2+. ie the musics are playable in these modes. To activate one
   of these modes, use software designed for it.
 - If you specify a boot disk, it must contain the MSXDOS2.SYS and COMMAND2.COM
   files. Otherwise the boot will not be done on this disk but on the default
   disk.
 - Interrupts are used for playing music, so if the interrupts are disabled for
   too long (for example, while accessing a disc), the music played will be
   choppy, which is normal.


* 5.37MHz mode limitations *

 Panasonic MSX2+ have a Turbo mode at 5.37MHz which can be activated by
 software. (This mode is different from that of the Victor HC-90/95). In this
 mode, the operating frequency of the CPU is 1.5 times faster, but since the
 PSG clock does not change, the sound becomes 1.5 times sharper, and the
 envelope period setting lasts 1/1.5 times the normal period.

 Therefore, MGSDRV automatically changes the values of the PSG registers
 so that the music is played correctly in the 5.37 MHz mode of these MSX2+.
 No data modification is therefore necessary. However, due to correction
 calculations, the PSG range is narrower than normal and there will be the
 following restrictions.

 - Sounds lower than # O1D will not play back normally.
   (The frequency will remain at around 40.97Hz)

 - Values greater than 21 of the N command will produce abnormal noise.
   (A noise equivalent to "N21" will be emitted)

 - Values greater than 43690 of the M command will not be able to set the
   hardware envelope cycle correctly.
   (An envelope cycle equivalent to "M43690" will be defined)

 In addition, the music may not be played correctly if you change the mode
 (change from 5.37MHz mode to normal mode at 3.58MHz or vice versa) during
 playback. Avoid doing this as much as possible.


* Version history *

v3.20+
 - Compatible with MSX1. (Fix by gdx)
v3.20
 - Fixed bug in 5.37MHz mode support.
 - Change of copyright displayed at startup which was still the old one.
 - Fixed document inaccuracies.
v3.19
 - Added support for 5.37MHz mode of Panasonic FS-A1FX/WX/WSX.
   (thanks to M. Masaki Seino)
 - Correction of what does not correspond to the description of the document.
v3.18A
 - Fixed version number which was 3.17.
v3.18
 - Fixed a bug that prevented SCC from working in some Slots.
 - Correction treatment of the value of the /Sx.
 - The development of MGSDRV is now entrusted to Gigamix.


* About copying and distribution *

 You can copy and distribute freely, but do not change the contents of the
 archive. If you have any questions, please contact me at the following
 coordinates.


* Contact information *

Twitter:
https://twitter.com/nf_ban

Gigamix WEB site:
http://www.gigamix.jp/

E-mail:
nf_ban@gigamix.jp


[eof]
