VOGONS


First post, by theelf

User metadata
Rank Oldbie
Rank
Oldbie

Hi all! I've been building a VGM music player for DOS and wanted to share a beta here to get some feedback before a proper release.

vgmdos plays VGM files using pure software chip emulation through a sb card . Tested and working on a real 286 25MHz, in fact, the target is a 286 machine

Supported systems:

Sega Master System / Game Gear / SG-1000 / ColecoVision / Tandy (SN76489 PSG)
Neo Geo Pocket (T6W28 dual-chip stereo PSG)
MSX (AY8910), with or without Konami SCC wavetable chip (scc VGM really dont work well in a 286 need 386DX+)

Other PSG machines/arcade/systems?¿

The software have

Fullscreen text UI with a directory browser
Reads GD3 tags (song/game/author/system) when available
Autodetects the chip type: by folder name (drop your files in folders named MSX, NGP, etc) or by scanning the VGM commands themselves if theres no hint
A config file (VGMDOS.INI) to set a starting path, toggle VU meters and pick audio quality (8000 to 44100Hz, set 8,16,22,44 default is 16 for 286 is best)
Can also play a whole folder in one go, recursively , using space bar

Is a beta bugs are expected, specially on different hardware than what I tested. Any feedback is very welcome, Im spanish so sorry in advance for my English!

thanks

Last edited by theelf on 2026-08-08, 23:34. Edited 1 time in total.

Reply 1 of 16, by theelf

User metadata
Rank Oldbie
Rank
Oldbie
The attachment 20260809_005716.jpg is no longer available

Hi, uploading a new version. Lots of interesting improvements (i think)

Support for more chips:

* NES and Famicom Disk System
* Game Boy
* PC Engine / TurboGrafx
* WonderSwan
* AY8910 (MSX, ZX Spectrum 128, Amstrad CPC, Atari ST)

Something i really need and use, added COVOX support! Yes, you dont even need a Sound Blaster !

OUTPUT=SB -> Sound Blaster
OUTPUT=L1, L2, L3, L4 -> COVOX on those parallel ports

I also added provisional PicoGUS support for the SN76489 chip, so it can play Game Gear, Master System, Tandy, and other VGM files that use this chipset.

Another new feature is a YM2413 to OPL3 translator for the FM sound used by the Master System FM Unit. To my ears it sounds quite decent.

The file browser can now read song names directly from the GD3 tags, so you dont have to rely only on filenames.

There is also support for a vgm.dir file to provide custom names for directories. I've included an example in the ZIP.

More optimization too. On my 286 25, at 11 kHz all cores run fine using COVOX, and FDS works at 8 kHz.

As always, feedback and testing on different hardware is welcome.

The attachment vgm.zip is no longer available

Reply 2 of 16, by wbahnassi

User metadata
Rank Oldbie
Rank
Oldbie

Nice, I tried a VGM for F1-Spirit from MSX, and that game uses both SCC and the AY8910 at the same time. Right now it is only playing the AY8910. The SCC sounds are completely dropped.

I see also that people use .VGZ files, which are .VGM compressed with gzip. Any chance these can be supported directly instead of requiring manual decompression ahead of time?

Thanks!

Turbo XT 12MHz, EGA, MFM HDD
Intel 386 DX-33, Speedstar 24X, SB 1.5, 1x CD
Intel 486 DX2-66, CL5428 VLB, SBPro 2, 2x CD
IBM BlueLightning 100MHz, CL5428, SB16, 4x CD
Intel Pentium 90, Matrox Millenium 2, SB16, 4x CD
HP Z400, Xeon 3.46GHz, YMF-744, RTX2060

Reply 3 of 16, by theelf

User metadata
Rank Oldbie
Rank
Oldbie
wbahnassi wrote on 2026-08-09, 03:35:

Nice, I tried a VGM for F1-Spirit from MSX, and that game uses both SCC and the AY8910 at the same time. Right now it is only playing the AY8910. The SCC sounds are completely dropped.

I see also that people use .VGZ files, which are .VGM compressed with gzip. Any chance these can be supported directly instead of requiring manual decompression ahead of time?

