Author Topic: Playing Donpachi with CD quality soundtrack on the FB Neo retroarch core  (Read 10510 times)

Offline amikipax

  • New Member
  • *
  • Posts: 3
  • Karma: +0/-0
Hello everyone,

I am trying to play Donpachi with the CD quality soundtrack sampleset on the FB Neo retroarch core. I put the donpachi.zip sampleset (around 200 MB) in system/fbneo/samples in the retroarch directory, and I have made sure to toggle the dipswitch in the retroarch options but I didn't notice any difference from the normal soundstrack and retroarch doesn't give me any feedback if it was able to load the sampleset or not.

Am I doing things correctly ?

Thanks.

Offline dink

  • Administrator
  • *****
  • Posts: 5325
  • Karma: +520/-1
  • pie? I nearly bought one!
Re: Playing Donpachi with CD quality soundtrack on the FB Neo retroarch core
« Reply #1 on: October 10, 2021, 01:32:04 AM »
Hi,
It sounds like you did everything right, I just tested it on the windows version and it works OK.
Is there anything in your log file to show that it loaded the samples properly?
something like..
Code: [Select]
*** Starting emulation of donpachi - ??? DonPachi (USA, ver. 1.12, 95/05/2x).
Cheat cpu-register INIT.
CPU-registry: 68k cpu #0 ...
Loading "02 - Sortie Instruction.wav": Sample at native rate already..
Loading "03 - Silent Outpost Base.wav": Sample at native rate already..
Loading "04 - Gale Force.wav": Sample at native rate already..
Loading "05 - God of Destruction.wav": Sample at native rate already..
Loading "06 - Advance Through the Sky.wav": Sample at native rate already..
Loading "07 - The Battle Intensifies.wav": Sample at native rate already..
Loading "08 - An Equal Match.wav": Sample at native rate already..
Loading "09 - It's All Up To Me!!.wav": Sample at native rate already..
Loading "10 - Chief's Congratulations.wav": Sample at native rate already..
Loading "11 - Breakthrough.wav": Sample at native rate already..
Loading "12 - Pressure.wav": Sample at native rate already..
Loading "13 - My Duty is Done.wav": Sample at native rate already..
Loading "14 - Eternal Soldier.wav": Sample at native rate already..
Loading "15 - Chase in the Dark.wav": Sample at native rate already..

Perhaps barbudreadmon has some input?

best regards,
- dink

Offline barbudreadmon

  • Administrator
  • *****
  • Posts: 1195
  • Karma: +68/-2
  • Helper
Re: Playing Donpachi with CD quality soundtrack on the FB Neo retroarch core
« Reply #2 on: October 10, 2021, 03:41:29 AM »
The files are loaded on my side, i can't say i hear much difference with or without but i'm probably a bit deaf.

If you enable debug logs in retroarch settings ("Settings > Logging > Core Logging Level" set to "0 (Debug)"), you should see some lines talking about samples right after "[libretro DEBUG] CPU-registry: 68k cpu #0 ...", the output is slightly different from standalone for various reasons though.

Offline amikipax

  • New Member
  • *
  • Posts: 3
  • Karma: +0/-0
Re: Playing Donpachi with CD quality soundtrack on the FB Neo retroarch core
« Reply #3 on: October 10, 2021, 09:31:11 AM »
After setting the core logs level to debug, I can see some additional logs, it seems the core is loading the samplest but it doesn't list the filenames in the logs:
Code: [Select]
[libretro INFO] [FBNeo] Applied dipswitches from core options
[libretro DEBUG] Cheat cpu-register INIT.
[libretro DEBUG] CPU-registry: 68k cpu #0 ...
[libretro DEBUG] Loading "": [libretro DEBUG] Converting 44100hz [16 bit, 2 channels] to 48000hz (native).
[libretro DEBUG] Loading "": [libretro DEBUG] Converting 44100hz [16 bit, 2 channels] to 48000hz (native).
[libretro DEBUG] Loading "": [libretro DEBUG] Converting 44100hz [16 bit, 2 channels] to 48000hz (native).
[libretro DEBUG] Loading "": [libretro DEBUG] Converting 44100hz [16 bit, 2 channels] to 48000hz (native).
[libretro DEBUG] Loading "": [libretro DEBUG] Converting 44100hz [16 bit, 2 channels] to 48000hz (native).
[libretro DEBUG] Loading "": [libretro DEBUG] Converting 44100hz [16 bit, 2 channels] to 48000hz (native).
[libretro DEBUG] Loading "": [libretro DEBUG] Converting 44100hz [16 bit, 2 channels] to 48000hz (native).
[libretro DEBUG] Loading "": [libretro DEBUG] Converting 44100hz [16 bit, 2 channels] to 48000hz (native).
[libretro DEBUG] Loading "": [libretro DEBUG] Converting 44100hz [16 bit, 2 channels] to 48000hz (native).
[libretro DEBUG] Loading "": [libretro DEBUG] Converting 44100hz [16 bit, 2 channels] to 48000hz (native).
[libretro DEBUG] Loading "": [libretro DEBUG] Converting 44100hz [16 bit, 2 channels] to 48000hz (native).
[libretro DEBUG] Loading "": [libretro DEBUG] Converting 44100hz [16 bit, 2 channels] to 48000hz (native).
[libretro DEBUG] Loading "": [libretro DEBUG] Converting 44100hz [16 bit, 2 channels] to 48000hz (native).
[libretro DEBUG] Loading "": [libretro DEBUG] Converting 44100hz [16 bit, 2 channels] to 48000hz (native).
[libretro INFO] [FBNeo] Initialized driver for donpachi
[libretro INFO] [FBNeo] Adjusted audio buffer to match driver's refresh rate (57.549999 Hz)

