BODY { font-family:Arial, Helvetica, sans-serif;font-size:12px; }greetings! a chuck novice here, so likely some silly user error!.... ;-) working through the tutorials in the pdf manual, when following the Getting MIDI section, if i do this... MidiIn min; if( !min.open(1) ) { me.exit(); } while(true){ min => now; while( min.recv(msg) ){ ; } } ...chuck throws me an "undefined variable 'msg'..." error! something i'm missing? recent change in MIDI syntax? (i'm on chuck v1.2.1.3 on linux) "chuck --probe" does show my desired MIDI interface as "1". thanks in advance... cheers! .pltk.
From: Peter Lutek
greetings! a chuck novice here, so likely some silly user error!.... ;-) working through the tutorials in the pdf manual, when following the Getting MIDI section, if i do this... MidiIn min; if( !min.open(1) ) { me.exit(); } while(true){ min => now; while( min.recv(msg) ){ ; } } ...chuck throws me an "undefined variable 'msg'..." error! something i'm missing? recent change in MIDI syntax? (i'm on chuck v1.2.1.3 on linux) "chuck --probe" does show my desired MIDI interface as "1". thanks in advance... cheers! .pltk.
ahh.... the next section of the tutorial (about outbound MIDI) includes:... MidiMsg msg; ...to define the variable. it works fine. inclusion of that line in the above code (of course) makes it work too. perhaps that should be clarified in the tutorial?? cheers! .pltk. ...and thanks for a maillist which is so amazing that we get answers without you guys even having to do anything! ;-)
Peter;
...to define the variable. it works fine. inclusion of that line in the above code (of course) makes it work too.
perhaps that should be clarified in the tutorial??
Yes, you are correct and I agree. It probably needs at least a brief note on what kind of thing it is.... MidiMsg abstracts 3 "bytes" of 7 bits each, that's unusual enough to warrant a note for the benefit of the increasingly large amount of people who never had to deal with the details of MIDI (for better or worse...). Does anyone know where the current pdf comes from and how we'd get something like that in? Yours, Kas.
participants (3)
-
Kassen
-
Peter Lutek
-
plutek