Thanks!

Hi, thanks for testing, please try this build, OUTPUT=SB for sound blaster, LPT1-4 for covox. For AY8910+SCC in my 286 i need to drop to 8khz and 286=1 but work fine, anyways i recommend at least a 386DX-40 to 22khz

the bug with SCC is that scan the VGM header is SUPER SLOW in a 286, then i shorter the scan, but it seems whas too short. I stoped until 22 events, but F1 VGMS did not start SCC until 56+ events

**NOTE: what 286=1 do is only do SCC at half rate, if you use 8khz, SCC willl be 4khz** Quality can be 8,16,22,44

The attachment Image1.png is no longer available
The attachment vgmdos.zip is no longer available

About VGZ i dont have any remotly interest, i dont see the point in a 286/386 when in modern times we have plenty of HDD space, but CPU are the same little bastards. Anyways, is possible, but for long filenames, whe need to use a file with names, maybe i can implement when i finish the cores

thanks

Reply 4 of 16, by wbahnassi

User metadata
Rank Oldbie
Rank
Oldbie

This version recognizes both AY and SCC indeed, but it seems to also introduce a regression on AY-only compared to the first version.. the pitch is lower now (or is it missing one of the channels?)
I was testing with Yie Ar Kung Fu 2 sound track (also MSX) with the track called Battle 1.

Turbo XT 12MHz, EGA, MFM HDD
Intel 386 DX-33, Speedstar 24X, SB 1.5, 1x CD
Intel 486 DX2-66, CL5428 VLB, SBPro 2, 2x CD
IBM BlueLightning 100MHz, CL5428, SB16, 4x CD
Intel Pentium 90, Matrox Millenium 2, SB16, 4x CD
HP Z400, Xeon 3.46GHz, YMF-744, RTX2060

Reply 5 of 16, by theelf

User metadata
Rank Oldbie
Rank
Oldbie
wbahnassi wrote on 2026-08-09, 10:00:

This version recognizes both AY and SCC indeed, but it seems to also introduce a regression on AY-only compared to the first version.. the pitch is lower now (or is it missing one of the channels?)
I was testing with Yie Ar Kung Fu 2 sound track (also MSX) with the track called Battle 1.

I tested much more console cores, i dont have much interest in MSX, then i tested very few vgm, good to me you do

Kung fu 2, only use SCC and not AY8910 at all

In my coode i always assume a MSX game have AY8910 minimum! interesting, thanks a lot. I dont not much about MSX, i had when child but not much time

test this build must sound now!!! work here https://vgmrips.net/packs/pack/yie-ar-kung-fu … akushuu-msx-scc

The attachment vgmdos.zip is no longer available

Please assume quality is NOT my goal, but SPEED, i made this for my 286, i use a lot of hacks and tricks, if sound similar to my ears, for me is fine, but not empty chhannels, etc of course!

Really wish more people test this, i will improve much faster!!

thanks!

Reply 6 of 16, by wbahnassi

User metadata
Rank Oldbie
Rank
Oldbie

Ah should have clarified.. Use the PSG version, not the SCC version. Konami remade several of its MSX games to use the SCC, but I always go to the original releases which are AY only. I tried another game (Goonies) and now it is clear to me that the pitch is an octave lower, not missing channels.

So yeah, go for the non-SCC versions. One title I know never had SCC treatment is Castle Excellent (not Konami even) if you want a safe bet.

I know that MSX is very little known in North America.. so no worries I understand the lack of interest. In reality the MSX was one of the most sophisticated 8-bit consoles when it comes to the sound department. It is almost in a similar situation to the IBM PC with all the possible sound cards you could add... Where the PC started with the speaker, MSX started with the AY-8910.. then extensions like Konami SCC, MSX-Audio, MSX-Music came in with OPLL and ADPCM ..etc.

It is a rabbit hole to support all MSX music devices. There is a VGM player for MSX-DOS and that one supports all the devices but it uses the real hardware, so it doesn't have to render samples like yours.. hence it has no trouble running on the Z80 at ~3MHz.

