News:

Printed Amstrad Addict magazine announced, check it out here!

Main Menu
avatar_belzebu

Digitize music on CPC or midi converter !?

Started by belzebu, 22:48, 14 March 11

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

belzebu

Hi to all,

I m new of this board, i m a 37 years old and i m a cpc lover :) the 464 was my first persnoal computer and i love it :)
I m not a developer and i not know the assembler language, but i have a passion for graphic adventure and i m developping a little graphic adventure in basic for the cpc...
But i have a problem with sound, i want realize a main theme but i m not a music maker, with spectrum i remember a process for digitalize the real sound from real sound track...
I m seraching but i haven't found anything for make the music for the cpc, a midi adapter/converter tool or a process for digitalizing the voice and the audio...
Can anyone help me ?!

Sorry for my very poor english guys and thanks for all!
This site is realy a great resource for the cpc fans :)

Bye

Belzy

Devilmarkus

Hi Belzy,
first: Welcome to our community!

Glad to see new members who share the same interests!

About your question:
Digitized music is very complicated on a CPC. It takes so much CPU time that there are almost no other resources free (A game or other things)
Sure, digitized music is cool, but not suitable when you want to put it in a game.

I remember coding "Elvira - Mistress of the Dark" for CPC, which was a project half written in machine code and half in BASIC, using RSX commands.
This project is actually in queue.
But I also had digitized title music in it and 1-bit digitized samples which were played during gameplay but also these short samples stopped the CPU until they finished playback.

You can check it here:
Elvira preview in WebCPC

For a good gameplay you should prefer the classic AY possibilities to play musics...
When you put your ear on a hot stove, you can smell how stupid you are ...

Amstrad CPC games in your webbrowser

JavaCPC Desktop Full Release

Devilmarkus

Of course I can also sample longer musics.
  This is a 524k sample splitted into 16k segments, and played with a RSX routine in BASIC:
  (No, that's no fake! I also have the DSK here... But only PARADOS rom can read it...)
 
When you put your ear on a hot stove, you can smell how stupid you are ...

Amstrad CPC games in your webbrowser

JavaCPC Desktop Full Release

belzebu

Thanks for your reply
Yes i have seen your link :)
My problem with the AY classic approach is my absolute no knowledge of music :)
Exist a tool for convert the midi or mod sample in compatible sound of amstrad ?!
When i have a track in AY format how i can import in my program on amstrad CPC !?
Sorry but music on amstrad cpc has always been my Achilles heel, since 80's :)

Thanks bye
Belzy

Devilmarkus

Well, I dont know if there somewhere exist a midi to AY chiptune converter.
The idea sure would be very interesting!

But there exist a few tracker for the CPC which can be used almost like the trackers for Amiga.
Soundtrakker for example:
http://www.cpc-power.com/index.php?page=detail&num=5076

Or also the Arkos Tracker:
http://www.julien-nevo.com/arkos/tools.html
(It's for PC usage)
And last, but not least the Starkos Tracker (for CPC) You find it on the same webpage...

How to create tunes, I cannot help you here, but I am sure we have a lot of musicians here, who can help you a bit.

You can store those music files in binary format and also add a interrupt player.
(Just do a CALL in BASIC and the music plays, another CALL to stop it)
Then your music can play in background while you code and play your game... ;)
When you put your ear on a hot stove, you can smell how stupid you are ...

Amstrad CPC games in your webbrowser

JavaCPC Desktop Full Release

Gryzor

Welcome back, mate! Really glad to have you here... :)

If you don't know about music I'd suggest (like Markus did) to pair up with a musician and share the project... it'll be much easier and the result will be much better....

PS About Markus' vid: I'm not sure if we're listening to the music or looking at the chicks...

arnoldemu

#6
Quote from: belzebu on 22:48, 14 March 11

But i have a problem with sound, i want realize a main theme but i m not a music maker, with spectrum i remember a process for digitalize the real sound from real sound track...

I m seraching but i haven't found anything for make the music for the cpc, a midi adapter/converter tool or a process for digitalizing the voice and the audio...
Can anyone help me ?!
Welcome to cpcwiki.

I hope you enjoy it here. Please feel free to ask questions about anything including BASIC and programming.

