description | allow IXM's to report back to central collector |
owner | schulte.eric@gmail.com |
last change | Wed, 24 Feb 2010 16:52:13 +0000 (24 09:52 -0700) |
URL | git://repo.or.cz/ixm-collector.git |
https://repo.or.cz/ixm-collector.git | |
push URL | ssh://repo.or.cz/ixm-collector.git |
https://repo.or.cz/ixm-collector.git (learn more) | |
bundle info | ixm-collector.git downloadable bundles |
content tags |
See here information on the Illuminato X Machina (IXM)
The collector is a small utility which can be included in your
sketches to allow printing directly back to a central observer
(probably your laptop) through a virtual face. The following example
sketch (included as sketch.pde
in this repository) demonstrates it's
usage.
/* -*- mode:C++ -*- * * Sketch description: Simple demonstration of the collector * * Sketch author: Eric Schulte * */ #include "collector.h" // include the collector int cface; // the virtual face assigned to the // collector int ledPin = 13; // LED connected to digital pin 13 int wait; // a variable for the delay time void setup() { cface = collector_init(); // initialize the collector and assign // the virtual face } void loop() { wait = random(2000); // set wait to a random number delay(wait); // wait for the assigned time digitalWrite(ledPin, LOW); // sets the LED on // print to the collector face and the result will be automatically // routed to your laptop facePrintf(cface, "waited %d miliseconds\n", wait); delay(500); // wait for the assigned time digitalWrite(ledPin, HIGH); // sets the LED off }
Once this sketch has burned to your boards, you send a c
-packet
(c2
in the example below) telling your boards that you will be the
collector. Each c
-packet should contain a number – boards keep
track of the highest c
-number they have received and will ignore any
c
-packets with lower numbers. Once the boards receive this
c
-packet their collector face will be connected to the sender of the
c
-packet. this is should in the following output of the above
example sketch.pde
.
Ln 11.602 [Sending checksum South for 0x10014+32748=AAD8E8E5-86FBCC66] Ln 16.257 [Sending checksum North for 0x18000+12204=A3E9651E-194595F0] Ln 17.953 [Sending checksum South for 0x18000+12204=A3E9651E-194595F0] Ln 19.283 [North burned successfully!] Ln 20.985 [South burned successfully!] c2 (-1,1) waited 1349 miliseconds (0,0) waited 3888 miliseconds (1,-1) waited 2374 miliseconds (1,0) waited 4205 miliseconds (-1,-1) waited 2570 miliseconds (1,1) waited 2540 miliseconds (-1,0) waited 3334 miliseconds (1,1) waited 1485 miliseconds (0,0) waited 2455 miliseconds (-1,1) waited 4452 miliseconds (-1,-1) waited 3534 miliseconds (1,0) waited 3948 miliseconds (1,-1) waited 4650 miliseconds (1,-1) waited 430 miliseconds (-1,0) waited 4916 miliseconds (1,-1) waited 464 miliseconds (0,0) waited 3712 miliseconds
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
See the file COPYING for a copy of the GNU General Public License or write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
2010-02-24 | Eric Schulte | adding GPL V3master | commitcommitdifftreesnapshot (tar.gz zip) |
2010-02-16 | Eric Schulte | adding link to IXM main page | commitcommitdifftreesnapshot (tar.gz zip) |
2010-02-16 | Eric Schulte | adding documentation file | commitcommitdifftreesnapshot (tar.gz zip) |
2010-02-16 | Eric Schulte | now able to accept c-packets w/o a space following... | commitcommitdifftreesnapshot (tar.gz zip) |
2010-02-16 | Eric Schulte | adding example sketch | commitcommitdifftreesnapshot (tar.gz zip) |
2010-02-16 | Eric Schulte | initial commit -- just what's required for the collector | commitcommitdifftreesnapshot (tar.gz zip) |
14 years ago | master | logtree |