Turbo XT 12MHz, EGA, MFM HDD
Intel 386 DX-33, Speedstar 24X, SB 1.5, 1x CD
Intel 486 DX2-66, CL5428 VLB, SBPro 2, 2x CD
IBM BlueLightning 100MHz, CL5428, SB16, 4x CD
Intel Pentium 90, Matrox Millenium 2, SB16, 4x CD
HP Z400, Xeon 3.46GHz, YMF-744, RTX2060

Reply 7 of 16, by theelf

User metadata
Rank Oldbie
Rank
Oldbie
wbahnassi wrote on 2026-08-09, 13:34:
Ah should have clarified.. Use the PSG version, not the SCC version. Konami remade several of its MSX games to use the SCC, but […]
Show full quote

Ah should have clarified.. Use the PSG version, not the SCC version. Konami remade several of its MSX games to use the SCC, but I always go to the original releases which are AY only. I tried another game (Goonies) and now it is clear to me that the pitch is an octave lower, not missing channels.

So yeah, go for the non-SCC versions. One title I know never had SCC treatment is Castle Excellent (not Konami even) if you want a safe bet.

I know that MSX is very little known in North America.. so no worries I understand the lack of interest. In reality the MSX was one of the most sophisticated 8-bit consoles when it comes to the sound department. It is almost in a similar situation to the IBM PC with all the possible sound cards you could add... Where the PC started with the speaker, MSX started with the AY-8910.. then extensions like Konami SCC, MSX-Audio, MSX-Music came in with OPLL and ADPCM ..etc.

It is a rabbit hole to support all MSX music devices. There is a VGM player for MSX-DOS and that one supports all the devices but it uses the real hardware, so it doesn't have to render samples like yours.. hence it has no trouble running on the Z80 at ~3MHz.

Hi im from Argentina, whe have MSX here, but was not so much popular like other machines, but still popular. When i live in japan i use much more the MSX. The problem is PAL/NTSC speed, i dont know if what you say about "is a the pitch is an octave lower" i dont know what a octave is, i google it, but i dont have any idea about music to understand and apply a fix

But i think is a code problem, i change a lot of unsigned longs in code, but i forget to change in MSX core some, and i was doing a wrong divisor L16 instead L8, please can you test the same kung fu? i tetsted this https://vgmrips.net/packs/pack/yie-ar-kung-fu … yie-gah-msx-psg i think is the one you talked about

The attachment vgmdos.zip is no longer available

Anyways, I add a MSX-MUSIC YM2413 suppoort in MSX, bcause a 286 is too slow to emulate this chipset, i add a option 2413OPL=1 and i use the OPL3 inside the sound blaster to "emulate" the 2413, please report if you have interest. Same core apply to master system FM games. Some VGM sound nice, others more or less... i tried my best to do a conversion

For example this game

https://vgmrips.net/packs/pack/illusion-city-msx-turbo-r

Reply 8 of 16, by wbahnassi

User metadata
Rank Oldbie
Rank
Oldbie

Great work fixing PSG. It now sounds correct. I played several tracks and all of them sound good, as well as tracks that include SCC music.

I tried the Illusion City track but as you said, the instruments aren't matched well.. but that's expected. I'm not very familiar with MSX-Music's instrument construction controls, so can't tell of it is just straight impossible to achieve with OPL3.

Great stuff though! I'll be trying music from other systems later today.

Turbo XT 12MHz, EGA, MFM HDD
Intel 386 DX-33, Speedstar 24X, SB 1.5, 1x CD
Intel 486 DX2-66, CL5428 VLB, SBPro 2, 2x CD
IBM BlueLightning 100MHz, CL5428, SB16, 4x CD
Intel Pentium 90, Matrox Millenium 2, SB16, 4x CD
HP Z400, Xeon 3.46GHz, YMF-744, RTX2060

Reply 9 of 16, by theelf

User metadata
Rank Oldbie
Rank
Oldbie
wbahnassi wrote on 2026-08-09, 16:42:

Great work fixing PSG. It now sounds correct. I played several tracks and all of them sound good, as well as tracks that include SCC music.