Micro Music Creator can record real sounds. it runs on the amstrad.
The quality is a bit poor (1-bit). Sounds made this way can also take a lot of ram.

An alternative is to use a sample on the PC, convert it down to 6Khz (any more and you will not have ram free), but then to play this you will need to use some z80 code. I already made some code to do this, but I would need to help you by making a binary version so you can use it easily from basic.

You can also use soundtrakker or similar tools to make chiptune, which will take less ram and less cpu time to play.

But, our cousins from the Spectrum have made a tool which *may* help:

http://www.worldofspectrum.org/utilities.html

Look for "midi2ay".

These tools are directed towards Spectrum, so the output may be in a form that a Spectrum or Spectrum emulator can use.

But, if they help in some way, then they can be modified to work for CPC too.

A lot of time our cousins on the Spectrum have made similar tools that we can use.

EDIT:

It is possible to use midi2ay with a modified player, which I have written.
But, the Spectrums AY sound chip runs at a different frequency so the music doesn't sound correct.
Devilmarkus has contacted the author and if we can get the sources, we can modify it to output an Amstrad version including correct sounds for Amstrad.
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

MacDeath

http://www.cpcwiki.eu/index.php/Ultra_Son

Ultrason is a french software running on CPC.

It enables to make samples from the Tape Drive.

don't know is this is good or easily exploitable ...

Anyway you can perhaps use the external Tapedrive plug and connect a modern MP3 or whatever Digital sound system...


I tried to "convert" manually the DaftPiunk song Derrezzed on CPC format thx to ArkosTracker...
I used a GuitarPro version of Derrezzed and entered the tunes one by one.

But the main problem I got was concerning the instruments...

On ArkosTracvker, you don't simply enter the length of each tunes, you have to create a proper "instrument" that do the sound and the length of the tune (Black, White, quarter and so on...)

not really user friendly.

Anyway.
There must be some existing MIDI oriented softwares.
Another easier way may be to use an Atari ST perhaps.
You get the song to run properly with the atariST YM... then convert this into the CPC friendlier AY "format".

Gryzor

Apologies for the OT - this reminded me of a type-in that, supposedly, had a small person dancing to the sound of an audio tape in the tape deck. Never worked... :(

Devilmarkus

Quote from: Gryzor on 18:40, 15 March 11
Apologies for the OT - this reminded me of a type-in that, supposedly, had a small person dancing to the sound of an audio tape in the tape deck. Never worked... :(

You definitively tried to type in a C64 program into your CPC :P

Reminds me on someone who asked me in the 80s, if its possible to load C64 tapes on a CPC.
I told him "Thats no problem, just slow down the tapedrive to about 10% of speed and also swap the CPU (z80) against a C64 cpu ":D
When you put your ear on a hot stove, you can smell how stupid you are ...

Amstrad CPC games in your webbrowser

JavaCPC Desktop Full Release

Gryzor


belzebu

Wow! thanks to alla for prescious suggestion and link!
Realy impressive...

Quote

Devilmarkus ha contattato l'autore e se possiamo ottenere i sorgenti, possiamo modificare per produrre una versione Amstrad i suoni corretti per Amstrad.

Wow! Realy fantastic i hope for this :)
I have tryed the midi2ay and i have converted a midi to ASM, open in assembler editor of Amstrad (WinApe) and...
I apologize for my ignorance in the world of assembler, but I always just used the basic and have never been a developer :)
thanks!!!!



arnoldemu

Quote from: belzebu on 19:47, 15 March 11
Wow! thanks to alla for prescious suggestion and link!
Realy impressive...

Wow! Realy fantastic i hope for this :)
I have tryed the midi2ay and i have converted a midi to ASM, open in assembler editor of Amstrad (WinApe) and...
I apologize for my ignorance in the world of assembler, but I always just used the basic and have never been a developer :)
thanks!!!!
We're working towards a midi2ay that will work with no extra work needed by the user.
But for the moment, we're not there.
So at the moment you have to output asm from midi2ay, then do some copying and pasting.
When you're done you can assemble (using wincpc assembler at this time). Then go to basic and type: CALL &8000
to hear the result.
It will not be in tune because it's using Spectrum values, and it's sound chip runs at a different frequency. This means we need different data for CPC for it to be correct.

