Forums > MaxMSP

please help! translating key sequences

April 25, 2008 | 7:38 am

I am attempting to translate sequences of switches to specific noteouts. basically, i am building a wind controller based on a standard boehm fingering system. i’ve linked 8 contact switches to max with an arudino board running arduino2max. all of that works fine. the hard part for me is trying to determine the best way to interpret the key sequnces. ie. pack, unpack, matrixctrl or something else that i have not considered taking into acount my blinding noob-ness.

for instance;
C-key 2
c#-no keys
D-keys 1,2,3,5,6,7
D#-keys 1,2,3, 5,6,7,8
E-keys 1,2,3,5,6
F-keys 1,2,3,5
F#-keys 1,2,3,6
G-keys 1,2,3
G#-keys 1,2,3,4
A-keys 1,2
A#-keys 1,4
B-key 1

I thought about using matrixctrl. my first thought was to put these key sequnces into the grid but i have not discovered how to make them "trip" the right note at the end. do i use it with the pack and unpack? or possibly use trigger? i need that when i press a particular sequnce of keys, it some howresults in a single particular midi note.

again, i am sorry for the overtly noob question, but i have read thru the manual so many times now and i confuse myself more with each read.

thank you in advance,

onyx


April 25, 2008 | 5:40 pm

bump


April 25, 2008 | 7:56 pm

onyx ashanti schrieb:
> again, i am sorry for the overtly noob question, but i have read thru
> the manual so many times now and i confuse myself more with each
> read.

though I didn’t really understand what you are after, it looks like you
are looking for the coll object…

Stefan


Stefan Tiedje————x——-
–_____———–|————–
–(_|_ —-|—–|—–()——-
– _|_)—-|—–()————–
———-()——–www.ccmix.com


April 25, 2008 | 8:18 pm

I am trying to interpret the pressing of a sequence of keys into a related midi note. ie, if i press button 1 and button 4, at the same time, i get Bflat, but if i press button 1 and button 2, i get A. my controller has 8 buttons. its basically an emulation of the boehm fingering method. I’m trying to figure out if i should store the button presses as integers or maybe text symbols, then interpret those into sequences of button presses, because each button only sends a 1 or an 0. so maybe i will try converting the bang into a variable of some kind, then interpreting the result into a midi note.

I’m getting a little closer but any help is greatly appreciated. thank you for your reply, i am reading up on the [cool] object right now. i will report back.

onyx

i’ve included the layout in this message.

max v2;
#N vpatcher 182 44 1246 711;
#P origin 363 128;
#P toggle 704 165 15 0;
#P window setfont "Sans Serif" 9.;
#P number 727 166 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P toggle 704 240 15 0;
#P number 727 241 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P toggle 705 275 15 0;
#P number 728 276 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P toggle 706 307 15 0;
#P number 729 308 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P toggle 742 347 15 0;
#P number 765 348 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P toggle 741 194 15 0;
#P number 764 195 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P toggle 705 127 15 0;
#P number 728 128 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P toggle 700 92 15 0;
#P number 502 447 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 723 93 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P user matrixctrl 544 461 134 195 MatrixDefaultCell.pct MatrixDefaultBkgnd.pct 134 195 16 16 8 12 16 16 1 1 48 2 5120 0;
#P window linecount 1;
#P newex 578 410 105 9109513 pack 0 0 0 0 0 0 0 0;
#P newex 707 345 29 9109513 r d9;
#P newex 670 306 29 9109513 r d8;
#P newex 670 239 29 9109513 r d6;
#P newex 669 272 29 9109513 r d7;
#P newex 708 194 29 9109513 r d5;
#P newex 669 164 29 9109513 r d4;
#P newex 667 126 29 9109513 r d3;
#P newex 664 91 29 9109513 r d2;
#P comment 651 53 100 9109513 scale keys;
#P window linecount 6;
#P comment 858 90 100 9109513 each [r] represents a key on a horn. combinations of keys produce a paricular note in a chromatic scale;
#P window linecount 8;
#P comment 728 409 100 9109513 am wondering if pack is what should be used at this point. i think i am going to have to create a list BEFORE i send ot to matrixctrl or pack , but i may be wrong.;
#P window linecount 2;
#P comment 859 209 100 9109513 I want to take combinations like;
#P fasten 12 0 15 0 583 433 507 433;
#P connect 12 0 13 0;
#P fasten 4 0 12 0 643 110 643 339 583 339;
#P fasten 5 0 12 1 649 145 649 344 590 344 590 402 596 402;
#P fasten 6 0 12 2 639 183 639 361 609 361;
#P fasten 7 0 12 3 634 213 634 378 615 378 615 402 622 402;
#P fasten 9 0 12 4 655 258 655 366 640 366 640 386 635 386;
#P fasten 8 0 12 5 674 295 661 295 661 371 648 371;
#P fasten 10 0 12 6 675 377 661 377;
#P fasten 11 0 12 7 712 391 674 391;
#P fasten 4 0 16 0 697 110 697 85 705 85;
#P fasten 6 0 30 0 674 189 700 189 700 158 709 158;
#P fasten 9 0 28 0 675 263 699 263 699 234 709 234;
#P fasten 5 0 18 0 672 150 699 150 699 120 710 120;
#P fasten 8 0 26 0 674 295 700 295 700 268 710 268;
#P fasten 10 0 24 0 675 332 701 332 701 299 711 299;
#P fasten 16 0 14 0 705 113 717 113 717 86 728 86;
#P fasten 30 0 29 0 709 186 721 186 721 159 732 159;
#P fasten 28 0 27 0 709 261 721 261 721 234 732 234;
#P fasten 18 0 17 0 710 148 722 148 722 121 733 121;
#P fasten 26 0 25 0 710 296 722 296 722 269 733 269;
#P fasten 24 0 23 0 711 328 723 328 723 301 734 301;
#P fasten 7 0 20 0 713 220 738 220 738 187 746 187;
#P fasten 11 0 22 0 712 372 737 372 737 340 747 340;
#P fasten 20 0 19 0 746 215 758 215 758 188 769 188;
#P fasten 22 0 21 0 747 368 759 368 759 341 770 341;
#P pop;