I tried the Illusion City track but as you said, the instruments aren't matched well.. but that's expected. I'm not very familiar with MSX-Music's instrument construction controls, so can't tell of it is just straight impossible to achieve with OPL3.

Great stuff though! I'll be trying music from other systems later today.

Thanks nice work well now, pleease if you test, dont test YM2413 in sooftware mode, im rewriting the core, thanks, not to loose time

About the YM2413>OPL, yes, the translation is not best (i dont think can be much better??¿), but in my opinion good enough to enjoy the music thinking is running in a different hardware. After many attemps i realize a 286 cant emulate a YM2413 properly, then a OPL translation can be a nice addition, thats why i use my time on this, while left the software core to later, im working now

Thanks

Reply 10 of 16, by bakemono

User metadata
Rank Oldbie
Rank
Oldbie

AFAIK, OPLL can be emulated perfectly on OPL2. You can see the parameters needed to duplicate the 15 melodic presets in eg. 0CC-LLTracker

Wreckage reimagined on itch: https://90soft90.itch.io/wreckage-dash

Reply 11 of 16, by theelf

User metadata
Rank Oldbie
Rank
Oldbie
bakemono wrote on 2026-08-09, 23:55:

AFAIK, OPLL can be emulated perfectly on OPL2. You can see the parameters needed to duplicate the 15 melodic presets in eg. 0CC-LLTracker

Hey, thanks for the info about 0CC-LLTracker!

I check the source code, but the array I find (vrc7_instruments) is actually the VRC7 tone table (for example instrument 1 is Buzzy Bell), not the real YM2413 one.

I need the real YM2413/OPLL table because im emulating MSX-MUSIC and Sega FM Sound Unit, both use real YM2413 chip, not VRC7.

Also I have some questions about what you say, OPLL can be emulated perfectly on OPL2, if you dont mind:

The conversion is just copy every field direct (AM/VIB/EG-type/KSR/Multi to $20-$35, KSL/TL to $40-$55, AR/DR to $60-$75, SL/RR to $80-$95)? Or there is some scaling needed too, maybe TL step size or something?
How you handle the modulator Total Level? In my code I do 0x3F - TL when writing to OPL2 TL register. Is this correct, or should be direct copy without invert?
The big one for me: what happen with the custom/user instrument when its ALL ZERO (0x00 in registers 0x00-0x07, this is how real YM2413 starts after power on, before game define it)?

On real chip this make a specific quiet sound, but when I use same zero values on OPL2 it sounds different, more thin and buzzy. Is there some known correct OPL2 patch for this exact case, or this is just hardware difference between OPLL and OPL2 and cant be fixed?

NOTE2 AFTER SOME TEST:

Hi again,I do more tests. I find why OPL2 and YM2413 sound different when the registers 00h to 07h are ALL ZERO (0x00) after power on.In real YM2413 chip, this all-zero makes a low sound, you can hear it. But when I put the same zeros in OPL2 registers, the sound is different. It sounds bad, very thin and buzzy.I don't know much about music, but why this happens?Is a chip hardware difference?Anybody knows a "trick patch" for OPL2 to make the same sound as YM2413 when is all zero? Or is impossible to fix with registers?

Sorry for my bad english

Thanks for any help!

Reply 12 of 16, by bakemono

User metadata
Rank Oldbie
Rank
Oldbie

One difference in the registers is that OPLL has a 9-bit frequency, while OPL2 has 10 bits. That value might need to be scaled, if it plays an octave too low. The OPLL 'volume' field from registers $30~$38 needs to be multiplied by 4 and added to the TL of the carrier. When the OPLL 'sustain pedal' is set, I think the equivalent for OPL2 is to set sustain to 5. OPL2 has 4 waveforms, but OPLL only has 2.

You can see the instruments in 0CC-LLTracker in the UI, so I think it must be in there somewhere.

Wreckage reimagined on itch: https://90soft90.itch.io/wreckage-dash

Reply 13 of 16, by theelf

User metadata
Rank Oldbie
Rank
Oldbie
bakemono wrote on 2026-08-11, 01:17:

