[TV] Nov 18 '017 For the sake of measurments with Linux Jack based audio I made some basic facilities for writing a Jack based midi message with a Tcl script, and read from Jakc audio paths and get results from that measurment back into the tcl script using external processes communicating via stdio. Here's a a signal graph of the first successful test setup: [tclsjackmidi1.png] This is the little script "test.tcl": ====== # # # testing jack/alsa midi sending # proc slsend a { puts "177 1 $a" } scale .sl .sl conf -from 0 -to 127 -tickinterval 16 -command {slsend } pack .sl -expand y -fill y button .bnote .bnote conf -text play -command { after 100 {puts "144 69 64" ; flush stdout } after 3000 "puts \"128 69 0\"" set c [open "|./jack_max jm default 3 jack_rack_filt:out_ 2>/dev/null" ] fileevent $c read {set ret [gets $c] ; close $c} } pack .bnote entry .emax .emax conf -textvar ret -width 12 pack .emax ====== These are the C source files for theo Midi Out command line process and the Jack based audio measurement tool: http://www.theover.org/Wiki/jack_max.c , http://www.theover.org/Wiki/midimes.c . The experiment that requires scripting in this case is an audio filter (the jack-rack in the picture) running over a sample (the "qsynth" sampler application in the graph, connected with Midi (red) and audio out (green) to the filter ), of which the maximum output amplitude is measured after the filter with the "jm" code from above. Changing the filter will find different overall spectral maxima that can be searched and intelligently (also automated and unsupervised) used for gathering audio processing data. This simple test lets you adjust the frequency of the filter, and press "play" to play the sample (the decimal codes are MIDI codes to start a note and change the Modulation wheel setting) and search for the maximum filter output amplitude, which is put in the bottom entry automatically after the measurement time is over (in this case 3 seconds with a piano "A" tone). <> Audio | Midi