thank you for your reply

onyx


April 25, 2008 | 10:59 pm

On Apr 25, 2008, at 1:18 PM, onyx ashanti wrote:
> I’m getting a little closer but any help is greatly appreciated.
> thank you for your reply, i am reading up on the [cool] object right
> now. i will report back.

I would approach by encoding the keys into one number. Here is a brute
force way to do this:

#P window setfont "Sans Serif" 9.;
#P window linecount 3;
#P comment 121 596 143 196617 This number could be put through a coll
or table to create arbitrary mappings.;
#P window linecount 1;
#P comment 171 576 81 196617 Encoded number;
#N vpatcher 664 249 1094 701;
#P outlet 15 411 15 0;
#P window setfont "Sans Serif" 9.;
#P newex 319 87 27 196617 t b i;
#P newex 309 109 27 196617 +;
#P newex 270 133 27 196617 t b i;
#P newex 260 155 27 196617 +;
#P newex 221 179 27 196617 t b i;
#P newex 211 201 27 196617 +;
#P newex 172 225 27 196617 t b i;
#P newex 162 247 27 196617 +;
#P newex 123 271 27 196617 t b i;
#P newex 113 293 27 196617 +;
#P newex 74 317 27 196617 t b i;
#P newex 64 339 27 196617 +;
#P newex 25 363 27 196617 t b i;
#P newex 15 385 27 196617 +;
#P newex 358 57 38 196617 * 128;
#P newex 309 57 32 196617 * 64;
#P newex 260 57 32 196617 * 32;
#P newex 211 57 32 196617 * 16;
#P newex 162 57 27 196617 * 8;
#P newex 113 57 27 196617 * 4;
#P newex 64 57 27 196617 * 2;
#N comlet bit 8;
#P inlet 358 27 15 0;
#N comlet bit 7;
#P inlet 309 27 15 0;
#N comlet bit 6;
#P inlet 260 27 15 0;
#N comlet bit 5;
#P inlet 211 27 15 0;
#N comlet bit 4;
#P inlet 162 27 15 0;
#N comlet bit 3;
#P inlet 113 27 15 0;
#N comlet bit 2;
#P inlet 64 27 15 0;
#N comlet bit 1;
#P inlet 15 27 15 0;
#P connect 0 0 15 0;
#P connect 16 0 15 0;
#P connect 15 0 29 0;
#P connect 17 0 16 0;
#P connect 16 1 15 1;
#P connect 1 0 8 0;
#P connect 8 0 17 0;
#P connect 18 0 17 0;
#P connect 19 0 18 0;
#P connect 18 1 17 1;
#P connect 2 0 9 0;
#P connect 9 0 19 0;
#P connect 20 0 19 0;
#P connect 21 0 20 0;
#P connect 20 1 19 1;
#P connect 3 0 10 0;
#P connect 10 0 21 0;
#P connect 22 0 21 0;
#P connect 23 0 22 0;
#P connect 22 1 21 1;
#P connect 4 0 11 0;
#P connect 11 0 23 0;
#P connect 24 0 23 0;
#P connect 25 0 24 0;
#P connect 24 1 23 1;
#P connect 5 0 12 0;
#P connect 12 0 25 0;
#P connect 26 0 25 0;
#P connect 27 0 26 0;
#P connect 26 1 25 1;
#P connect 6 0 13 0;
#P connect 13 0 27 0;
#P connect 28 0 27 0;
#P fasten 14 0 28 0 363 82 324 82;
#P connect 28 1 27 1;
#P connect 7 0 14 0;
#P pop;
#P newobj 131 540 118 196617 p bits2num;
#P toggle 96 486 15 0;
#P toggle 96 463 15 0;
#P toggle 96 440 15 0;
#P number 131 574 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P toggle 96 417 15 0;
#P toggle 96 371 15 0;
#P toggle 96 394 15 0;
#P toggle 96 348 15 0;
#P toggle 96 325 15 0;
#P comment 89 307 32 196617 Keys;
#P hidden connect 1 0 10 0;
#P connect 10 0 6 0;
#P hidden connect 2 0 10 1;
#P hidden connect 4 0 10 2;
#P hidden connect 3 0 10 3;
#P hidden connect 5 0 10 4;
#P hidden connect 7 0 10 5;
#P hidden connect 8 0 10 6;
#P hidden connect 9 0 10 7;
#P window clipboard copycount 13;

Chris Muir
cbm@well.com

http://www.xfade.com


April 25, 2008 | 11:27 pm

It is not as difficult as you think. have a look at this:
I used pack to make a list of all the key settings, and then compare the
list with settings for all the different notes.

max v2;
#N vpatcher 352 190 952 670;
#P origin 0 29;
#P window setfont "Sans Serif" 9.;
#P number 341 367 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 342 340 100 9109513 Lsame 1 1 1 0 0 1 0 0;
#P comment 351 320 100 9109513 F# key;
#P number 228 366 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 229 339 100 9109513 Lsame 0 1 0 0 0 0 0 0;
#P message 124 339 90 9109513 0 1 0 0 0 0 0 0;
#P newex 123 315 57 9109513 prepend set;
#P newex 68 239 95 9109513 pack 0 0 0 0 0 0 0 0;
#P button 45 212 15 0;
#P toggle 98 186 15 0;
#P toggle 98 163 15 0;
#P toggle 97 139 15 0;
#P toggle 97 116 15 0;
#P toggle 97 93 15 0;
#P toggle 97 70 15 0;
#P toggle 96 46 15 0;
#P toggle 96 23 15 0;
#P window linecount 3;
#P comment 122 69 50 9109513 toggles represent keys;
#P window linecount 1;
#P comment 238 319 100 9109513 C key;
#P hidden connect 9 0 10 0;
#P hidden connect 8 0 10 0;
#P hidden connect 7 0 10 0;
#P hidden connect 6 0 10 0;
#P hidden connect 5 0 10 0;
#P hidden connect 4 0 10 0;
#P hidden connect 3 0 10 0;
#P hidden connect 2 0 11 0;
#P hidden connect 10 0 11 0;
#P hidden connect 3 0 11 1;
#P hidden connect 4 0 11 2;
#P hidden connect 5 0 11 3;
#P hidden connect 6 0 11 4;
#P hidden fasten 11 0 12 0 73 286 128 286;
#P hidden connect 12 0 13 0;
#P hidden connect 7 0 11 5;
#P hidden connect 8 0 11 6;
#P hidden connect 9 0 11 7;
#P hidden connect 14 0 15 0;
#P hidden fasten 11 0 14 0 73 278 234 278;
#P hidden connect 17 0 18 0;
#P hidden fasten 11 0 17 0 73 270 347 270;
#P pop;