One difference in the registers is that OPLL has a 9-bit frequency, while OPL2 has 10 bits. That value might need to be scaled, if it plays an octave too low. The OPLL 'volume' field from registers $30~$38 needs to be multiplied by 4 and added to the TL of the carrier. When the OPLL 'sustain pedal' is set, I think the equivalent for OPL2 is to set sustain to 5. OPL2 has 4 waveforms, but OPLL only has 2.

You can see the instruments in 0CC-LLTracker in the UI, so I think it must be in there somewhere.

Thanks! yes, i already takeare of frecuency

freq = (u16b)((((u16b)regs[0x10+F] & 0xFF) | (((u16b)regs[0x20+F] & 1) << 😎) << 1);

the << 1 at the end is what did the trick

About volume, i use this code table

static const u8b fm_vol[16] = {
0x00, 0x03, 0x06, 0x03, 0x09, 0x0c, 0x0f, 0x12,
0x15, 0x18, 0x1b, 0x1e, 0x21, 0x24, 0x27, 0x2a
};

and this made a index for this

if (addr >= 0x30 && addr < 0x36) {
set_voice(addr & 0x0F, (data >> 4) & 0x0F, fm_vol[data & 0x0F]);
return;
}

About sustain, i dont understand very werll what you say, i will check, i have MS, CS, MSL, and CSL values, but all are dinamic, is not same for all isntruments. I check MEKA source for this values

thanks

Reply 14 of 16, by bakemono

User metadata
Rank Oldbie
Rank
Oldbie

I made a mistake, when 'sustain pedal' is set RELEASE should be set to 5.

The way volume control works on OPL2 is you have a TL value for carrier and one for modulator. They are 6 bits with resolution of .75dB per step.

On OPLL, the modulator TL is part of the instrument preset or from register $02. The 4-bit volume from $30~38 is effectively the TL for the carrier, but it has a resolution of 3.0dB per step.

(value of 0 is always loudest)

Wreckage reimagined on itch: https://90soft90.itch.io/wreckage-dash

Reply 15 of 16, by theelf

User metadata
Rank Oldbie
Rank
Oldbie

Hi, thanks guys for all testing in MSX area, Im trying to reward your efforts by bringing you a new update. In addition to several fixes, thanks to your feedback, Ive added support for YM2149, changed generic YM2413 instruments to MSX-FM/VCR7 when needed, fixed the AY8910 core which had some bugs I introduced with integer conversions, and more. The Master System FM YM2413 is still broken... thats my next task

Anyways, i testesd kung fu 2 PSG and SCC and both sound great to my ears, fix all?¿..never say all, better most...jejeje bugs in SCC, fixed sound tables for msx-r turbo illusion city vgm sound much better now etc

Anyways feedbacks are welcome

The attachment vgm.zip is no longer available

Reply 16 of 16, by theelf

User metadata
Rank Oldbie
Rank
Oldbie

New test/beta version!!

I even write a readme.txt, copy paste here the english part

In my 286 i can play at 22khz PSG (SN76489), AY8910, NES, PCengine, Gameboy, 16khz Wonderswan and at 11khz SCC & FDS. SCC is most difficult, FDS next, i think maybe there is some room for improvement in SCC, FDS i did my best already

The attachment Image1.png is no longer available
The attachment Image2.png is no longer available
================================================================ VGM Player for DOS =========================================== […]
Show full quote

================================================================
VGM Player for DOS
================================================================

Player of .VGM files (Video Game Music) for PC under DOS.

----------------------------------------------------------------
1. CHIPS EMULATED BY SOFTWARE
----------------------------------------------------------------

These ones are calculated sample by sample, in real time, in the
CPU itself. You dont need nothing weird of hardware, only a card
that can put out PCM (a Sound Blaster or compatible, or the
parallel port with a Covox):

- PSG (SN76489) -- Master System, Game Gear, BBC Micro,
and a lot of 8 bit computers. With
support for "dual chip" (two PSG at
same time, thing of some arcade
boards).
- AY-3-8910/8912 -- MSX, ZX Spectrum 128, Amstrad CPC,
Atari ST.
- SCC (Konami) -- MSX cartridges with the Konami
SCC/SCC+ sound expansion.
- NES APU -- NES/Famicom (2 pulse, triangle,
noise and DPCM).
- FDS -- Famicom Disk System expansion, one
extra wave channel with phase
modulation.
- Game Boy / GBC APU -- 2 pulse (one with sweep), one wave
channel of 32 samples and noise.
- WonderSwan -- APU of WonderSwan / WonderSwan Color.
- PC Engine / TurboGrafx-16 -- 6 wave channels, noise, and
frequency modulation between pairs
of channels.
- YM2203 (OPN) -- PC-88, PC-98 and other japanese
computers (the PSG part of the chip;
the FM part goes through real
OPL2/OPL3, see section 2).

----------------------------------------------------------------
2. CHIPS THAT NEED REAL OPL HARDWARE
----------------------------------------------------------------

These ones are not emulated no more, they get translated: the
program grabs their registers from the VGM and resend them as is,
like OPL2/OPL3 commands, straight to the Yamaha chip of your card.

- YM3812 (OPL2) -- AdLib, Sound Blaster (Pro/16/AWE).
- YM3526 (OPL) -- the ancestor of OPL2.
- Y8950 (MSX-AUDIO) -- FM expansion for MSX.
- YMF262 (OPL3) -- Sound Blaster Pro 2/16/AWE, with its
secondary bank of 4 operators.
- YM2413 (OPLL) -- this one we dont really emulate it,
we approximate it reprogramming a
normal OPL2/OPL3 so it sound similar.
The real OPLL as itself is not
supported.
- FM part of YM2203 -- same trick like the YM2413.

----------------------------------------------------------------
3. AUDIO OUTPUT
----------------------------------------------------------------

a) Sound Blaster (by default, or if you put OUTPUT=SB). The
program find out what card you have reading the environment
variable BLASTER, that must be in your AUTOEXEC.BAT, like
this:
SET BLASTER=A220 I5 D1 H5 P330 T6
Plays through hardware DMA.

