I’m trying to generate a drum score using pymusicxml – in the version that just dropped, I can set the midi program number to 10 for percussion, but when I open it in MuseScore, it plays (as per the midi spec) as a glockenspiel. If I edit the part to have Drumset as an instrument and save it back out as a musicxml file, I see that (a.o.) it has
<midi-instrument id="P1-I36">
<midi-channel>10</midi-channel>
<midi-program>1</midi-program>
<midi-unpitched>36</midi-unpitched>
<volume>78.7402</volume>
<pan>0</pan>
</midi-instrument>
stanzas, but I’m not sure whether this is the distinction that makes a difference. I don’t think I can currently add this through pymusicxml, but I’d be OK postprocessing the results with lxml if need be.