问题
How can I query a midi device for a current state of program, volume etc? I tried to find it in Midi specs, yet without any luck. I basically need to get the current instrument (piano etc.) from a digital piano connected by USB midi.
Java seems to be able to do it:
http://docs.oracle.com/javame/config/cldc/opt-pkgs/api/mm/jsr135/index.html?javax/microedition/media/control/MIDIControl.html
How do they do it?
回答1:
You can't. There are no such standard messages for dumping the current patch, CC values, etc.
Some synths have sysex messages that can be used for this, but not all, and that message varies from device to device, manufacturer to manufacturer.
The best you can do is send new CC values, set the patch, etc., and store what it is. If it changes on the synth end, and you have a return path set up, you can receive it and update what you have stored.
来源:https://stackoverflow.com/questions/12660770/how-to-get-a-current-state-of-a-midi-device