b) Parallel port, with a Covox or Disney Sound Source
(OUTPUT=LPT1, LPT2, LPT3 or LPT4). Here the PCM is already
mixed by the program in software and gets sent to a
homemade DAC plugged in the parallel port. Only sounds what
is synthesized by software.

----------------------------------------------------------------
5. CONFIGURATION FILE (vgmdos.ini)
----------------------------------------------------------------

PATH=<path> Where it looks for your VGM when it starts.

QUALITY=<n> Sample rate. Accepts 8, 11, 16, 22 or 44 as
shortcut (thousands of Hz), or any number
between 4000 and 44100 if you wanna fine
tune more.

286=1 The "SLOW286" mode. Several emulators (NES,
GB, WonderSwan, SCC, FDS...) lower a bit
their internal time resolution -- things
like Zero-Order Hold in the noise or
subsampling in the FDS -- for not drowning
the CPU in slow machines. You lose some
fidelity, but normally its not too much
noticeable. If you got something more
powerful (386/486 and up), put 286=0 or just
remove the line, better fidelity.

OUTPUT=<mode> SB for Sound Blaster (its what it does
anyway if you dont put this line), or
LPT1/LPT2/LPT3/LPT4 if you output through
parallel port with a Covox.

PGUS_TNDY=1 If you have a Tandy board (Picogus!) it
sends the PSG straight to the real chip
(port 0xC0 by default) instead of emulating
it by software. If yours is in other port,
PGUS_TNDY=<port in hex>.

NOSHORT=1 Shows the full name of the song (the one
that comes in the GD3 tag of the VGM) in
the browser, instead of the short name of
the file.

----------------------------------------------------------------
6. FILES.LST (song names without reading every .vgm)
----------------------------------------------------------------

From the browser, key S makes a FILES.LST in the current folder:
one line per .vgm, format "name.vgm=Song Title", taken from the
GD3 tag of each file. Once it exist, the program reads the title
from there instead of opening every single .vgm -- faster when
you enter a folder with lots of files, specially with NOSHORT=1.
If you delete or move some .vgm, just press S again to remake it.

TheElf 2026

Made in free time, for pure love of my 286

The attachment vgmdos.zip is no longer available