Daniel James wrote: > Hi Ralf, > >> Has anybody a simple source code in C/C++ getting bytes from ALSA or >> JACK MIDI in raw format, that is easy to compile? > > Try asking on the linux-audio-dev list, I think you will get some > suggestions there.
Hi Daniel :) good idea, even if I prefer to subscribe to users lists instead of developers lists, I subscribed to the LAD list. I did it 2 times, because I didn't get a reply. I'll wait some hours and if I won't get a reply, I'll write the list owner. Maybe someone from this list knows how to compile http://www.alsa-project.org/alsa-doc/alsa-lib/_2test_2rawmidi_8c-example.html. 00167 if (handle_out) { 00168 unsigned char ch; 00169 ch=0x90; snd_rawmidi_write(handle_out,&ch,1); 00170 ch=60; snd_rawmidi_write(handle_out,&ch,1); 00171 ch=100; snd_rawmidi_write(handle_out,&ch,1); 00172 snd_rawmidi_drain(handle_out); 00173 sleep(1); 00174 ch=0x90; snd_rawmidi_write(handle_out,&ch,1); 00175 ch=60; snd_rawmidi_write(handle_out,&ch,1); 00176 ch=0; snd_rawmidi_write(handle_out,&ch,1); 00177 snd_rawmidi_drain(handle_out); 00178 } This is a note on 0x9n for channel 1, middle C, velocity 100 and the same note on with velocity 0 means note off, it's often used instead of 0x8n. The complete example from line 1 to 241 seems to do what I was looking for. So I have to eliminate the line numbers and to compile and link it, but I don't know how to do this. I didn't test it for this one, but I know that I always had to struggle with the needed libs and the command to include the libs or to build a make file instead. The next step would be to include a timer, an array to store the MIDI monitoring etc. and than there again willbe trouble with a make file or the right options for the command. Cheers, Ralf
signature.asc
Description: OpenPGP digital signature
_______________________________________________ 64studio-users mailing list [email protected] http://lists.64studio.com/mailman/listinfo/64studio-users
