How to get a current state of a midi device?

醉酒当歌 提交于 2021-01-27 19:26:59

问题


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

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!