Forums

Sega Master System / Mark III / Game Gear
SG-1000 / SC-3000 / SF-7000 / OMV
Home - Forums - Games - Scans - Maps - Cheats - Credits
Music - Videos - Development - Hacks - Translations - Homebrew

View topic - [Coding competition 2024] SMS VGM Player by Maxim

Reply to topic

Rate this entry!

1 (Terrible) 0% 0%
2 0% 0%
3 0% 0%
4 0% 0%
5 6% 6%
6 6% 6%
7 13% 13%
8 60% 60%
9 0% 0%
10 (Excellent) 13% 13%
This poll has expired.
Author Message
  • Site Admin
  • Joined: 19 Oct 1999
  • Posts: 14745
  • Location: London
Reply with quote
[Coding competition 2024] SMS VGM Player by Maxim
Post Posted: Tue Mar 26, 2024 2:22 pm
Last edited by Maxim on Tue Apr 02, 2024 9:07 am; edited 1 time in total
https://www.smspower.org/Homebrew/SMSVGMPlayer-SMS



Quote
This is a "stub" which is able to play VGM files on the Sega Master System. These are logged music from video games.

It is only able to play back music composed for the sound chips it has: the Sega PSG and the YM2413. It also requires you to decompress the VGM file (if it is compressed; most are) and append it to the ROM.

If you have trouble with playback, try:

1. For compatibility with some flash cartridges, the ROM must be padded to a multiple of 64KB.
2. For compatibility with some emulators, the ROM must be be padded to a minimum of 64KB.

The included makerom.py file will do this for you.

New in version 2.00:

- Functioning FM support, including for mixed PSG/FM music and on real systems
- Works on a real system without graphical corruption
- Enhanced frequency visualisation to support FM data
- Enhanced snow visualisation to have better animation and more snowflakes
- Screensaver visualisation
- Optimised code to remove lag sometimes seen on complicated VGMs
- Reduced to 16KB
- Added (incomplete) support for Japanese GD3 tags

Source code is at https://github.com/maxim-zhao/sms-vgm-player
  View user's profile Send private message Visit poster's website
  • Joined: 30 Jan 2023
  • Posts: 55
  • Location: Manchester, England
Reply with quote
Post Posted: Thu Mar 28, 2024 10:21 am
Words can not describe how happy this makes me ^_^
Finally being able to listen to FM music made in Furnace on real hardware is nothing short of incredible...
https://youtube.com/shorts/GGiqk91qxKI?si=8zXLVmba7eejfglo
  View user's profile Send private message Visit poster's website
  • Joined: 13 Mar 2007
  • Posts: 38
  • Location: Vitória da Conquista, Brazil
Reply with quote
Post Posted: Thu Mar 28, 2024 10:37 am
This will be the reason I finally get some sort of FM module, be it on cartridge form or a mod board, thanks Maxim!
  View user's profile Send private message Visit poster's website
  • Joined: 11 Mar 2018
  • Posts: 66
  • Location: New Zealand
Reply with quote
Post Posted: Thu Mar 28, 2024 10:57 pm
Works great :3


I did run into a Python syntax error; I wonder if this is a difference between Python versions. On my system (Linux + python3), I needed to change a line to capitalize the 'T' in 'true'

isGzip = True
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 19 Oct 1999
  • Posts: 14745
  • Location: London
Reply with quote
Post Posted: Thu Mar 28, 2024 11:16 pm
Hmm, I thought I’d fixed that. I need to spend time to test the script.
  View user's profile Send private message Visit poster's website
  • Joined: 28 Mar 2022
  • Posts: 37
  • Location: UK
Reply with quote
Post Posted: Fri Mar 29, 2024 10:30 pm
I also needed to do that and could have sworn I posted to mention it.

So if you find a post about a python bug in some random thread that'll be it. :D
  View user's profile Send private message Visit poster's website
  • Joined: 06 Mar 2022
  • Posts: 671
  • Location: London, UK
Reply with quote
Post Posted: Sat Mar 30, 2024 4:43 pm
Does exactly what it says on the tin!

Visualisations are a fun addition, although I found that if I cycled through them and back to the piano the graphics became corrupted - see screenshot.
vgm.png (42.59 KB)
vgm.png

  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 19 Oct 1999
  • Posts: 14745
  • Location: London
Reply with quote
Post Posted: Sat Mar 30, 2024 8:11 pm
That’s the old version, it should be fixed now…
  View user's profile Send private message Visit poster's website
  • Joined: 30 Jan 2023
  • Posts: 55
  • Location: Manchester, England
Reply with quote
Post Posted: Wed Apr 03, 2024 9:39 pm
Just realised it works with MSX YM2413 vgm files as well hell yeah ^_^

Of course any VGMs which use the AY chip as well will have that part missing but even then they usually sound really good still...
  View user's profile Send private message Visit poster's website
  • Joined: 05 Sep 2013
  • Posts: 3828
  • Location: Stockholm, Sweden
Reply with quote
Post Posted: Thu Apr 18, 2024 11:55 am
It's so sad Windows doesn't even include a program to pad a file to a certain size.
In Linux, one can just use truncate

example:
truncate -s 128K yourfile.sms
  View user's profile Send private message Visit poster's website
Reply to topic



Back to the top of this page

Back to SMS Power!