DIARY OF THE FLYING CLOCKMAKER
MAY 2011
Contacting Reni, Isjtar, Barb, organising meetings and planing building trip to Bruessels.
Trying out materials that can be used as analog sensors outdoors. Conductive thread, fabric, ink, graphite, etc.
JUNE 2011
Building a wodden Wind Clock based on the leonardo model (Setting: 30 - 60 - 500).
7.6. 2011 Meeting Reni
tinkering with velotex:
Velotex is a cheap material you can order on http://www.plugandwear.com/
and http://www.lessemf.com/
Velotex is resistive, with a decreasing resistance if bended or pressed. It therefore would work well as a cheap, sustainable and waterproof bend sensor.
Try to build a fabric bend sensor that's water proof. Have been lazor cutting conductive fabric, worked well. (same setting as “leather”)
8.6.2011 Accelerameter
trying out more sensors
I lazorcutted two more wodden leonardo clocks in order to mount three different sensors.
It was 6,50 EUR for two clocks. Plus twice 5,20 EUR for the material.
Now I try to assemble the two new clocks and think about better measurement systems (e.g. infrared-light-sensor, Ultrasonic Sensor, etc..)
Or maybe simpler and easier and cheaper ways of measuring as e.g. just adding a potentiometer at the top of the moving part in the clock.
Maybe cut something from an old plastic foil in a way that you can fold it like origami and use it as a wind sail.
14.-17.6. 2011
Pure Data
Working with students in connecting clocks analog input to Pure Data.
I gave a 4 hours workshop in DIY sensors at the University of Applied Arts, with students of the Digital Media Art department in Vienna. We assembled 4 wodden clocks and experimented with the range of ultrasonic sensors, an accelerameter, self made bend sensors and Pure Data via Arduino. Talke to Reni about our next session when we will work on the connecting point to the server.
Also made an appointment with Barb to meet her for a tinkering session in Metalab this coming Monday.
20.6.2011
Working afternoon with Barb. We met between 14h-18h to talk about clock models and alternative materials for clock making.
Together we came up with a lot of lovely ideas on how to extend the model or substitute it with a simpler modification.
We also agreed to meet again beginning of july to actually build the ones we came up with.
Here is some research we did:
BEND SENSORS BIG SCALE
http://www.plugandwear.com/default.asp?mod=cat&cat_id=86
ARDUINO LILY PAD ETHERSHIELD
http://www.arduino.cc/en/Main/ArduinoEthernetShield
DIY accelerameter
http://www.plusea.at/
WIND IN THE CITY -prophecies on how the wind blows by research department in Innsbruck:
http://derstandard.at/1287099958444/Wetterlaunen-berechnen-Innsbrucker-Forscher-wollen-den-Wind-besser-vorhersagen
USING ORGANIC MATERIALS FOR SENSING
http://nilseuropa.com/?p=137
http://www.instructables.com/id/Moss-Graffiti/
IDEAS:
Build a frame instead of putting the whole clock on one stick
Wäscheleinensensor
Windorgel (viele hintereinander hängende Stoffstücke mit Sensor)
Segel statt Holzplatte auf clock und symmetrisch
Plastik bottle wind mill
Gras touch sensor
Infusions Flasche über Moos Sensor
Falted Paper Sail
22.6.2011
Took out old stepper motor from a PC hardware previously connected to the harddrive. Wonderful to connect to pins and use as ball bearing substitute to have a wind wheel turn and generate current. Had a simple wind wheel attached that generated impulses between 0.01 and 0.2 Volts which was enough to trigger sounds in Pure Data over PDuino (Firmata Library).

3.July 2011
Today Barb and me met to work the whole day on the new clocks. We (almost) made 4 clocks:
1. Three Photoresistor clocks (Leonardo in wood), conductive ink instead of cables
2. A bed sheet sensor (bed sheet fabric, velostat, tape, conductive thread)
3. Feather sensor (Feather, conductive ink)
4. Capacitive Sensor (http://www.arduino.cc/playground/Code/CapacitiveSensor)
TO DO NEXT TIME:
: : Sheet sensor: Not only one sensor, but maybe three, maybe wire them up with fabric lines, not thread lines.
: : Barb bring material that takes liquid up to the moss.
: : Stefanie bring drip-feeding bottle from hospital
CAPACITOR MOSS SENSOR CODE FOR ARDUINO:
/*Capacitative Sensing Code for ATMega328 Arduinos*/
/*Sensor key demonstrates how the Arduino
can sense a touch sensitive key through
digital pins 8 to 13. It requires no special hardware,
nevertheless a capacitor of 1nF is recommended in
line with the pin to decouple 50Hz noises
*/
void setup()
{
Serial.begin(9600); // connect to the serial port
}
void loop ()
{
char capval[6];
char pinval[6] = {1<<PINB0,1<<PINB1,1<<PINB2,1<<PINB3,1<<PINB4,1<<PINB5};
delay(1000);
for(char i = 0; i < 6; i++)
{
capval[i] = getcap(pinval[i]);
Serial.print("digital ");
Serial.print(i+8, DEC);
Serial.print(": ");
Serial.println(capval[i], DEC);
}
Serial.println("");
}
returns capacity on one input pin
pin must be the bitmask for the pin e.g. (1«PB0)
char getcap(char pin)
{
char i = 0; DDRB &= ~pin; // input PORTB |= pin; // pullup on for(i = 0; i < 16; i++) if( (PINB & pin) ) break; PORTB &= ~pin; // low level DDRB |= pin; // discharge return i;
}

Trying to get humidity to the moss
cutting more windclocks
capacitor sensor
Barb was getting moss from upper austria, fresh from mother nature 
nice signals coming in
fabric with tape and conductive, yet resistive material, conductive thread as plus and minus layers
bend sensor on fabric
making a mess at metalab :)