Here is a screenshot of the content of the donpachi.zip samplest


Offline dink

  • Administrator
  • *****
  • Posts: 5325
  • Karma: +520/-1
  • pie? I nearly bought one!
Re: Playing Donpachi with CD quality soundtrack on the FB Neo retroarch core
« Reply #4 on: October 10, 2021, 09:55:17 AM »
Not showing the filename on lr is probably OK - you're still not hearing any difference after coining up and hitting start, then flipping the dip for enabling the hq audio on/off?  The voices are still going to be coming from the oki msm6295 (not the greatest quality, I think 16khz? or so..).

this one's for barbudreadmon, any chance you could do a strreplace in bprintf on lr for %S -> %s?  Windows uses %S to display a non-unicode string, I'm pretty certain that's the problem here w/filenames not displaying...  Unless you have a better idea :)

best regards,
- dink

Offline amikipax

  • New Member
  • *
  • Posts: 3
  • Karma: +0/-0
Re: Playing Donpachi with CD quality soundtrack on the FB Neo retroarch core
« Reply #5 on: October 10, 2021, 11:59:20 AM »
I tried using my headset and I can finally hear some difference, but I honestly can't with the speakers. I guess my speakers aren't good enough for my ears to pick up the difference.

Thanks !

Offline barbudreadmon

  • Administrator
  • *****
  • Posts: 1195
  • Karma: +68/-2
  • Helper
Re: Playing Donpachi with CD quality soundtrack on the FB Neo retroarch core
« Reply #6 on: October 11, 2021, 03:10:32 AM »
this one's for barbudreadmon, any chance you could do a strreplace in bprintf on lr for %S -> %s?  Windows uses %S to display a non-unicode string, I'm pretty certain that's the problem here w/filenames not displaying...  Unless you have a better idea :)

That's indeed one of the various reasons for the different output i mentioned above, i was thinking about leaving it like that tbh, but yeah the strreplace is a good idea, and the libretro port already got a function to do that.

Offline dink

  • Administrator
  • *****
  • Posts: 5325
  • Karma: +520/-1
  • pie? I nearly bought one!
