MIDI Player

Hi, I am trying this:

but it will not play anything when I select an midi file
can I also suggest a block that shows all available midi keyboards?

Hey, I'm Harsh the lead TuneScope developer! First I want to say how wonderful it is to see users coming up with new feature ideas for the library. As Glen mentioned, we meet every Monday to discuss our plans with TuneScope, and we will have more time to dedicate to new features once the semester ends in late May.

As for your concerns with the midi imports and latency, I do not have a definite answer for your case. It is possible that the midi file itself has some incorrect values for the note durations. As far as the Play Tracks block is concerned, the backend javascript keeps track of the measures in your song and re-synchronizes at the start of every new measure. This ensures that we don't have audible drift as latency between tracks accumulates, but it can be susceptible to lag w.r.t the number of tracks it processes at one time. I'm happy to look into this further; if you have any questions on how the backend for TuneScope functions works, PM me and I can give you a more in depth answer as well.

The block is not well named ... currently the midi file must be converted to json format before it can be imported. Also, it currently has the limitation that it can only import a single track. The current status is documented in the following chapter:

A CS student, Emily Liu, is collaborating with Harsh on adding the ability to import a MIDI file directly into Snap! using the Tone.js library. However, this functionality has not yet been implemented.

We only included the MIDI keyboards that we have and therefore are able to test in the drop-down menu. Other models can be typed into the space directly, however.

If there's a list of popular MIDI keyboard that could be added to the drop-down menu, that would be useful ... but someone else who has access to those keyboards would need to test them to make sure that they work. A good suggestion though.

Just received a note from Harsh, "hopefully they will ping me with any questions/concerns before the weekly TuneScope meeting on Monday, and I can try and have an answer sorted out before then."

So if you can post further thoughts / suggestions / questions in this strand, including a ping to @ harshpadhye for technical issues that fall in his domain, Harsh can follow up after the next TuneScope meeting.

How can I import a MIDI file?

I tried untitled script pic 176
and all that happened was the script has apparently been running for ages. I wasn’t asked for a filename, like I had expected.

I’m using an iPad Pro (2017).


yeah, safari has issues with running scripts for file picker.

I tried a Windows PC with Chrome. Downloading MIDI's actually works, thanks for your hint!

Many of the free files are actually not that well, I discovered (my next challenge :smirk: ).