pcmplay - new dragon sound routine

A place to discuss everything Dragon related that doesn't fall into the other categories.
sorchard
Posts: 531
Joined: Sat Jun 07, 2014 9:43 pm
Location: Norwich UK

Re: pcmplay - new dragon sound routine

Post by sorchard »

utz wrote:... if anybody finds some extra cycles, please feel free to improve the routine ...
I did notice that your sample pointers have 24 bits of resolution as you are using the carry from each 16 bit frequency counter to increment the sample offsets.

You should be able to get a reduction in cycles if you use the top byte of each frequency counter as a sample offset instead. (And recalculate the frequency table). I've heard a few examples that use this resolution and they sound acceptable to my ear at least. I'll have a play with the code when I get a chance, but don't wait for me, you might come up with something that nobody has thought of yet :)
Stew
sixxie
Posts: 1348
Joined: Fri Jul 18, 2008 8:36 am
Location: Hertfordshire
Contact:

Re: pcmplay - new dragon sound routine

Post by sixxie »

24-bit counters drop the samplerate a lot, but some of the lower bass notes might be a lot nicer that way. I've definitely noticed some bum notes in CyD. Swings & roundabouts, I guess.

This does sound nice, and if you keep to the frequency range it can handle (anything under A♯7?) there'll be no problems.
User avatar
Stig
Posts: 74
Joined: Mon Mar 17, 2014 4:54 pm

Re: pcmplay - new dragon sound routine

Post by Stig »

Thanks for the instructions Pere !

Here is how it sounds played on a real Dragon plugged directly into my 80's boombox :)

https://youtu.be/oGKSrmfrCV8
User avatar
robcfg
Posts: 1532
Joined: Sat Apr 04, 2009 10:16 pm
Location: Stockholm, Sweden
Contact:

Re: pcmplay - new dragon sound routine

Post by robcfg »

Awesome sound!

You have a nice Dragon setup there :mrgreen:
User avatar
utz
Posts: 18
Joined: Mon Aug 31, 2015 8:49 pm
Location: Absurdistan
Contact:

Re: pcmplay - new dragon sound routine

Post by utz »

True, using byte-length counters would speed up things a lot, but I find it limits the range of notes too much. Typically, you'll get some serious detuning after about 2½ octaves.

Is there any open source tool to create .vdk images from .bin files? If so, I could include it in the toolchain so they would be build automatically.

@Stig: Thanks for the vid, nice to see it running on an actual Dragon. The recording I linked to in the first post is from Simon's CoCo, btw.
User avatar
Stig
Posts: 74
Joined: Mon Mar 17, 2014 4:54 pm

Re: pcmplay - new dragon sound routine

Post by Stig »

I would love to dabble with your PCM program but I have no idea how to even start it running lol

Could you write a "how to" on using it for a complete noob like myself or would it be to hard for a noob to use ?

Anyway, I hope you make some more tunes soon, would love to have a collection of these to demo on my dragon.

If you're looking for something else to do, can I suggest a dragon version of the tune from Cybernoid 2 on the C64 ? Please, it's my favourite chiptune ever :)

https://www.youtube.com/watch?v=yv5_LsRaPrY

All the best

John
sixxie
Posts: 1348
Joined: Fri Jul 18, 2008 8:36 am
Location: Hertfordshire
Contact:

Re: pcmplay - new dragon sound routine

Post by sixxie »

Stig wrote:If you're looking for something else to do, can I suggest a dragon version of the tune from Cybernoid 2 on the C64 ? Please, it's my favourite chiptune ever :)
Funny you should mention that, it's my default test tune for CyD. http://www.6809.org.uk/tmp/cyd/cyber2.cas

Massive caveats: My conversion tool isn't intelligent, it's just a note by note translation, so memory use is stupid and it only gets a bit into the tune (lots of arpeg = lots of notes). When it loops, the channels are out of alignment so it'll sound really weird. This is actually a good example of why 24 bit counters are useful - the bassline is definitely "off" in this one.

(Not offering CyD to compete here - it's just different. Kinda like CoCoSID cut back a lot, with the idea being to define tunes as programs rather than patterns - which the SID conversion doesn't make any use of whatsoever. In theory you can make a nice long tune in less memory like that though - but I've not found time to try and make any!)
Last edited by sixxie on Wed Sep 09, 2015 9:33 pm, edited 1 time in total.
pser1
Posts: 1672
Joined: Sun Mar 25, 2012 7:32 pm
Location: Barcelona (SPAIN)

Re: pcmplay - new dragon sound routine

Post by pser1 »

I thought I had to share an idea I had a few minutes ago.
If anyone wants to give it a listen ...

I loaded the BIN file into XRoar in a Dragon64 emulation and then entered
POKE&hFFD9,0: EXEC&hF00: POKE&hFFD8,0 and Enter
The result is that you lose the video, but there was nothing to look at and the sound
doubles speed and the frequency (maybe I got it wrong, you could tell me)
Bass notes sound great!
That way the code could process twice as much data, so maybe widening the frequency window (?)

cheers
pere

Ps The same result will be acomplished if we run this player from ROM area with the 'normal' POKE&HFFD7,0, so not losing
the video ... it should have to be compiled at $E000 and then burned on a bank in a CoCo-SDC or a ROM bank in any of the
Rolo's multi-cartridge units, just an idea ...
simon
Posts: 163
Joined: Wed Nov 27, 2013 8:56 pm

Re: pcmplay - new dragon sound routine

Post by simon »

ok... you did fastpoke... which would actually double the freq due to doubling the clock rate of the 6809....

what i AM sure of is this... we can shave a few more cycles of UTZ's routine here..... possibly reducng some resolution, but with the same frequency response

/Simon :-)
User avatar
Stig
Posts: 74
Joined: Mon Mar 17, 2014 4:54 pm

Re: pcmplay - new dragon sound routine

Post by Stig »

sixxie wrote:
Stig wrote:If you're looking for something else to do, can I suggest a dragon version of the tune from Cybernoid 2 on the C64 ? Please, it's my favourite chiptune ever :)
Funny you should mention that, it's my default test tune for CyD. http://www.6809.org.uk/tmp/cyd/cyber2.cas

Massive caveats: My conversion tool isn't intelligent, it's just a note by note translation, so memory use is stupid and it only gets a bit into the tune (lots of arpeg = lots of notes). When it loops, the channels are out of alignment so it'll sound really weird. This is actually a good example of why 24 bit counters are useful - the bassline is defintely "off" in this one.

(Not offering CyD to compete here - it's just different. Kinda like CoCoSID cut back a lot, with the idea being to define tunes as programs rather than patterns - which the SID conversion doesn't make any use of whatsoever. In theory you can make a nice long tune in less memory like that though - but I've not found time to try and make any!)
Very nice version of the Cybernoid tune there, just a shame it doesn't play the entire tune before it loops. Would be interesting to hear what it sounds like generated in utz pcmplay routine. This tune will be with me to the day I die and probably the only reason I still on a C64 lol
Post Reply