Midi .mid file player to Midi out

By st1mpy

Paladin (805)

Аватар пользователя st1mpy

28-04-2021, 19:57

Are there any midi .mid file player utility on msx (or a program with source) that can output to an io port of my choice? I tried to use Midry and set it to use the msx magazine interface (port 0) but the program tries to detect the interface and says not found, because I'm using my own Arduino midi shield attached to cartridge port. (If I manually send midi commands myself to port 0/1, I can play midi from the msx through arduino to roland sound module, I want to try a full song.)

Для того, чтобы оставить комментарий, необходимо регистрация или !login

By st1mpy

Paladin (805)

Аватар пользователя st1mpy

28-04-2021, 21:59

So, one way to do this is how it's normally done with a msx with midi interface. Read midi data byte by byte and send it through io port out to the midi interface and to external midi sound module. This looks like msx doing work (just reading and sending out bytes), but is actually just consuming processing resource. (This method can be done with arduino too, but it is used just to pass data onto the other device)

The alternative is less impressive (msx is not playing the file) but is better in terms of freeing up resource. Send a midi file to play to arduino (or arduino reads from its sd card the file specified), then arduino reads and send the data out the midi port to play. And msx can just send command to play, stop, next track etc.

With the second method, you can get mp3 players like that as well. Also, you could replace the arduino with a better microcontroller board to have the whole sound module emulated. And talking of emulation, it could also do emulation of the usual sounchips like sid, ym fm chips etc.

By st1mpy

Paladin (805)

Аватар пользователя st1mpy

01-05-2021, 14:42

I got Midry to detect the arduino midi, just forced return 1 when it reads midi/command in. Midry is just midi out anyway.
Sounds great, not as cheap to make as tada midi, but atleast this one is parallel out (tada midi is serial out on printer port pin, just like joystick port midi) and doesn't waste msx's processing to do the serial midi out (arduino is doing that), so its as good as other msx midi interfaces. This can be used for games, might be cheap enough to build into a game cartridge too.
I will do a video later.

By st1mpy

Paladin (805)

Аватар пользователя st1mpy

02-05-2021, 17:32

By ToriHino

Paladin (721)

Аватар пользователя ToriHino

02-05-2021, 17:45

Nice LOL! And seems to work very well!