sketch
making a bird's house for the clock
covering each hair of the feather with conductive ink, brushing them apart so that they become less resistive when wind tosses them apart
JULY 6th 2011
First day in Ghent with you folks
Came to Timelab and found out we can use everything always as much as we want. Paradise. Made a new wodden clock and a pressure sensor from the stuff that micro ship are sold on (little black foam pillows), also tried to make a sensor from copper, but stupid copper in mantled with something not conductive, testes a lot of different materials, talked to Gi about parachute sensors etc.. Tomorrow more and with more energy (was travelling from morning of the 5th until morning of the 6th of July…
PRESSURE / FORCE SENSOR FOR PARACHUTE CLOCK
WOW::::::
FOXHOLE RADIO!!!!! Marcio just explained to me the magic of tessler coils and radios made out simply a magnet and a coil in the most simple form
http://www.kobakant.at/DIY/?p=2936
need to get this book:
Practival Electronics for Inventors
and this:
Muscle Wire
7th of JULY 2011
FROM THE BOOK practical electronics for inventors:
“INDUCTORS
An inductor is an electrical component whose behavior is opposite to that of a capacitor (it “resists” changes in current while passing steady-state or DC current). An inductor resembles a springlike coil or solenoid, shown below.
The inductor coil has a loop area A and a constant number of turns per unit lenght (N/l). If a current I flows through the inductor, by Ampere's law, a magnetic flux will (flux = BA=µ NIA/l form, and it will point in the opposite direction as the current flow. Here µ is the permeability of the material on which the coil is wound (typically an iron or air core). In free space , µ=µ0= 4pee times 10 high -7 N/A2. According to Faraday's law, the voltage induced across the terminals of the coils as a result of the magnetic fields is
(…)
The constant is called inductance, which is simplified into the single constant L.
Inductance has units of henrys (abbreviated H) and is equal to one weber per ampere. Typical values for inductors range from 1µH (10higher -6 H) to about 1H.
To find expression for the current through an inductor, you can rearrange the preceding equation to get the following (..).
Similar to capacitors, inductors do not dissipate energy like resistors; instead, they store electrical energy in the form of magnetic fields about their coils. The energy W stored in an incustor can be determined by using the electrical power expression P =IV and the expression for the definition of power P=dW/dt and then doing some math: (…)
So I made two coils, one from conductive thread on fabric, one of conductive ink on paper. The paper one from ink is bigger and works therefore a bit better.
I attached an amplifyer circuit with an LM386 and got some nice signals and sounds, but it was not very reliable yet.



8th of JULY 2011
The opposite of a coil is a capacitor. So now I made a capacitor sensor that works with two pins that get compared to each other. Between them I have a 1 Mega Ohm resistor and from the receiver pin to ground I have a capacitor of 100 µF 16 V
http://www.arduino.cc/playground/Main/CapSense
Mixture of Cap Sensor Code with Tone Pitch Follower Code:
.
. /
/ .
.
. /
/ .
#include <CapSense.h>
/*
* CapitiveSense Library Demo Sketch
* Paul Badger 2008
* Uses a high value resistor e.g. 10M between send pin and receive pin
* Resistor effects sensitivity, experiment with values, 50K - 50M. Larger resistor values yield larger sensor values.
* Receive pin is the sensor pin - try different amounts of foil/metal on this pin
*/
CapSense cs_4_2 = CapSense(4,2); 10M resistor between pins 4 & 2, pin 2 is sensor pin, add a wire and or foil if desired
CapSense cs_4_5 = CapSense(4,5); 10M resistor between pins 4 & 6, pin 6 is sensor pin, add a wire and or foil
CapSense cs_4_8 = CapSense(4,8); 10M resistor between pins 4 & 8, pin 8 is sensor pin, add a wire and or foil
void setup()
{
cs_4_2.set_CS_AutocaL_Millis(0xFFFFFFFF); turn off autocalibrate on channel 1 - just as an example
Serial.begin(9600);
}
void loop()
{
long start = millis(); long total1 = cs_4_2.capSense(30); //long total2 = cs_4_5.capSense(30); // long total3 = cs_4_8.capSense(30);
Serial.print(millis() - start); // check on performance in milliseconds
Serial.print("\t"); // tab character for debug windown spacing
Serial.print(total1); // print sensor output 1
Serial.println("\t");
//Serial.print(total2); // print sensor output 2
//Serial.print("\t");
//Serial.println(total3); // print sensor output 3
int thisPitch = map(total1, 100, 1000, 100, 1000);
tone(8, thisPitch, 10);
delay(20); // arbitrary delay to limit data to serial port
}





.
. /
/ .
.
. /
/ .
MICROPHONE SKETCH FOR ARDUINO
uses the BOB-08669 breakout board for the electret microphine
const int ledPin = 13; the code will flash the LED in pin 13
const int middleValue = 512; middle of range of analog values
const int numberOfSamples = 128; how many readings will be taken each time
int sample; the value read from microphone each time
long signal; the reading once you have removed DC offset
long averageReading; the average of that loop of readings
long runningAverage = 0; the running average of calculated values
const int averagedOver = 16; how quickly new values affect running average. bigger numbers mean slower
const int threshold=400; at what level the light turns on
void setup (){
pinMode(ledPin, OUTPUT); Serial.begin(9600); }
void loop(){
long sumOfSquares = 0;
for(int i=0; i<numberOfSamples; i++) { //take many readings and average them
sample =analogRead(0); //take a reading
signal=(sample - middleValue); //work out its offset from the center
signal *= signal; // square it to make all values positive
sumOfSquares += signal; // add to the total
}
averageReading = sumOfSquares/numberOfSamples; //calculated running average
runningAverage = (((averagedOver-1)*runningAverage)+averageReading)/averagedOver;
if (runningAverage>threshold){ //is average more than the threshold?
digitalWrite(ledPin, HIGH); //if it is turn on the LED
}else{
digitalWrite(ledPin, LOW); //if it isn't turn the LED off
}
Serial.println(runningAverage); //print the value so you can check it
}
.
. /
/ .
.
. /
/ .
LM 386 as an amplifyer with a Piezo WORKED REALLY WELL .. numbers from 150 to 20 000
http://www.national.com/mpf/LM/LM386.html#Overview
With the paper coil I get numbers between 16 000 and 22 000 depending on how far my magnet is away.
With the yellow coil it's the same. I have the same results with my hand as with the magnet.
The white flag coil works really well now with the magnet, give in nice numbers depending on how far away I am with the magnet.
Now I neet a counter to reset the maximum and minimum level.
JULY 15th 2011
Trying to connect our clock via ethershield to the server. Barb and me sit inside Metalab and change the VortexClock Code and and the Arduino Ehternet Library Code “Webclient”. It's a little frustrating since we think there is no bug, but it still doesn't work ;)… we will not surrender…
::::::::::::::
#include <SPI.h>
#include <Ethernet.h>
Network setup, you should adapt this of course
byte mac[] ={ 0x90, 0xA2, 0xDA, 0x00, 0x16, 0x5D};
byte ip[] = {10,20,30,245};
byte gateway[] = {192,168,0,254};
byte subnet[] = {255, 255, 255, 0 };
byte server[] = {193,93,114,234};
byte server[] = {192,168,0,47};
initialize the library instance:
Client client(server, 30223);
clock and tik JSON strings
String clock = String(”{'name':'fakeClock2','longitude':'0.0','latitude':'0.0','altitude':'0.0','metaDataDefinitions':[{'name':'orientation','type':'int'},{'name':'windspeed','type':'int'}],'test':false}”);
int orientation = 0;
int windspeed = 0;
void setup()
{
Serial.begin(9600);
Ethernet.begin(mac, ip, gateway, subnet);
delay(1000); give ethernet shield time to boot
//make the connection
client.connect();
if(client.connected())
{
Serial.println("connected!");
client.print(clock); //first connection sends clockId to register with the TAK server
}
//give a randomSeed for our pseudoTIK, just for our example
randomSeed(analogRead(6));
}
void loop()
{
//check if connection is still up and start tikking
if(client.connected() && doesItTik) // doesItTik is a function we're defining below that has to return true for a tik to be sent
{
orientation = analogRead(0); // get some data
windspeed = analogRead(1); // other data
String tik = String("{{'metaDataValues':[{'name':'orientation','type':'int','value':") +
String(orientation) +
String("},{'name':'windspeed', 'type':'int','value':") +
String(windspeed) + String("}]}");
Serial.println(tik);
client.print(tik);
}
//wait 5 seconds and reconnect
else
{
Serial.println("no connection");
delay(5000);
client.stop();
client.connect();
client.print(clock);
}
delay(300); //make this smaller after debugging, this is a delay in the loop, so it doesn't run as fast as it can
}
replace by real function connected to WindClock
int doesItTik()
{
int tikReady = random(100) < 70;
return tikReady;
}
20th of July
BARB IS BRILLIANT, SHE GOT THIS CODE TO WORK:
#include <SPI.h>
#include <Ethernet.h>
Network setup, you should adapt this of course
byte mac[] ={
0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xEF};
byte ip[] = {10, 20, 30, 240};
byte gateway[] = {10, 20, 30, 1};
byte subnet[] = {255, 255, 255, 0};
byte server[] = {193,93,114,234};
byte server[] = {
88,190,16,207};
initialize the library instance:
Client client(server, 30223);
clock and tik JSON strings
String clock = ”{'name':'barb','longitude':0.0,'latitude':0.0,'altitude':0.0,'metaDataDefinitions':[{'name':'orientation','type':'float'}]”;
int orientation = 0;
int windspeed = 0;
void setup()
{
Serial.begin(9600); Ethernet.begin(mac, ip, gateway, subnet); delay(1000); // give ethernet shield time to boot
//make the connection
client.connect();
if(client.connected())
{
Serial.println("connected!");
client.print(clock); //first connection sends clockId to register with the TAK server
}
//give a randomSeed for our pseudoTIK, just for our example randomSeed(analogRead(6));
}
void loop()
{
//check if connection is still up and start tikking
if(client.connected() && doesItTik) // doesItTik is a function we're defining below that has to return true for a tik to be sent
{
orientation = analogRead(0); // get some data
windspeed = analogRead(1); // other data
String tik = String("{{'metaDataValues':[{'name':'orientation','type':'float','value':'0.5'}]}") +
String(orientation) +
String("},{'name':'windspeed', 'type':'int','value':") +
String(windspeed) + String("}]}");
Serial.println(tik); client.print(tik); }
//wait 5 seconds and reconnect
else
{
Serial.println("no connection");
delay(5000);
client.stop();
client.connect();
client.print(clock);
}
delay(300); //make this smaller after debugging, this is a delay in the loop, so it doesn't run as fast as it can
}
replace by real function connected to WindClock
int doesItTik()
{
int tikReady = random(100) < 70;
return tikReady;
}
AUGUST 10th 2011 : : MEETING RENI IN GRAZ
In the morning we met with the people of Kunstgarten to decide for a place and a construction to install the wind clock in their garden.
Then we went to ESC to work on the windclocks. We made 3 Wind Wheel Wind clocks with magnets and connected them to the ethershield. AND FINALLY IT WORKS!!!!




#include <SPI.h>
#include <Ethernet.h>
Network setup, you should adapt this of course
byte mac[] = {0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xFE};
byte ip[] = {89,106,215,66};
byte gateway[] = {89,106,215,65};
byte subnet[] = {255,255,255,224};
byte server[] = {88,190,16,207}; TAKE THE IP ADRESS OF THE MAIN TIK SERVER - IN THIS CASE: OKNO
initialize the library instance:
Client client(server,30223);
clock and tik JSON strings - change name, longitude, latitude, elevationto your data
String clock =String (”{'idClock':1, 'name':'kunstgarten','longitude':47.3,'latitude':15.25,'elevation':365}”);
String tik = String(”{'idClock'=1}”); hardcoded clockid;
TIK test value
int tikReady = 1;
void setup()
{
pinMode(8,INPUT);
pinMode(13,OUTPUT);
boot serial and Ethernet, serial is just to debug
Serial.begin(9600);
Ethernet.begin(mac, ip, gateway, subnet); watch out for these settings!
delay(1000); give ethernet shield time to boot
make the connection
client.connect();
if(client.connected())
{
Serial.println("connected!");
client.print(clock); //first connection sends clockId to register with the TAK server
}
randomSeed(analogRead(6));
}
int c;
boolean input, state;
void loop()
{
if(client.connected())
{
input = digitalRead(8);
if (input != state){
c++;
Serial.print©;
Serial.println(”: TIK”);
client.print(tik);
}
state = input;
}
wait 5 seconds and reconnect
else
{
Serial.println("no connection");
delay(5000);
client.connect();
client.print(clock);
}
delay(500);
}



FINALLY. YEAH.
http://www.youtube.com/watch?v=UZC8J5oX1pg