Previously subject : get console messages for Arduino In attachment, my solution to detect automatically an Arduino Board with Firmata. I wonder if we could get the device name of the console output, it would be easier to detect... Any suggestions ?
Thanks, Jerome
#N canvas 18 79 1046 711 10; #X msg 52 398 devices; #X msg 126 99 1; #X obj 311 567 sel 0; #X msg 311 588 0; #X obj 126 78 t b b; #X msg 463 311 ports; #X obj 219 583 unpack f s; #X obj 594 502 b; #X msg 594 522 0; #X msg 631 525 1; #X obj 561 569 spigot; #X msg 126 314 close; #X msg 287 333 info; #X obj 287 309 del 1000; #X msg 169 312 close \, open \$1; #X obj 183 213 r \$0-port; #X obj 126 144 sel 0 1; #X obj 169 172 t b b b; #X obj 126 434 pduino/arduino 1; #X obj 126 123 tgl 15 0 empty empty empty 17 7 0 10 -257985 -1 -1 1 1; #X obj 126 57 loadbang; #X floatatom 183 236 5 0 0 0 - - -; #X obj 46 99 r \$0-onoff; #X obj 311 608 s \$0-onoff; #X obj 219 607 s \$0-port; #X obj 169 263 f 1; #X msg 561 594 0; #X obj 561 614 s \$0-onoff; #X obj 561 414 t b b; #X obj 561 453 del 3500; #X text 509 311 <- test 1 : get port number of the last serial port ; #X text 326 332 <- for test2; #X text 309 629 test 2 : if the port is not accessible \; close the serial port; #X obj 219 468 route ports open version; #X obj 240 433 print ARDUINO_OUT; #X text 662 514 if the version message is received \, it means \; it's an Arduino with Firmata \; if not it is not an Arduino \, a bluettooth device in Mac Os); #X text 68 7 Auto-detect Arduino board \; --------------------------- ; #X text 216 629 test 1; #X text 622 452 test3. Wait for "version message"; #X text 558 632 test 3; #X connect 0 0 18 0; #X connect 1 0 19 0; #X connect 2 0 3 0; #X connect 3 0 23 0; #X connect 4 0 1 0; #X connect 4 1 5 0; #X connect 5 0 18 0; #X connect 6 0 24 0; #X connect 7 0 8 0; #X connect 8 0 10 1; #X connect 9 0 10 1; #X connect 10 0 26 0; #X connect 11 0 18 0; #X connect 12 0 18 0; #X connect 13 0 12 0; #X connect 14 0 18 0; #X connect 15 0 21 0; #X connect 16 0 11 0; #X connect 16 1 17 0; #X connect 17 0 25 0; #X connect 17 1 13 0; #X connect 17 2 28 0; #X connect 18 1 33 0; #X connect 18 1 34 0; #X connect 19 0 16 0; #X connect 20 0 4 0; #X connect 21 0 25 1; #X connect 22 0 19 0; #X connect 25 0 14 0; #X connect 26 0 27 0; #X connect 28 0 29 0; #X connect 28 1 9 0; #X connect 29 0 10 0; #X connect 33 0 6 0; #X connect 33 1 2 0; #X connect 33 2 7 0; #X coords 0 711 1 710 57 208 0;
_______________________________________________ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list