Re: Playing Donpachi with CD quality soundtrack on the FB Neo retroarch core
« Reply #7 on: October 11, 2021, 09:23:30 AM »
Patching that would probably reduce the risk of someone thinking there is a problem with fbn because of what they see in the logfile (there's quite a lot more things that do this other than snd/samples), but, have it your way :)

best regards,
- dink

Offline udance4ever

  • New Member
  • *
  • Posts: 3
  • Karma: +0/-0
Hi!  Sorry for digging up an old thread - I do feel it is related to all the troubleshooting steps provided here.

I turned on core debugging and can I see fbneo loading samples for roms like `dkong`:

Code: [Select]
[libretro INFO] [FBNeo] Samplerate set to 48000
[libretro INFO] [FBNeo] Applied dipswitches from core options
[libretro DEBUG] Cheat cpu-register INIT.
[libretro DEBUG] CPU-registry: Z80 cpu #0 ...
[libretro DEBUG] Loading "run01.wav": [libretro DEBUG] Converting 11025hz [16 bit, 1 channels] to 48000hz (native).   
[libretro DEBUG] Loading "run02.wav": [libretro DEBUG] Converting 11025hz [16 bit, 1 channels] to 48000hz (native).   
[libretro DEBUG] Loading "run03.wav": [libretro DEBUG] Converting 11025hz [16 bit, 1 channels] to 48000hz (native).   
[libretro DEBUG] Loading "jump.wav": [libretro DEBUG] Converting 11025hz [16 bit, 1 channels] to 48000hz (native).
[libretro DEBUG] Loading "dkstomp.wav": [libretro DEBUG] Converting 11025hz [16 bit, 1 channels] to 48000hz (native).
[libretro DEBUG] *** Using BUFFERED samples-mode.
[libretro INFO] [FBNeo] Initialized driver for dkong

I don't see it loading all the different tracks for Donpachi:

Code: [Select]
[libretro INFO] [FBNeo] Samplerate set to 48000
[libretro INFO] [FBNeo] Applied dipswitches from core options
[libretro DEBUG] Cheat cpu-register INIT.
[libretro DEBUG] CPU-registry: 68k cpu #0 ...
[libretro INFO] [FBNeo] Initialized driver for donpachi
[libretro INFO] [FBNeo] Adjusted audio buffer to match driver's refresh rate (57.550000 Hz)

In fact, when I flip the dip switch, I don't hear any BGM anymore (I hear only sound effects) and when I flip it back to OFF, the built-in lower quality audio plays (as expected).

The MD5SUM of my fbneo/samples/donpachi.zip is aa8c5e742ba27cb30ce7a872edd684bf

I can unzip the file and play the .wav files in it just fine (which sound great btw!)

Any pointers?

Offline barbudreadmon

  • Administrator
  • *****
  • Posts: 1195
  • Karma: +68/-2
  • Helper
In fact, when I flip the dip switch, I don't hear any BGM anymore

Samples are loaded when loading games, so donpachi requires a full reboot after fliping that dipswitch if it wasn't obvious.
It might also be worth mentioning that retroarch's "restart" thingy is not a reboot, it's a reset.
« Last Edit: May 19, 2025, 02:12:01 AM by barbudreadmon »

Offline udance4ever

  • New Member
  • *
  • Posts: 3
  • Karma: +0/-0
Samples are loaded when loading games, so donpachi requires a full reboot after fliping that dipswitch if it wasn't obvious.
yeah - I made sure to completely quit and restart RetroArch to no avail.

Interestingly enough, you *can* flip the DIP switch OFF in the middle of the emulation and it will return to the built-in BGM :rolleyes:

Offline barbudreadmon

  • Administrator
  • *****
  • Posts: 1195
  • Karma: +68/-2
  • Helper
I'm not sure what could be your problem then, it's working fine here.
Maybe try posting the full logs when the dipswitch is enabled.

Offline dink

  • Administrator
  • *****
  • Posts: 5325
  • Karma: +520/-1
  • pie? I nearly bought one!
With donpachi, it loads the samples if they exist regardless of the dip, and it can be changed between the cd quality & built-in music during the game.

If they're not loading, make sure your zip has the right names, like:
Code: [Select]
Archive:  donpachi.zip
 Length   Method    Size  Cmpr    Date    Time   CRC-32   Name
--------  ------  ------- ---- ---------- ----- --------  ----
10939196  Defl:N  9482190  13% 04/19/2015 15:03 4f70db25  02 - Sortie Instruction.wav
30173852  Defl:N 27472930   9% 04/19/2015 15:03 01878dd9  03 - Silent Outpost Base.wav
23649404  Defl:N 20889146  12% 04/19/2015 15:03 21e94bf7  04 - Gale Force.wav
23687036  Defl:N 20823184  12% 04/19/2015 15:03 8e69327e  05 - God of Destruction.wav
18698444  Defl:N 16347128  13% 04/19/2015 15:03 c4019fca  06 - Advance Through the Sky.wav
22581596  Defl:N 20183191  11% 04/19/2015 15:03 57f71194  07 - The Battle Intensifies.wav
25399292  Defl:N 22474409  12% 04/19/2015 15:03 1cb6ed8b  08 - An Equal Match.wav
 2236796  Defl:N  1426103  36% 04/19/2015 15:03 d40fa0c2  09 - It's All Up To Me!!.wav
 4297148  Defl:N  3351250  22% 04/19/2015 15:03 b59a6318  10 - Chief's Congratulations.wav
 8631884  Defl:N  7144253  17% 04/19/2015 15:03 62f9541a  11 - Breakthrough.wav
11541308  Defl:N  9566064  17% 04/19/2015 15:03 d4e05ba0  12 - Pressure.wav
 9906668  Defl:N  8490163  14% 04/19/2015 15:03 ef1d7916  13 - My Duty is Done.wav
21358556  Defl:N 18445527  14% 04/19/2015 15:03 77192ee8  14 - Eternal Soldier.wav
25286396  Defl:N 22313327  12% 04/19/2015 15:03 8e66a78c  15 - Chase in the Dark.wav
--------          -------  ---                            -------
238387576         208408865  13%                            14 files

best regards,
- dink

Offline barbudreadmon

  • Administrator
  • *****
  • Posts: 1195
  • Karma: +68/-2
  • Helper
Weird, when i tested the game this morning without enabling the dipswitch, it felt like it launched very fast without loading the samples, i guess i dreamed it ?

Offline udance4ever

  • New Member
  • *
  • Posts: 3
  • Karma: +0/-0
thanks everyone for all your support - I figured it out.

I have multiple emulator roots for development and accidentally copied the donpachi.zip sample file to my production instance (so the file was missing where RetroArch was running).  doh.

in any case, I do think if the DIP switch in ON and RetroArch doesn't find samples where it expects it, it should issue a warning in the log file.

just sayin.  it's my fault in the end :)

glad I slept on it, it was driving me nuts :eek: and appreciate y'all keeping the ball rolling!