.ay file player for divMMC/esxdos

Show us what you're working on, (preferably with screenshots).
Post Reply
User avatar
bob_fossil
Manic Miner
Posts: 657
Joined: Mon Nov 13, 2017 6:09 pm

.ay file player for divMMC/esxdos

Post by bob_fossil »

Initial release of my .ay file player for DivMMC devices running esxdos with 128k of extra memory. An .ay file is a music file that can contain Z80 assembly code which plays music through the beeper or AY chip. You can download .ay files from sites such as ProjectAY or AYGOR. Normally you'd listen to them on a PC with an appropriate player but I wondered whether it would be possible to directly load them onto a Spectrum and play them on real hardware.

Usage:

Copy the PLAYAY file to your esxdos BIN folder. Then you can do:

Code: Select all

.playay music.ay
You should then see a screen showing you some information about the .ay file and the current song. Press 1 to move to the previous song and 2 to move to the next. SPACE starts playing the song ('Playing...' will appear). Press SPACE again to stop playback. X exits the player. You can't exit or change song during playback. You need to stop the song playing first.

I've tested it with the following .ay files and it seems to work okay:

Code: Select all

180!
Bionic Commandos
Chubby Gristle
Cobra
Deviants
Fairlight
Fairlight 2
Foxx Fights Back
Glider Rider
Gobots
Head Over Heels
LED Storm
Manic Miner
Marauder
Mikie
Mountie Mick's Death Ride
Psycho Pigs UXB
Robin Of The Wood
Robocop
Sabre Wulf
Switchblade
Trap Door
Wizball
XOR
Issues and limitations:
  • Only supports EMUL .ay file type.
  • Sections of the .ay file that load to ROM are ignored. This shouldn't be a problem as we have the real ROM available for .ay files that rely on ROM data.
  • Some .ay files can draw to or change the screen. This wasn't an issue with a PC just emulating the Z80 and AY chip as they didn't bother emulating the screen. (Manic Miner)
  • Some beeper .ay files play until they stop (Sabre Wulf), use a different key to stop playback (Mikie uses ENTER) or can't be stopped once started (The Great Escape).
  • I haven't tried this with Amstrad .ay files. :)


Download here.
akeley
Dynamite Dan
Posts: 1048
Joined: Sat Feb 01, 2020 5:47 pm

Re: .ay file player for divMMC/esxdos

Post by akeley »

Neat. Any chance to incorporate this into your browser?
User avatar
bob_fossil
Manic Miner
Posts: 657
Joined: Mon Nov 13, 2017 6:09 pm

Re: .ay file player for divMMC/esxdos

Post by bob_fossil »

akeley wrote: Sat Oct 24, 2020 12:48 pm Neat. Any chance to incorporate this into your browser?
I'm working on it. I just need to iron out some issues with running playay and the browser at the same time. I now have a version of the browser which uses a plug in based system to handle file types. These plug ins exist exist as separate pieces of code so the size of the browser doesn't grow the more you have. Currently I have plugins for .tap, .trd, .sna, .z80, .scr, .lce, .sqt, .stc and .pt3 files.
XoRRoX
Manic Miner
Posts: 233
Joined: Wed Jul 11, 2018 6:34 am

Re: .ay file player for divMMC/esxdos

Post by XoRRoX »

This is fantastic, Bob! Looking forward to playing around with it as soon as I have some time.

And it would indeed be nice if it could be integrated as a plugin in your also fabulous browser 8-)

Thanks! :)
XoRRoX
Manic Miner
Posts: 233
Joined: Wed Jul 11, 2018 6:34 am

Re: .ay file player for divMMC/esxdos

Post by XoRRoX »

I tried some .ay files I found in the download of AVR-AY Player in a folder called "DigitalAY". Only the file "LyraII7.ay" played, the others reset.

https://www.avray.ru/avr-ay-player/

I used a ZX-Uno VM in RVM.
User avatar
bob_fossil
Manic Miner
Posts: 657
Joined: Mon Nov 13, 2017 6:09 pm

Re: .ay file player for divMMC/esxdos

Post by bob_fossil »

New version 004 available here.
  • Modified .ay reading code to stop large .ay files overwriting the stack and crashing the player during loading.
  • Player was hanging on specific .ay files that disabled interrupts in their playback code.
nikosidis
Drutt
Posts: 12
Joined: Tue Mar 15, 2022 4:01 pm

Re: .ay file player for divMMC/esxdos

Post by nikosidis »

Any chance to look at the ay file in this archive?

https://www.youtube.com/redirect?event= ... _point.zip

It does not play.
I have DivIDE but loading the .tap file give me a lot of trash in the sound.

Thanks
User avatar
bob_fossil
Manic Miner
Posts: 657
Joined: Mon Nov 13, 2017 6:09 pm

Re: .ay file player for divMMC/esxdos

Post by bob_fossil »

nikosidis wrote: Tue Mar 15, 2022 4:04 pm Any chance to look at the ay file in this archive?

https://www.youtube.com/redirect?event= ... _point.zip

It does not play.
I have DivIDE but loading the .tap file give me a lot of trash in the sound.

Thanks
Seems to work fine. .playay requires the additional memory of the divMMC which isn't present on a divIDE - which is probably why it's not working for you.
nikosidis
Drutt
Posts: 12
Joined: Tue Mar 15, 2022 4:01 pm

Re: .ay file player for divMMC/esxdos

Post by nikosidis »

Ok, thanks for the info.
User avatar
bob_fossil
Manic Miner
Posts: 657
Joined: Mon Nov 13, 2017 6:09 pm

Re: .ay file player for divMMC/esxdos

Post by bob_fossil »

@nikosidis

Turns out making a divIDE compatible version wasn't so hard, so there's a new version 005 available here.
  • Added divIDE support. divIDE users can use the supplied version in the No_MMC_Memory folder.
  • Backported some player fixes from the AY plugin in my long filename browser.
nikosidis
Drutt
Posts: 12
Joined: Tue Mar 15, 2022 4:01 pm

Re: .ay file player for divMMC/esxdos

Post by nikosidis »

That is very kind of you Bob :)
Works perfect.
Thanks a lot.
Post Reply