note that I used the [Lsame] object from the Lobjects pack written by Peter
Elsea.
http://arts.ucsc.edu/ems/music/research/Lobjects.readme.html
wwww.maxobjects.com

cheers,

Jeroen


April 26, 2008 | 1:14 am

that’s it! thats what i was looking for.

the thing i’ve got to get used to is that there are so many ways to do just about anything with this software. i studied the coll object like stefan suggested, which started leading to the pack, unpack, table and iter objects as possiblities. i cant wait til i can say how easy this program is to get result, as you did, jahroen. that was exactly what i am trying to do.

thank you all. i will post pics and music from the thing, when i get closer to finishing it. if you’d like the see the controller itself (its not amazing or anything, but it puts a face to the code) you can see it on my myspce profile at http://www.myspace.com/onyxashantisinterstellarribshack its the third slide show down on the right.

cheers,

onyx


April 26, 2008 | 12:03 pm

Hey onyx,
you’re creating a nice controlling apparatus as I can see! I hope to see it
working someday, keep us informed on the list!
Cheers!
J.


April 26, 2008 | 7:17 pm

thanks. i will. if you’re in california, i will be attempting to use it at the MakeFaire next weekend. thanks again for the insight.

onyx


April 26, 2008 | 9:33 pm

oh, by the way jahroen, this is what i ended up with from the example that you sent to me. as you can see, it was absolutely EXACTLY what i am trying to do. thanks again.

onyx

