Hi,
I hope I've picked the right location for this post.
I am a beginner with processing and with Java in general. I'm trying to figure out how to simply construct a midi note on message and send it to an internal midi port application, that can then route it to a software synthesizer.
I'm using javax.sound.midi for this, and processing 2.0b6.
This is some code I have written to check what devices exist:
However, every single one of those devices, if it is not in the try, catch block that discards MidiUnavailableException, will throw just that exception. Yet none of my devices should be in use for anything, so I'm not sure why all of them throw this error. Any thoughts?
I hope I've picked the right location for this post.
I am a beginner with processing and with Java in general. I'm trying to figure out how to simply construct a midi note on message and send it to an internal midi port application, that can then route it to a software synthesizer.
I'm using javax.sound.midi for this, and processing 2.0b6.
This is some code I have written to check what devices exist:
import javax.sound.midi.*;
MidiDevice.Info[] infos = MidiSystem.getMidiDeviceInfo();
MidiDevice device;
try {
device = MidiSystem.getMidiDevice(infos[11]);
} catch (MidiUnavailableException e) {}
for (int i = 0; i < infos.length; i++) {
print(infos[i]);
}
That code prints the following:
Gervill
Axiom Pro 61 HyperControl In
Axiom Pro 61 MIDI In
Axiom Pro 61 USB A In
Axiom Pro 61 USB B In
Network MIDI
Internal MIDI Port 1
Internal MIDI Port 2
Microsoft MIDI Mapper
Microsoft GS Wavetable Synth
Axiom Pro 61 HyperControl Out
Axiom Pro 61 MIDI Out
Network MIDI
Internal MIDI Port 1
Internal MIDI Port 2
Real Time Sequencer
However, every single one of those devices, if it is not in the try, catch block that discards MidiUnavailableException, will throw just that exception. Yet none of my devices should be in use for anything, so I'm not sure why all of them throw this error. Any thoughts?