2 #+OPTIONS: num:nil ^:nil
5 See [[http://illuminatolabs.com/IlluminatoXMachina.htm][here]] information on the /Illuminato X Machina/ (IXM)
7 The collector is a small utility which can be included in your
8 sketches to allow printing directly back to a central observer
9 (probably your laptop) through a virtual face. The following example
10 sketch (included as =sketch.pde= in this repository) demonstrates it's
16 * Sketch description: Simple demonstration of the collector
18 * Sketch author: Eric Schulte
21 #include "collector.h" // include the collector
22 int cface; // the virtual face assigned to the
24 int ledPin = 13; // LED connected to digital pin 13
25 int wait; // a variable for the delay time
28 cface = collector_init(); // initialize the collector and assign
33 wait = random(2000); // set wait to a random number
34 delay(wait); // wait for the assigned time
35 digitalWrite(ledPin, LOW); // sets the LED on
36 // print to the collector face and the result will be automatically
37 // routed to your laptop
38 facePrintf(cface, "waited %d miliseconds\n", wait);
39 delay(500); // wait for the assigned time
40 digitalWrite(ledPin, HIGH); // sets the LED off
44 Once this sketch has burned to your boards, you send a =c=-packet
45 (=c2= in the example below) telling your boards that you will be the
46 collector. Each =c=-packet should contain a number -- boards keep
47 track of the highest =c=-number they have received and will ignore any
48 =c=-packets with lower numbers. Once the boards receive this
49 =c=-packet their collector face will be connected to the sender of the
50 =c=-packet. this is should in the following output of the above
54 Ln 11.602 [Sending checksum South for 0x10014+32748=AAD8E8E5-86FBCC66]
55 Ln 16.257 [Sending checksum North for 0x18000+12204=A3E9651E-194595F0]
56 Ln 17.953 [Sending checksum South for 0x18000+12204=A3E9651E-194595F0]
57 Ln 19.283 [North burned successfully!]
58 Ln 20.985 [South burned successfully!]
60 (-1,1) waited 1349 miliseconds
61 (0,0) waited 3888 miliseconds
62 (1,-1) waited 2374 miliseconds
63 (1,0) waited 4205 miliseconds
64 (-1,-1) waited 2570 miliseconds
65 (1,1) waited 2540 miliseconds
66 (-1,0) waited 3334 miliseconds
67 (1,1) waited 1485 miliseconds
68 (0,0) waited 2455 miliseconds
69 (-1,1) waited 4452 miliseconds
70 (-1,-1) waited 3534 miliseconds
71 (1,0) waited 3948 miliseconds
72 (1,-1) waited 4650 miliseconds
73 (1,-1) waited 430 miliseconds
74 (-1,0) waited 4916 miliseconds
75 (1,-1) waited 464 miliseconds
76 (0,0) waited 3712 miliseconds
79 This program is free software; you can redistribute it and/or modify
80 it under the terms of the GNU General Public License as published by
81 the Free Software Foundation; either version 3, or (at your option)
84 This program is distributed in the hope that it will be useful, but
85 WITHOUT ANY WARRANTY; without even the implied warranty of
86 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
87 General Public License for more details.
89 See the file COPYING for a copy of the GNU General Public License or
90 write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
91 Floor, Boston, MA 02110-1301, USA.
93 #+HTML: <img src="http://www.gnu.org/graphics/gplv3-88x31.png"/>