max v2;
#N vpatcher 15 55 1185 722;
#P origin 0 29;
#P window setfont "Sans Serif" 9.;
#P number 614 283 35 9 0 0 4096 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P message 621 255 18 9109513 59;
#P number 577 283 35 9 0 0 4096 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P message 582 255 18 9109513 58;
#P number 539 281 35 9 0 0 4096 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P message 545 255 18 9109513 57;
#P number 503 281 35 9 0 0 4096 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P message 506 255 18 9109513 56;
#P number 466 282 35 9 0 0 4096 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P message 469 256 18 9109513 55;
#P number 429 282 35 9 0 0 4096 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P message 432 256 18 9109513 54;
#P number 392 282 35 9 0 0 4096 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P message 395 256 18 9109513 53;
#P number 355 281 35 9 0 0 4096 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P message 358 255 18 9109513 52;
#P number 318 282 35 9 0 0 4096 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P message 321 256 18 9109513 51;
#P number 281 283 35 9 0 0 4096 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P message 284 257 18 9109513 50;
#P number 244 284 35 9 0 0 4096 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P message 247 258 18 9109513 49;
#P number 207 285 35 9 0 0 4096 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P message 210 259 18 9109513 48;
#P user led 622 235 17 17 0 150;
#P user led 582 235 17 17 0 150;
#P user led 546 233 17 17 0 150;
#P user led 509 235 17 17 0 150;
#P user led 471 235 17 17 0 150;
#P user led 434 235 17 17 0 150;
#P user led 396 235 17 17 0 150;
#P user led 360 235 17 17 0 150;
#P user led 323 235 17 17 0 150;
#P user led 281 235 17 17 0 150;
#P user led 247 235 17 17 0 150;
#P user led 212 235 17 17 0 150;
#P comment 430 191 29 9109513 f#;
#P number 395 210 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 742 354 100 9109513 Lsame 1 1 1 0 1 0 0 0;
#P comment 742 338 100 9109513 F key;
#P comment 624 192 29 9109513 b;
#P comment 587 192 29 9109513 a#;
#P comment 544 191 29 9109513 a;
#P comment 502 191 29 9109513 g#;
#P comment 464 192 29 9109513 g;
#P comment 390 192 29 9109513 f;
#P comment 353 193 29 9109513 e;
#P comment 317 193 29 9109513 d#;
#P comment 281 193 29 9109513 d;
#P comment 245 193 29 9109513 c#;
#P newex 84 246 24 9109513 r d9;
#P newex 83 225 24 9109513 r d8;
#P newex 82 202 24 9109513 r d7;
#P newex 82 180 24 9109513 r d6;
#P newex 81 156 29 9109513 r d10;
#P newex 81 133 24 9109513 r d4;
#P newex 81 109 24 9109513 r d3;
#P newex 81 85 24 9109513 r d2;
#P hidden newex 488 48 54 9109513 r portinfo;
#P user umenu 488 75 149 9109543 1 64 91 1;
#X setrgb 12 0 214 255 255 255 255 255 255 221 221 221 170 170 170 119 119 119 187 187 187;
#X add COM4:;
#X add Bluetooth-PDA-Sync;
#X add Hackmendie-Dial-upnetwo-2;
#X add Bluetooth-Modem;
#X add Bluetooth-Modem;
#X add 5;
#X add 6;
#X add 7;
#P toggle 251 72 22 0;
#P window setfont "Sans Serif" 12.;
#P comment 246 49 40 9109516 start;
#P window setfont "Sans Serif" 9.;
#N vpatcher 175 47 1429 745;
#P origin 76 34;
#P window setfont "Sans Serif" 9.;
#P window linecount 0;
#P newex 976 191 36 9109513 r help;
#P window linecount 1;
#P newex 1173 205 64 9109513 s portselect;
#B color 1;
#P newex 35 276 64 9109513 r portselect;
#B color 1;
#P window linecount 0;
#P newex 229 447 54 9109513 s portinfo;
#P window linecount 1;
#N vpatcher 13 88 484 450;
#P outlet 24 246 20 0;
#P inlet 24 32 20 0;
#P window setfont "Sans Serif" 12.;
#P newex 304 196 127 9109516 prepend setitem 7;
#B color 1;
#P newex 264 170 127 9109516 prepend setitem 6;
#B color 1;
#P newex 224 145 127 9109516 prepend setitem 5;
#B color 1;
#P newex 184 119 127 9109516 prepend setitem 4;
#B color 1;
#P newex 143 197 127 9109516 prepend setitem 3;
#B color 1;
#P newex 104 171 127 9109516 prepend setitem 2;
#B color 1;
#P newex 64 146 127 9109516 prepend setitem 1;
#B color 1;
#P newex 24 120 127 9109516 prepend setitem 0;
#B color 1;
#P newex 24 89 293 9109516 unpack s s s s s s s s;
#B color 1;
#P newex 24 59 93 9109516 route port;
#B color 1;
#P comment 167 235 258 9109516 Manages serial name data. Each port name (up to 8 , in this case) replaces an item in the drop-down menu of the parent patch (items in drop-down are numbered 0 – 7).;
#B color 1;
#P connect 11 0 1 0;
#P lcolor 2;
#P connect 1 0 2 0;
#P lcolor 2;
#P connect 2 0 3 0;
#P lcolor 2;
#P connect 10 0 12 0;
#P lcolor 2;
#P connect 9 0 12 0;
#P lcolor 2;
#P connect 8 0 12 0;
#P lcolor 2;
#P connect 7 0 12 0;
#P lcolor 2;
#P connect 6 0 12 0;
#P lcolor 2;
#P connect 5 0 12 0;
#P lcolor 2;
#P connect 4 0 12 0;
#P lcolor 2;
#P connect 3 0 12 0;
#P lcolor 2;
#P connect 2 1 4 0;
#P lcolor 2;
#P connect 2 2 5 0;
#P lcolor 2;
#P connect 2 3 6 0;
#P lcolor 2;
#P connect 2 4 7 0;
#P lcolor 2;
#P connect 2 5 8 0;
#P lcolor 2;
#P connect 2 6 9 0;
#P lcolor 2;
#P connect 2 7 10 0;
#P lcolor 2;
#P pop;
#P newobj 229 412 50 9109513 p sorter;
#B color 1;
#P newex 35 307 91 9109513 prepend port;
#B color 1;
#P button 350 244 27 0;
#P window linecount 0;
#P comment 394 162 284 9109513 Set the sample rate: between every 15ms and every 100ms.;
#P number 350 177 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P user hslider 350 120 38 153 86 1 15 0;
#P newex 275 244 48 9109513 loadbang;
#P newex 208 267 43 9109513 delay 4;
#P number 1234 582 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 1169 582 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 1104 582 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 1039 582 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 974 582 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 909 582 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 844 582 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 779 582 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 714 582 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 649 582 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 584 582 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 519 582 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 454 582 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 389 582 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 324 582 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 259 582 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 194 582 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 129 582 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P window setfont "Sans Serif" 18.;
#P comment 395 86 237 9109522 Serial Port Settings;
#P window setfont "Sans Serif" 9.;
#P newex 976 242 47 9109513 pcontrol;
#P message 976 221 30 9109513 open;
#N vpatcher 483 171 1200 738;
#P origin 0 -1;
#P window setfont "Sans Serif" 10.;
#P window linecount 0;
#P comment 254 165 48 9109514 start;
#P comment 412 162 56 9109514 settings;
#P button 339 190 23 5;
#P comment 335 163 35 9109514 help;
#P window linecount 2;
#P comment 33 79 493 9109514 Arduino2Max uses an Arduino board programmed with the Arduino code that watches the Arduino’s input pins and makes the pin data available through receive objects anywere in your patch.;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P comment 549 309 61 9109513 digital pins;
#P comment 80 309 71 9109513 analog pins;
#P button 425 190 23 5;
#P toggle 253 192 21 0;
#N vpatcher -8 44 1246 704;
#P origin 67 15;
#N comlet inlet to open help patch;
#P inlet 666 67 15 0;
#N comlet inlet for patcher control;
#P inlet 1136 64 15 0;
#N comlet 1 or 0 to start/stop serial reads;
#P inlet 73 39 15 0;
#P pop;
#P newobj 253 254 183 9109513 p arduinoreader;
#P window setfont "Sans Serif" 10.;
#P comment 35 417 585 9109514 A few notes: – Unused inputs will fluctuate between values. This is normal , as unconected pins do this on their own.;
#P window setfont "Sans Serif" 9.;
#P window linecount 3;
#P comment 189 343 319 9109513 Once you have the above patch , you can get Arduino’s analog and digital values anywere in your own patcher by making a "receive a#" or "receive d#" object , where # is the input pin you want to read.;
#P window linecount 1;
#P newex 600 336 29 9109513 r d3;
#P newex 544 336 29 9109513 r d2;
#P newex 124 336 29 9109513 r a1;
#P newex 67 336 29 9109513 r a0;
#P user led 544 364 17 17 0 150;
#P user led 600 364 17 17 3 150;
#P window setfont "Sans Serif" 10.;
#P number 67 364 40 10 0 0 0 139 0 0 0 255 189 156 222 222 222 0 0 0;
#P number 124 364 40 10 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P window linecount 2;
#P comment 35 462 655 9109514 – Arduino2Max runs flawlessly on a 1.83 GHz Macbook Pro ; your mileage may vary.;
#P comment 36 491 636 9109514 – Patch adapted from Thomas Ouellet Fredericks’ "Simple Message Sytem" example. Serial writes are possible , but not implemented here: see the S.M.S. code. Thanks to Seejay James one the MAX list for the pull-down menu code!;
#P comment 35 433 643 9109514 – You may have to change your serial port to suit the port in use. Click on the yellow button to see the guts of the serial read and to make changes to how the patch talks to the serial port.;
#P window setfont "Sans Serif" 9.;
#P window linecount 7;
#P comment 97 175 125 9109513 At minimum , you need the "arduinoreader" patcher at the right , which does the work of reading the pins. The toggle turns serial reads from the Arduino on and off.;
#P comment 495 179 111 9109513 The right-hand yellow button opens the patch so that you can adjust settings , like how often to read from the Arduino and which port to use.;
#P window setfont "Sans Serif" 18.;
#P window linecount 1;
#P comment 33 33 163 9109522 Arduino2Max;
#B frgb 21 56 9;
#P window setfont "Sans Serif" 10.;
#P comment 218 39 334 9109514 Read the 6 analog and 12 digital input pins of the Arduino into MAX.;
#P user panel 18 29 670 101;
#X brgb 255 247 207;
#X frgb 0 0 0;
#X border 0;
#X rounded 0;
#X shadow 0;
#X done;
#P hidden inlet 594 21 15 0;
#P user panel 18 412 671 114;
#X brgb 255 247 207;
#X frgb 0 0 0;
#X border 0;
#X rounded 0;
#X shadow 0;
#X done;
#P user panel 43 332 128 57;
#X brgb 130 218 232;
#X frgb 0 0 0;
#X border 0;
#X rounded 0;
#X shadow 0;
#X done;
#P user panel 245 154 227 129;
#X brgb 130 218 232;
#X frgb 0 0 0;
#X border 0;
#X rounded 0;
#X shadow 0;
#X done;
#P user panel 515 329 139 57;
#X brgb 130 218 232;
#X frgb 0 0 0;
#X border 0;
#X rounded 0;
#X shadow 0;
#X done;
#P connect 17 0 14 0;
#P connect 18 0 13 0;
#P fasten 24 0 23 0 258 224 258 224;
#P connect 30 0 23 1;
#P fasten 25 0 23 2 430 226 430 226;
#P connect 19 0 16 0;
#P connect 20 0 15 0;
#P pop;
#P newobj 976 264 100 9109513 p arduino2max_help;
#P newex 61 137 41 9109513 r onoff;
#N comlet inlet for patcher control;
#P inlet 1173 146 15 0;
#P window linecount 1;
#P comment 978 289 168 9109513 help and patcher control stuff.;
#N comlet 1 or 0 to start/stop serial reads;
#P inlet 129 120 15 0;
#P comment 397 251 243 9109513 Print a list of serial ports to the max window;
#P button 208 299 15 0;
#N vpatcher 289 44 1127 677;
#P outlet 99 316 15 0;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 107 210 31 9109513 spell;
#P window linecount 0;
#P message 90 241 20 9109513 13;
#P newex 90 127 27 9109513 t b l;
#P inlet 90 70 15 0;
#P connect 0 0 1 0;
#P fasten 1 0 2 0 95 235 95 235;
#P fasten 3 0 4 0 112 286 104 286;
#P fasten 2 0 4 0 95 286 104 286;
#P connect 1 1 3 0;
#P pop;
#P newobj 129 290 53 9109513 p convert;
#P newex 1169 697 35 9109513 s d12;
#B color 14;
#P newex 1234 697 35 9109513 s d13;
#B color 14;
#P newex 1104 697 35 9109513 s d11;
#B color 14;
#P newex 1039 697 35 9109513 s d10;
#B color 14;
#P newex 974 697 29 9109513 s d9;
#B color 14;
#P newex 909 697 29 9109513 s d8;
#B color 14;
#P newex 779 697 29 9109513 s d6;
#B color 14;
#P newex 844 697 29 9109513 s d7;
#B color 14;
#P newex 714 697 29 9109513 s d5;
#B color 14;
#P newex 649 697 29 9109513 s d4;
#B color 14;
#P newex 584 697 29 9109513 s d3;
#B color 14;
#P newex 519 697 29 9109513 s d2;
#B color 14;
#P newex 389 697 29 9109513 s a4;
#B color 14;
#P newex 454 697 29 9109513 s a5;
#B color 14;
#P newex 324 697 29 9109513 s a3;
#B color 14;
#P newex 259 697 29 9109513 s a2;
#B color 14;
#P newex 194 697 29 9109513 s a1;
#B color 14;
#P newex 129 697 29 9109513 s a0;
#B color 14;
#N vpatcher 582 197 863 594;
#P window setfont "Sans Serif" 9.;
#P newex 137 226 64 9109513 fromsymbol;
#P newex 137 182 40 9109513 itoa;
#P newex 137 148 61 9109513 zl group 78;
#P newex 137 84 53 9109513 sel 10 13;
#N comlet out;
#P outlet 137 298 26 0;
#N comlet in;
#P inlet 137 37 15 0;
#P connect 0 0 2 0;
#P fasten 2 1 3 0 163 124 142 124;
#P fasten 2 2 3 0 184 124 142 124;
#P connect 3 0 4 0;
#P connect 4 0 5 0;
#P connect 5 0 1 0;
#P pop;
#P newobj 129 412 73 9109513 p convertback;
#P newex 129 470 52 9109513 route list;
#P newex 1234 611 49 9109513 change 0;
#B color 6;
#P newex 1169 611 49 9109513 change 0;
#B color 6;
#P newex 1104 611 49 9109513 change 0;
#B color 6;
#P newex 1039 611 49 9109513 change 0;
#B color 6;
#P newex 974 611 49 9109513 change 0;
#B color 6;
#P newex 909 611 49 9109513 change 0;
#B color 6;
#P newex 844 611 49 9109513 change 0;
#B color 6;
#P newex 779 611 49 9109513 change 0;
#B color 6;
#P newex 714 611 49 9109513 change 0;
#B color 6;
#P newex 649 611 49 9109513 change 0;
#B color 6;
#P newex 584 611 49 9109513 change 0;
#B color 6;
#P newex 519 611 49 9109513 change 0;
#B color 6;
#P newex 454 611 49 9109513 change 0;
#B color 14;
#P newex 389 611 49 9109513 change 0;
#B color 14;
#P newex 324 611 49 9109513 change 0;
#B color 14;
#P newex 259 611 49 9109513 change 0;
#B color 14;
#P newex 194 611 49 9109513 change 0;
#B color 14;
#P newex 129 611 49 9109513 change 0;
#B color 14;
#P newex 129 528 1131 9109513 unpack i i i i i i i i i i i i i i i i i i;
#P message 129 240 14 9109513 r;
#P toggle 129 157 15 0;
#P newex 129 204 52 9109513 metro 15;
#P newex 129 365 95 9109513 serial d 115200 8 1 0;
#P message 350 301 32 9109513 print;
#P user panel 370 57 398 255;
#X brgb 158 223 254;
#X frgb 0 0 0;
#X border 0;
#X rounded 0;
#X shadow 0;
#X done;
#P connect 83 0 80 0;
#P fasten 51 0 4 0 66 155 134 155;
#P connect 48 0 4 0;
#P connect 4 0 3 0;
#P connect 3 0 5 0;
#P connect 5 0 45 0;
#P connect 45 0 2 0;
#P fasten 46 0 2 0 213 333 134 333;
#P fasten 1 0 2 0 355 341 134 341;
#P connect 80 0 2 0;
#P connect 2 0 26 0;
#P connect 26 0 25 0;
#P connect 25 0 6 0;
#P connect 6 0 56 0;
#P connect 56 0 7 0;
#P fasten 7 0 27 0 134 678 134 678;
#P fasten 77 0 3 1 355 199 176 199;
#P connect 6 1 57 0;
#P connect 57 0 8 0;
#P fasten 8 0 28 0 199 680 199 680;
#P fasten 3 0 74 0 134 232 213 232;
#P connect 74 0 46 0;
#P connect 2 1 81 0;
#P connect 81 0 82 0;
#P connect 6 2 58 0;
#P connect 58 0 9 0;
#P fasten 9 0 29 0 264 680 264 680;
#P connect 6 3 59 0;
#P connect 59 0 10 0;
#P fasten 10 0 30 0 329 680 329 680;
#P fasten 76 0 77 0 355 167 355 167;
#P fasten 75 0 1 0 280 281 355 281;
#P connect 79 0 1 0;
#P connect 6 4 60 0;
#P connect 60 0 11 0;
#P fasten 11 0 32 0 394 680 394 680;
#P connect 6 5 61 0;
#P connect 61 0 12 0;
#P fasten 12 0 31 0 459 680 459 680;
#P connect 6 6 62 0;
#P connect 62 0 13 0;
#P fasten 13 0 33 0 524 680 524 680;
#P connect 6 7 63 0;
#P connect 63 0 14 0;
#P fasten 14 0 34 0 589 680 589 680;
#P connect 6 8 64 0;
#P connect 64 0 15 0;
#P fasten 15 0 35 0 654 680 654 680;
#P connect 6 9 65 0;
#P connect 65 0 16 0;
#P fasten 16 0 36 0 719 680 719 680;
#P fasten 6 10 66 0 784 570 784 570;
#P fasten 66 0 17 0 784 604 784 604;
#P fasten 17 0 38 0 784 680 784 680;
#P connect 6 11 67 0;
#P connect 67 0 18 0;
#P fasten 18 0 37 0 849 680 849 680;
#P connect 6 12 68 0;
#P connect 68 0 19 0;
#P fasten 19 0 39 0 914 680 914 680;
#P connect 6 13 69 0;
#P connect 69 0 20 0;
#P fasten 20 0 40 0 979 680 979 680;
#P connect 85 0 53 0;
#P hidden connect 53 0 54 0;
#P hidden connect 54 0 52 0;
#P connect 6 14 70 0;
#P connect 70 0 21 0;
#P fasten 21 0 41 0 1044 680 1044 680;
#P connect 6 15 71 0;
#P connect 71 0 22 0;
#P fasten 22 0 42 0 1109 680 1109 680;
#P connect 6 16 72 0;
#P connect 72 0 23 0;
#P fasten 23 0 44 0 1174 680 1174 680;
#P connect 50 0 84 0;
#P connect 6 17 73 0;
#P connect 73 0 24 0;
#P fasten 24 0 43 0 1239 680 1239 680;
#P pop;
#P newobj 251 138 247 9109513 p arduinoSerialreader;
#P number 622 210 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 742 687 100 9109513 Lsame 1 0 0 0 0 0 0 0;
#P comment 742 664 100 9109513 B key;
#P number 582 210 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 742 638 100 9109513 Lsame 1 0 0 0 1 0 0 0;
#P comment 742 618 100 9109513 A# key;
#P number 545 210 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 742 589 100 9109513 Lsame 1 1 0 0 0 0 0 0;
#P comment 742 569 100 9109513 A key;
#P number 509 209 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 742 522 100 9109513 Lsame 1 1 1 1 0 0 0 0;
#P comment 742 502 100 9109513 G# key;
#P number 244 1291 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 245 1264 100 9109513 Lsame 0 0 0 0 0 0 0 0;
#P comment 254 1244 100 9109513 C# key;
#P number 407 892 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 408 865 100 9109513 Lsame 0 0 0 0 0 0 0 0;
#P comment 417 845 100 9109513 C# key;
#P number 471 209 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 742 458 100 9109513 Lsame 1 1 1 0 0 0 0 0;
#P comment 742 437 100 9109513 G key;
#P number 358 211 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 742 312 100 9109513 Lsame 1 1 1 0 1 1 0 0;
#P comment 742 292 100 9109513 E key;
#P number 320 210 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 742 257 100 9109513 Lsame 1 1 1 0 1 1 1 1;
#P comment 742 224 100 9109513 D# key;
#P number 283 211 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 742 172 100 9109513 Lsame 1 1 1 0 1 1 1 0;
#P comment 742 152 100 9109513 D key;
#P number 245 212 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 742 102 100 9109513 Lsame 0 0 0 0 0 0 0 0;
#P comment 742 82 100 9109513 C# key;
#P number 433 210 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 742 400 100 9109513 Lsame 1 1 1 0 0 1 0 0;
#P comment 742 383 100 9109513 F# key;
#P number 209 212 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 742 38 100 9109513 Lsame 0 1 0 0 0 0 0 0;
#P message 76 353 90 9109513 0 0 0 0 0 0 0 0;
#P newex 77 329 57 9109513 prepend set;
#P newex 76 300 95 9109513 pack 0 0 0 0 0 0 0 0;
#P button 105 272 15 0;
#P toggle 158 246 15 0;
#P toggle 158 223 15 0;
#P toggle 157 199 15 0;
#P toggle 157 176 15 0;
#P toggle 157 153 15 0;
#P toggle 157 130 15 0;
#P toggle 156 106 15 0;
#P toggle 156 83 15 0;
#P window linecount 3;
#P comment 182 129 50 9109513 toggles represent keys;
#P window linecount 1;
#P comment 742 29 100 9109513 C key;
#P comment 209 193 29 9109513 c;
#P hidden connect 3 0 12 0;
#P hidden connect 11 0 12 0;
#P hidden connect 13 0 14 0;
#P hidden fasten 12 0 13 0 81 346 82 346;
#P hidden connect 4 0 12 1;
#P hidden connect 5 0 12 2;
#P hidden connect 10 0 11 0;
#P hidden connect 8 0 11 0;
#P hidden connect 6 0 11 0;
#P hidden connect 4 0 11 0;
#P hidden connect 5 0 11 0;
#P hidden connect 7 0 11 0;
#P hidden connect 9 0 11 0;
#P hidden connect 6 0 12 3;
#P hidden connect 7 0 12 4;
#P hidden connect 8 0 12 5;
#P hidden connect 9 0 12 6;
#P connect 58 0 3 0;
#P connect 59 0 4 0;
#P fasten 60 0 5 0 158 129 162 129;
#P connect 61 0 6 0;
#P connect 62 0 7 0;
#P connect 63 0 8 0;
#P connect 64 0 9 0;
#P connect 65 0 10 0;
#P hidden connect 10 0 12 7;
#P connect 92 0 93 0;
#P hidden connect 15 0 16 0;
#P connect 80 0 92 0;
#P connect 16 0 80 0;
#P connect 94 0 95 0;
#P hidden connect 39 0 40 0;
#P hidden connect 21 0 22 0;
#P connect 22 0 81 0;
#P connect 81 0 94 0;
#P fasten 55 0 53 0 256 115 256 115;
#P connect 25 0 82 0;
#P connect 96 0 97 0;
#P hidden connect 24 0 25 0;
#P connect 82 0 96 0;
#P connect 98 0 99 0;
#P hidden connect 27 0 28 0;
#P connect 83 0 98 0;
#P connect 28 0 83 0;
#P connect 100 0 101 0;
#P hidden connect 30 0 31 0;
#P connect 84 0 100 0;
#P connect 31 0 84 0;
#P connect 102 0 103 0;
#P hidden connect 77 0 78 0;
#P connect 85 0 102 0;
#P connect 78 0 85 0;
#P hidden connect 36 0 37 0;
#P connect 104 0 105 0;
#P connect 86 0 104 0;
#P hidden connect 18 0 19 0;
#P connect 19 0 86 0;
#P connect 106 0 107 0;
#P connect 87 0 106 0;
#P hidden connect 33 0 34 0;
#P connect 34 0 87 0;
#P hidden connect 57 0 56 0;
#P connect 56 0 53 1;
#P connect 108 0 109 0;
#P connect 88 0 108 0;
#P hidden connect 42 0 43 0;
#P connect 43 0 88 0;
#P connect 110 0 111 0;
#P hidden connect 45 0 46 0;
#P connect 89 0 110 0;
#P connect 46 0 89 0;
#P connect 112 0 113 0;
#P hidden connect 48 0 49 0;
#P connect 49 0 90 0;
#P connect 90 0 112 0;
#P connect 114 0 115 0;
#P connect 91 0 114 0;
#P hidden connect 51 0 52 0;
#P connect 52 0 91 0;
#P fasten 12 0 15 0 81 340 668 340 668 46 747 46;
#P fasten 12 0 21 0 81 323 674 323 674 104 747 104;
#P fasten 12 0 24 0 81 327 684 327 684 163 747 163;
#P fasten 12 0 27 0 81 336 696 336 696 245 747 245;
#P fasten 12 0 30 0 141 333 711 333 711 319 747 319;
#P fasten 12 0 77 0 81 332 711 352;
#P fasten 12 0 18 0 81 465 687 465 687 384 747 384;
#P fasten 12 0 33 0 81 486 692 486 692 463 747 463;
#P fasten 12 0 42 0 81 520 747 520;
#P fasten 12 0 45 0 81 539 586 539 586 566 665 560 665 597 747 597;
#P fasten 12 0 48 0 81 550 747 550;
#P fasten 12 0 51 0 81 552 178 586 747 586;
#P pop;