Asm code for wincpc:
http://www.cpctech.org.uk/source/midi2ay.asm

My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Gryzor

Would you happen to have a demo dsk we could listen to? :)

AMSDOS

AA had a couple of Type-ins which dealt with capturing and digitalising sound (one being Sound Sampler I think from AA15), though the one I thought was pretty good is RSX Speech from AA85:
in one of the following AAs there was a patch for it which allowed people with 128k to put longer sound recordings in the extra 64k which made it really handy!  ;D  You can find it here!
* Using the old Amstrad Languages :D   * with the Firmware :P
* I also like to problem solve code in BASIC :)   * And type-in Type-Ins! :D

Home Computing Weekly Programs
Popular Computing Weekly Programs
Your Computer Programs
Updated Other Program Links on Profile Page (Update April 16/15 phew!)
Programs for Turbo Pascal 3

Devilmarkus

Quote from: Gryzor on 09:14, 16 March 11
Would you happen to have a demo dsk we could listen to? :)

Hey, DSK's (3") are expensive!
I think around 40€ for 10 3" DSK... Maybe, not sure, probably...

But: Take WinCPC, compile this piece of code and do a CALL &8000!
When you put your ear on a hot stove, you can smell how stupid you are ...

Amstrad CPC games in your webbrowser

JavaCPC Desktop Full Release

belzebu

Fine! Thanks for the code :)
It work corectly, i have make my first sound theme for the game :)
When i compile and run it with call memory address, after, i can save this with save a memory area !? And re-call it when i need.. :P

Bye
Belzy!

Devilmarkus

Sure you can.
When you compile it with WinCPC, it prints out the start address (&8000) and length of the assembled binary.
So you can easily save it as: SAVE"MUSIC.BIN",B,&8000,<length>

To load it later into your game use this:
MEMORY &7FFF:LOAD"MUSIC.BIN",&8000

And to play the music use CALL &8000 then ;)

Much fun!
When you put your ear on a hot stove, you can smell how stupid you are ...

Amstrad CPC games in your webbrowser

JavaCPC Desktop Full Release

arnoldemu

Quote from: belzebu on 00:39, 17 March 11
Fine! Thanks for the code :)
It work corectly, i have make my first sound theme for the game :)
When i compile and run it with call memory address, after, i can save this with save a memory area !? And re-call it when i need.. :P

Bye
Belzy!
Sorry that you must go through this process to make the music.

We hoped to contact author of midi2ay and modify the code to make cpc data quickly and easily.. but no answer yet.
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Bryce

From a Hardware point of view, would a hardware solution be of any use? ie: A decent A/D Convertor mapped to an address that you could read from? That way you could connect any source (MP3 Player etc) to the device and a software loop could sample the port at the bit-rate you wanted?

Bryce.

Devilmarkus

Perhaps we can also research the MIDI format?
http://www.sonicspot.com/guide/midifiles.html

I think it's possible...
When you put your ear on a hot stove, you can smell how stupid you are ...

Amstrad CPC games in your webbrowser

JavaCPC Desktop Full Release

demoniak

I've made a small MIDI decoder. Maybe I'll make a MIDI to YM converter with this ?

Devilmarkus

Hmmmm better a MIDI to suitable CPC format converter...
(Like .128 source for Soundtracker?)
I dunno...
My idea is: To create 16 instruments (with different envelopes) and to create a suitable format, which contains songata and eventually the instruments...
What do you think?
When you put your ear on a hot stove, you can smell how stupid you are ...

Amstrad CPC games in your webbrowser

JavaCPC Desktop Full Release

belzebu

:) Work all  correctly, i save the memory area and i load it when i need :)
Another question for the "gurus" :) Is possible grab the music from the demo ? and use it !?

Thanks for all!
Belzey

steve

Quote from: Bryce on 11:04, 17 March 11
From a Hardware point of view, would a hardware solution be of any use? ie: A decent A/D Convertor mapped to an address that you could read from? That way you could connect any source (MP3 Player etc) to the device and a software loop could sample the port at the bit-rate you wanted?

Bryce.

Could the analogue ports on the plus models be used as an audio digitiser?

Powered by SMFPacks Menu Editor Mod