Introduction: Paper Lamp + Touch On/off Mechanism With Arduino

Picture of Paper Lamp + Touch On/off Mechanism With Arduino


:::about:::

We are going to be making lamp shade made out of paper and thread.
For it, we are going to create our own touch lamp mechanism using an Arduino board and some conductive thread. 

:::ingredients:::

1. velum paper or any semi translucent + black paper +white thread + ribbon
2. 4 or more 360 o white LEDs
3. Conductive thread ( you can buy it at sparkfun)
4. Arduino board + USB cable
5. 28 gauge wire
6. 1-10 M Ohm resistor (link to resistor Wiki)
7. straight male header
8. breadboard
9. Solder iron or wire wrapper + wire wrap
10. X-acto knife + blades


:::process:::

The process of making the paper lamp is divided in two parts:

1. Building + testing the circuit
2. Designing + Building lamp shade

Step 1: Building the Circuit

Picture of Building the Circuit


At first we are going to build our  capacitance sensing circuit on a breadboard with one LED and a stripped wire for our sensor. Eventually we will add the rest of the LEDs, replace the stripped wire for conductive thread and solder or wire wrap all the parts of circuits.

::: build capacitance sensing circuit:::

1. Connect two wires on the breadboard with a 10 M ohm resistor
2. Connect one of this wire to digital pin 8 in the Arduino board
3. Connect the other wire  to digital pin 9 in the Arduino board
4. To the same wire that is going to input 9 connect a piece of wire that it is stripped at one of its the ends. This wire is our sensor, and it will eventually be replaced,  in our chandelier,  for conductive thread
5. Connect the short leg(anode)  of an LED to GND in the Arduino board and the long leg (anode) to digital input 13


Step 2: Add Code


Copy and paste the following code in the Arduino sketch (this code is a variation of a capacitance sensing code that is pretty stable and noise free. Here is link to the original code in the Arduino forum.


// code based on CapSense.pde by Paul Badger 2007. A few changes on how I/O pins are declared.
//code can be found here http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1171076259

int  i;
unsigned int x, y;
float accum, fout, fval = .07;    // these are variables for a simple low-pass (smoothing) filter - fval of 1 = no filter - .001 = max filter

void setup() {
 Serial.begin(9600);


 pinMode(8, OUTPUT);     // output pin
 pinMode(9, INPUT);      // input pin
 pinMode(10, OUTPUT);    // guard pin
 digitalWrite(10, LOW);
 pinMode(13, OUTPUT);
 pinMode(12, OUTPUT); //could also be HIGH - don't use this pin for changing output though
}

void loop() {
 y = 0;        // clear out variables
 x = 0;

 for (i=0; i < 4 ; i++ ){       // do it four times to build up an average - not really neccessary but takes out some jitter

   // LOW-to-HIGH transition
                   // Same as line below -  shows programmer chops but doesn't really buy any more speed
  digitalWrite(8, HIGH);   
                                

      // while the sense pin is not high
     while (digitalRead(9) != 1){     // same as above port manipulation above - only 20 times slower!               
     x++;
   }
   delay(1);

   //  HIGH-to-LOW transition
                 // Same as line below - these shows programmer chops but doesn't really buy any more speed
     digitalWrite(8, LOW);             
           // while pin is not low  -- same as below only 20 times faster
     while(digitalRead(9) != 0 ) {     // same as above port manipulation - only 20 times slower!
     y++; 
   }

   delay(1);
 }

 fout =  (fval * (float)x) + ((1-fval) * accum);  // Easy smoothing filter "fval" determines amount of new data in fout
 accum = fout;
if (fout > 90 ){
   digitalWrite(13, HIGH);
   digitalWrite(12, HIGH);
 }else {
   digitalWrite(13, LOW);
   digitalWrite(12, LOW);
 }

 Serial.print( "   ");
 Serial.println( (long)fout, DEC); // Smoothed Low to High
 }


Step 3: Test Circuit

Picture of Test Circuit


1. Upload the code to your Arduino board
2. Test your circuit and code by touching the stripped wire. As you touch it the LED should be turning on
3. If it works then we are ready to start designing the chandelier. I will do this by using Illustrator but any other drawing software can be used.

Step 4: Cuttin Paper

Picture of Cuttin Paper

In the following step we will build the main body of the lamp shade:

1. Cut a trapezoid: the bottom side will be larger than the top while right and left sides are the same lengh. The side of the bottom and top will depend on how large you want your finish lamp shade to be.




Step 5: Thread Balls

Picture of Thread Balls

2. NOw that you have cut the main body of the lamp. grab some thread and make some messy balls out of long strands of thread

Step 6: Sewing a Pattern With Thread

Picture of Sewing a Pattern With Thread

3. Make a pattern of a design that you want to sew on the lamp shade. Now draw the  pattern on the velum paper you cut on step 1.
4. With a new needle start sewing the pattern.

Step 7: Attaching Thread Balls

Picture of Attaching Thread Balls

5. Once you are reaching the bottom of the lamp shade, grab the balls of thread and place them inline with the patern that you have been sewing.
6. Attach the ball by sewing over it until it is sewn firmly and it does not move.

Step 8: Gluing the Main Body of the Lamp Shade

Picture of Gluing the Main Body of the Lamp Shade

6. use hot glue to attach the short edges of the trapezoid.
7. Feel free to cut a pattern on bottom on the body of the lamp shade

Step 9: Top of the Lamp Shade

Picture of Top of the Lamp Shade

This part is made out of black paper or any other color that is going to create a nice contrast with the velum.

1. cut a rectangle about 12" in hight. it should be a litter wider than the top of your lamp shade. JUst a 1/2 " longer so you have enough material to glue on.
2. Now with you exacto knife cut vertical line about 1 " from the top and bottom edge. The lines should be 9" in high
3. NOw fold the paper over in half. Now your paper should be 6" in high.

Step 10: Attaching Black Paper to Lamp Shade

Picture of Attaching Black Paper to Lamp Shade

4. Glue sides together and attach to velum paper.

Step 11: Build Swich Mechanism

Picture of Build Swich Mechanism

In this step we sew the conductive thread to a ribbon or any other material that you want to use.
 

Step 12: Adding the LEDs

Picture of Adding the LEDs

make sure you have ready:

1. four or more 360 degree white LEDs
2. wire wrapper
3. wire wrap

1. cut a disk out of paper the same diameter as the top of your lamp shade
2. attach LEDs
4. wire all the Anodes (short legs) together to ground
5. wire the Cathode of two LEDs together to digital output 12 and 13  pins on the Arduino board ( you can use a small bread board if you want to)


Step 13: Attaching Touch Sensin Mechanism + LEDs

Picture of Attaching Touch Sensin Mechanism + LEDs

1. Now hot glue paper disk with LEDs
2. Connect conductive thread from ribbon to  digital input 9 on the Arduino board (see code for the correct one)

Step 14: Enjoy!

Picture of Enjoy!

Notice this is a needy lamp,  it needs to be touched to stay on. It was inspired by the Robot series by Dunne and Raby, my favorite designers right now. Check them out here www.dunneandraby.co.uk/content/projects/10/0
You can change the code so the sensing acts as a toggle switch.

Comments

dnicky2288 (author)2012-11-20

Nice! I love this! You can do so much more if you take the idea further!!!

About This Instructable

9,055views

13favorites

License:

More by celguero:Computer + paper = magicPaper lamp + touch on/off mechanism with Arduino
Add instructable to: