MID player for PSG

Door aoineko

Champion (445)

afbeelding van aoineko

23-04-2022, 16:13

Hello,
Do you know any MIDI file (.mid) replayers that are able to play music on the PSG?
I found converters from MIDI to Arkos format (included in Arkos Tracker) or to PT3 (Midi2PT3) but both of them work very badly with test files (quite simple MIDI files).
At first, I would be interested in a player that simply converts the MIDI file to notes. Then, if possible, to be able to use "instruments" (like in a tracker).
Would you have any advise?
I'm looking for replayer in assembler (or in C).

Aangemeld of registreer om reacties te plaatsen

Van MsxKun

Paragon (1104)

afbeelding van MsxKun

23-04-2022, 21:43

aoineko wrote:

At first, I would be interested in a player that simply converts the MIDI file to notes. Then, if possible, to be able to use "instruments" (like in a tracker).
Would you have any advise?

For that part, I used some MIDI parser I found on github that parses MIDI in several ways. I made some changes to some of the code to convert basically that, MIDI to notes, and then using some assembler, reading that to send to the PSG. But all the playing part is very handmade. Wich is good cause being raw it can be adapted to play in many ways. I was using only 1 channel MIDI pre-prepared tracks for the tests, with the goal of use 3 channel later (or 5 for SCC or FM or so...).
The bad part, it's far from being a replayer. It's just test code.

But, for the MIDI part, it is interesting to check the code I found, MIDIFILE. On Tools, there is plenty of code examples with uses the main code, and midi2notes.cpp was the base to make the midi2msx.cpp, wich is exactly the same, but in the way I wanted.
From that, writing some replayer is up to you, you can make it simple and very light or more complicated, depends what do you want exactly. In the end, you gonna need some MIDI with more or less a bit of preparation anyway, and it will depend on the final format you choose.