Home | News | Products | Support | Download | Sales | library | Guests | Contact | WebCam | Links
CDS Logo LanBox-Talk mail archive
 

By date: Prev | Next | Index By thread: Prev | Next | Index

Subject[LCtalk] dmx from max/jitter
FromJoost Rekveld
DateMon, 21 Jun 2004 11:32:29 +0200


Hi,


for a project recently I made the following 'landmx' max object. Below you find the patch itself, plus a demonstration patch. My object uses the otudp object by Matt Wright and the new version of aka.datagram by Masayuki Akamatsu, both available online. it is pretty straightforward: it writes lists of dmx values in a buffer, and outputs them via utp with the appropriate header. It uses a new feature in the new firmware, the ability to write values into the mixer directly.


I used it to control four grids of rgb led-tiles, each 6 by 6, and I made another object which converted jitter-matrices into dmx-values. I was outputting 540 dmx-channels at a bit more than 20 fps, no problem !

thanks to Fokko and matthijs for the support.

ciao,

Joost.






max v2;
#N vpatcher 26 83 859 592;
#P origin -219 0;
#P window setfont "Sans Serif" 9.;
#P comment 227 379 110 196617 otudp by Matt Wright;
#P newex 547 159 33 196617 zl len;
#P newex 571 191 53 196617 prepend set offset;
#P newex 499 376 27 196617 gate;
#P newex 31 138 33 196617 zl len;
#P message 71 164 38 196617 set \$1;
#P newex 16 195 40 196617 accum;
#P newex 116 195 27 196617 1;
#P comment 148 197 63 196617 startchannel;
#P message 351 260 45 196617 offset 6;
#P newex 213 82 79 196617 t b 0 b b b b;
#P newex 16 227 27 196617 + 6;
#P newex 16 287 161 196617 pack 0 0 0 0;
#P newex 166 259 38 196617 & 255;
#P newex 116 259 27 196617 >> 8;
#P newex 66 259 38 196617 & 255;
#P newex 16 259 27 196617 >> 8;
#P newex 558 430 65 196617 zl group 256;
#P newex 499 403 69 196617 aka.datagram;
#P newex 652 323 65 196617 prepend host;
#P newex 483 192 61 196617 prepend set;
#P newex 547 52 239 196617 route header host startchannel tellmeudp outpacket;
#P newex 312 82 40 196617 t l l b;
#P newex 428 247 44 196617 onebang;
#N comlet lists of bytes \, bang to send;
#P inlet 213 30 15 0;
#N comlet (header 1 2 3 4) or (host 1.2.3.4 1234) or (startchannel 1) or tellmeutp;
#P inlet 547 28 15 0;
#N comlet outpacket in byteslist;
#P outlet 558 458 15 0;
#P newex 213 54 109 196617 route bang;
#P message 428 277 144 196617 192 183 0 0 202 254 0 0 0 0;
#P newex 351 321 69 196617 aka.datagram;
#P message 562 324 85 196617 tellmeeverything;
#P newex 351 376 104 196617 otudp write $1 4777;
#P newex 462 92 45 196617 loadbang;
#P comment 58 198 55 196617 nrchannels;
#P comment 44 323 137 196617 lanbox uses port 4777 \, this is the default header for writing directly into dmx-mixer \, default start channel 1 (feature available since lanbox firmware 2.00);
#P comment 227 323 110 196617 aka.datagram 1.1 by Masayuki Akamatsu;
#P fasten 25 2 29 0 244 118 21 118;
#P fasten 30 0 29 0 76 188 21 188;
#P connect 29 0 24 0;
#P connect 24 0 19 0;
#P connect 19 0 23 0;
#P fasten 13 1 31 0 332 132 36 132;
#P connect 31 0 29 1;
#P fasten 34 0 24 1 552 221 38 221;
#P fasten 24 0 20 0 21 251 71 251;
#P connect 20 0 23 1;
#P fasten 25 1 30 0 231 113 76 113;
#P fasten 25 3 28 0 257 123 121 123;
#P connect 28 0 21 0;
#P connect 21 0 23 2;
#P fasten 14 2 28 1 642 136 138 136;
#P fasten 28 0 22 0 121 241 171 241;
#P connect 22 0 23 3;
#P connect 11 0 8 0;
#P connect 8 0 25 0;
#P connect 8 1 13 0;
#P fasten 25 4 26 0 270 160 356 160;
#P fasten 33 0 26 0 576 238 356 238;
#P fasten 25 0 6 0 218 302 356 302;
#P fasten 13 0 6 0 317 296 356 296;
#P fasten 23 0 6 0 21 313 356 313;
#P connect 26 0 6 0;
#P fasten 7 0 6 0 433 308 356 308;
#P connect 6 0 4 0;
#P fasten 16 0 4 0 657 357 356 357;
#P fasten 5 0 4 0 567 353 356 353;
#P fasten 13 2 12 0 347 132 433 132;
#P fasten 15 0 7 0 488 271 433 271;
#P connect 12 0 7 0;
#P fasten 25 5 12 1 283 118 467 118;
#P connect 3 0 12 1;
#P fasten 14 0 15 0 552 150 488 150;
#P fasten 14 4 32 0 732 361 504 361;
#P connect 32 0 17 0;
#P fasten 6 0 32 1 356 345 521 345;
#P connect 10 0 14 0;
#P fasten 14 0 34 0 552 150 552 150;
#P connect 17 1 18 0;
#P connect 18 0 9 0;
#P fasten 14 3 5 0 687 312 567 312;
#P fasten 34 0 33 0 552 183 576 183;
#P fasten 14 1 16 0 597 86 657 86;
#P pop;






max v2;
#N vpatcher 208 340 886 648;
#P button 76 139 15 0;
#P window setfont "Sans Serif" 9.;
#P message 10 165 85 196617 1 2 3 4 5 6 7 8 9;
#P toggle 518 125 15 0;
#P newex 177 223 63 196617 print packet;
#P message 518 147 65 196617 outpacket \$1;
#P message 405 149 80 196617 startchannel \$1;
#P number 406 129 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P message 290 138 103 196617 host 127.0.0.1 4777;
#P newex 116 161 27 196617 t b l;
#P number 60 98 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 212 98 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 174 98 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 136 98 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 98 98 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 117 137 69 196617 pak 0 0 0 0 0;
#P message 264 70 51 196617 tellmeutp;
#P newex 177 197 95 196617 landmx 10.0.0.201;
#P comment 47 51 100 196617 lists set values in dmx buffer \, bang sends values out;
#P comment 252 49 100 196617 report status of utp;
#P comment 291 105 100 196617 set host (always include portnr);
#P comment 395 97 100 196617 dmx channel to start writing (default = 0);
#P comment 506 98 100 196617 switch monitoring output on/off;
#P connect 7 0 13 0;
#P connect 12 0 7 0;
#P connect 8 0 7 1;
#P connect 9 0 7 2;
#P connect 10 0 7 3;
#P connect 11 0 7 4;
#P connect 21 0 5 0;
#P connect 20 0 5 0;
#P connect 13 1 5 0;
#P connect 13 0 5 0;
#P connect 5 0 18 0;
#P connect 17 0 5 1;
#P connect 16 0 5 1;
#P connect 14 0 5 1;
#P connect 6 0 5 1;
#P connect 15 0 16 0;
#P connect 19 0 17 0;
#P pop;


By date: Prev | Next | Index By thread: Prev | Next | Index