April 27, 2008 | 12:49 am

On Apr 26, 2008, at 2:33 PM, onyx ashanti wrote:
> oh, by the way jahroen, this is what i ended up with from the
> example that you sent to me. as you can see, it was absolutely
> EXACTLY what i am trying to do. thanks again.

Don’t let me discourage you from using that solution, if it’s working
for you, but it strikes me as over-complicated, and hard to extend.
Here’s one based on treating the switches as bits, encoding them into
a number (as I described before), then looking up the numbers that
matter via a coll to get the pitches. This one is easily extended to
look up any old combination of switches, to generate other notes.

#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P comment 133 334 94 196617 Looked up note num;
#P number 91 332 35 9 0 0 4096 3 0 0 0 221 221 221 222 222 222 0 0 0;
#N coll note_map;
#T flags 1 0;
#T 0 49;
#T 119 50;
#T 1 59;
#T 2 48;
#T 247 51;
#T 55 52;
#T 23 53;
#T 39 54;
#T 7 55;
#T 15 56;
#T 3 57;
#T 17 58;
#P newobj 91 312 72 196617 coll note_map;
#P newex 15 204 24 196617 r d9;
#P newex 14 183 24 196617 r d8;
#P newex 13 160 24 196617 r d7;
#P newex 13 138 24 196617 r d6;
#P newex 12 114 34 196617 r d10;
#P newex 12 91 24 196617 r d4;
#P newex 12 67 24 196617 r d3;
#P newex 12 43 24 196617 r d2;
#P comment 131 295 81 196617 Encoded number;
#N vpatcher 664 249 1094 701;
#P outlet 15 411 15 0;
#P window setfont "Sans Serif" 9.;
#P newex 319 87 27 196617 t b i;
#P newex 309 109 27 196617 +;
#P newex 270 133 27 196617 t b i;
#P newex 260 155 27 196617 +;
#P newex 221 179 27 196617 t b i;
#P newex 211 201 27 196617 +;
#P newex 172 225 27 196617 t b i;
#P newex 162 247 27 196617 +;
#P newex 123 271 27 196617 t b i;
#P newex 113 293 27 196617 +;
#P newex 74 317 27 196617 t b i;
#P newex 64 339 27 196617 +;
#P newex 25 363 27 196617 t b i;
#P newex 15 385 27 196617 +;
#P newex 358 57 38 196617 * 128;
#P newex 309 57 32 196617 * 64;
#P newex 260 57 32 196617 * 32;
#P newex 211 57 32 196617 * 16;
#P newex 162 57 27 196617 * 8;
#P newex 113 57 27 196617 * 4;
#P newex 64 57 27 196617 * 2;
#N comlet bit 8;
#P inlet 358 27 15 0;
#N comlet bit 7;
#P inlet 309 27 15 0;
#N comlet bit 6;
#P inlet 260 27 15 0;
#N comlet bit 5;
#P inlet 211 27 15 0;
#N comlet bit 4;
#P inlet 162 27 15 0;
#N comlet bit 3;
#P inlet 113 27 15 0;
#N comlet bit 2;
#P inlet 64 27 15 0;
#N comlet bit 1;
#P inlet 15 27 15 0;
#P window setfont "Sans Serif" 12.;
#P comment 167 335 223 196620 Take eight input bits , and generate a
number between 0-255;
#P connect 17 0 16 0;
#P connect 1 0 16 0;
#P connect 16 0 30 0;
#P connect 18 0 17 0;
#P connect 17 1 16 1;
#P connect 2 0 9 0;
#P connect 19 0 18 0;
#P connect 9 0 18 0;
#P connect 20 0 19 0;
#P connect 19 1 18 1;
#P connect 3 0 10 0;
#P connect 21 0 20 0;
#P connect 10 0 20 0;
#P connect 22 0 21 0;
#P connect 21 1 20 1;
#P connect 4 0 11 0;
#P connect 23 0 22 0;
#P connect 11 0 22 0;
#P connect 24 0 23 0;
#P connect 23 1 22 1;
#P connect 5 0 12 0;
#P connect 25 0 24 0;
#P connect 12 0 24 0;
#P connect 26 0 25 0;
#P connect 25 1 24 1;
#P connect 6 0 13 0;
#P connect 27 0 26 0;
#P connect 13 0 26 0;
#P connect 28 0 27 0;
#P connect 27 1 26 1;
#P connect 7 0 14 0;
#P connect 29 0 28 0;
#P connect 14 0 28 0;
#P fasten 15 0 29 0 363 82 324 82;
#P connect 29 1 28 1;
#P connect 8 0 15 0;
#P pop;
#P newobj 91 272 118 196617 p bits2num;
#P toggle 56 218 15 0;
#P toggle 56 195 15 0;
#P toggle 56 172 15 0;
#P number 91 293 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P toggle 56 149 15 0;
#P toggle 56 103 15 0;
#P toggle 56 126 15 0;
#P toggle 56 80 15 0;
#P toggle 56 57 15 0;
#P comment 49 39 32 196617 Keys;
#P connect 6 0 20 0;
#P connect 20 0 21 0;
#P connect 19 0 9 0;
#P connect 18 0 8 0;
#P connect 17 0 7 0;
#P connect 16 0 5 0;
#P connect 15 0 3 0;
#P connect 14 0 4 0;
#P connect 13 0 2 0;
#P connect 12 0 1 0;
#P hidden connect 9 0 10 7;
#P hidden connect 8 0 10 6;
#P hidden connect 7 0 10 5;
#P hidden connect 5 0 10 4;
#P hidden connect 3 0 10 3;
#P hidden connect 4 0 10 2;
#P hidden connect 2 0 10 1;
#P connect 10 0 6 0;
#P hidden connect 1 0 10 0;
#P window clipboard copycount 23;

Chris Muir
cbm@well.com

http://www.xfade.com


April 27, 2008 | 1:27 am

you’re right. i’m learning that the strength of max is its ability to create many different ways of doing things.

it kinda beats up my ego because i’m used to feeling sufficiently "clever" when it comes to music software but this whole "all possiblities" paradigm takes some serious practice. your solution is very similar to the one that thomas henriques used to create his meta-ewi. my problem is that i know what all the components are; the trigers, bangs, integers, etc…i just get confused when it come time to pick a solution.

thank you for your patch. it will give me something to study tonight. I look forward to being able to return the favor one day.

onyx


April 28, 2008 | 8:14 pm

You are absolutely right chris.
This is probably the most effective way.



PQE
May 22, 2008 | 8:44 pm

May I suggest Lbyte for quickly encoding bits into numbers as Chris explained.
pqe


Viewing 14 posts - 1 through 14 (of 14 total)