How to transfer a Spectrum music to an Amstrad CPC
---------------------------------------------------

Tom & Jerry/GPA 12/2005

I ams definitly sorry for my ugly english.I wish in spite of this shame
habit you will understand it enough to use 

This little article will teach you how to transfer on our good old CPC
musics composed on an unfortunate opponent, the famous Sinclair Spectrum.
Since Sinclair has been bought by Amstrad, last models of Speccy have 
been sold with a nice sound processor, the AY-8910, a very closed cousin
of the AY-8912.
Many many many musics have been done on the Speccy, most of them can be
easily transferred on our machine.

Tronic of GPA has made me discover the marvellous world of Speccy music,
and has given me the idea to write this text. Its goal is to help you not
loosing your precious time of you want to hear Speccy musics on your Arnold !

There is no link for some of the tools you need to (I don't want to make an
HUGE zipped file). Take your browser and look for them, it is quite easy to
catch them (they are all freeware).



What do you need for...
------------------------

* A PC with Windows... (tested with Win98SE abd WINXP).

* ZX Spectrum Soundchip Emulator from Sergey Bulba Vladimorovich.
  This cool program can create YM6! files from many Spectrum musics !

* YM6! Spectrum to Atari : 
  A personal tool to adjust the music frequency. Sorry, you may need the	
  file VB6FR.DLL.

* LHA.EXE :
  Very old japanese packer. YM6! files must be uncrunched with this tool.

* KIT AY v0.3 from Madram/Overlanders :
  A CPC toolkit that transform an uncompressed YM6! file into a crunched
  AYC file !

* A tool that allow you to copy a PC file on a CPC. I personnaly use 
  MANAGEDSK, a excellent program by Demoniak.

* A real CPC or an emulator.

* Maxam from Arnod Ltd. and the AY Player 0.5 Maxam source.
  The source is a "lighted" copy of the DAMS source spreaded with the KIT
  AY. You can find it on the file YM6_SPEC.DSK.

* A Speccy Music : I have choosen as an example "Sokkal" from X-Agon
  of Fantasy. 


Step 1 : Create a YM6! file from a Spectrum tune
------------------------------------------------
- Install ZX Spectrum Soundchip Emulator on your PC.
- Load into the PLAYLIST (PL button) the music you want to convert.
- On the music name, push the right button of your mouse. 
- Surprise, a menu appears ! 
- Select YM6! to export the music.

In our exemple, you should have done a music called SOKKAL.YM.


Step 2 : Uncrunch the YM6! file
--------------------------------
- Copy LHA.EXE in the same directory than the file you have created.
- Open a Text Window (COMMAND or CMD).
- Go to the directory where your files are copied.
- Type command : LHA X <filename>.
  In our exemple, it will be :  LHA X SOKKAL.YM

  If everything is fine, you should obtain a new file : AY_EMUL.

  If there is a problem, verify that the source filename is MSDOS 8.3
  compliant (8 chars for the name and 3 chars for the extension).

  
Step 3 : Correct frequencies of the YM6! file
---------------------------------------------
- Start program "YM6! Spectrum to Atari".
- The interface is quite simple, so you should not have trouble here :-).

  The tool changes frequences of voices A B C and hardware shapes so that
  the YM6! Spectrum becomes an Atari ST file (frequency 2Mhz).

  The tool can convert long musics (30 000 patterns), that is quite
  enough if you consider that the KIT AY 0.3 allow only musics of
  22528 patterns maximum (more than 7 minutes of sounds !).

  On some musics, hardware voices are not perfectly converted (they are 
  too high). With the "Register adjustment" option, you can eventually 
  try to correct this problem (experimental !). A value of 1.02 may be
  right, but you could have to make tests before to find the 
  unexpectable good compromise.
  
  
Step 4 : Copy the YM6! file on a CPC diskette !
-----------------------------------------------
With ManageDsk, create a new DSK and copy the file on it (ASCII format).

At this step, you could have a problem. Some music files might be too big
to fit onto a standard DATA disk (178Kb).

ManageDsk is able to create DSK files with more space (256ko), that can be
used on a CPC without any trick, but you must use an emulator or a 3.1/2
drive to copy it.

On a 178kb disk, you can store a music of 3 minutes 47 seconds.
On a 256kb disk, you can store a music of 5 minutes 25 seconds.

If you want to transfer a longer music, it is possible but not easy...


Step 5 : Convert YM6! file i an AYC file
----------------------------------------
- Take your emulator or your CPC
- Launch the YM2AYC.BAS program (on the AY toolkit disk)
- Do the conversion !

If you don't want to read the AYC review, say 1 to all buffers size. You may
then use the AYC player that is already compiled on the YM6_SPEC.DSK disk.

if the conversion process finished correctly, you should have created a
file named YOUPLA2.BIN.


Step 6 : play the music 
-----------------------
Well, there is no "official AYC module player" on CPC. So, you have to compile
the Maxam source in the archive. It is simple to adapt to your needs, just
read it !

* Start Maxam.
* Push "T" key
* Load the AYC.AMS source file with the "L" key.
* Press "E" to edit and eventually update the souce.
	Music execution address is at the beginning of the text
	Music buffers are at the end of the text !

* Push "Escape" to come back to the menu.
* Press "A" pour assembly the program.

The compiled player uses by default these parameters :

	Load player in memory : &5000
	Music file start      : &6000
	Working Buffers       : &4000-&4100, and so and so...


To listen to the music, type a program like this one :

	10 OPENOUT"D":MEMORY &3FFF
	20 LOAD "madram.bin",&5000
	30 LOAD "youpla2.bin",&6000
	40 CALL &5003
	50 CALL &BD19:CALL &5003:GOTO 50

Easy, isn't it ?