20. Project Development

Final Project Proposal

The 2D chair - initial idea

In modern times, the houses of people in cities have become smaller but the needs have increased.
Most of the furniture pieces in a house are not used most of the time. So why waste space?

What I propose here is a chair which transforms into a planar surface hence occupying minimum space when not in use.

Initial Idea

Initial Idea

The Process of Transformation

Folding stage 1 : The chair when in use

1

Folding stage 2 : One member sticks to the wall

2

Folding stage 3 : The chair starts to fold into a 2d plane

3

Folding stage 4 : The chair becomes 2d occupying zero floor space

4

Components

The final chair assembly with have primary four types of fabricated parts.

  1. Wall Mount - The box that holds the chair will be mounted to the wall and will also contain all the electronic components including the motors, PCB, and the input devices.

4

  1. Frame Member 1 - One of the two types of members supporting the chair. 4 of each will be used in one chair.

4

  1. Frame Member 2 - The other member supporting the chair. There will be 4 of these members too.

4

  1. Seating - The seating and the backrest which unfolds with the frame.

4

Input/Output Devices

Input

  1. Though I planned to use Motion detectors to open the chair, I feel using a touch sensor would be more ideal since with motion detectors, the chair might start unfolding without someone actually wanting it to.

4

  1. The second will be ultrasonic sensor that will detect if someone is standing in front of the chair. If there is, the unfolding process would stop to prevent someone getting hurt.

4

  1. The third will be a pressure sensor which will initiate the folding of the chair to 2d plane after it is unused for 60 seconds.

4

Output

  1. In both cases, the output will be thw two synchronised motors.

4

Detail drawings and dimensions

drawings

Joinery Detail Examples

joinery 1 joinery 2

Requirements

Challenges

Deliverables

References

Transformation

Output Devices

During Output devices, I wrote this code to use the touch sensor and ultrasonic sensor to run the motor exactly as I wished to for my final project.

#define ctsPin A1 //defines input pin
const int trigPin = A2; 
const int echoPin = A3; //Constant Integer value
long duration;
int distance; 
int ledPin = 13;
int m1 = 6;
int m2 = 7; defines the specified pin numbers as integers

void setup()
{     
  Serial.begin(9600);     // Starts the serial communication
  pinMode(ledPin, OUTPUT); // defines output
  pinMode(m1, OUTPUT); // defines output
  pinMode(m2, OUTPUT); // defines output
  pinMode(ctsPin, INPUT); // defines input
  pinMode(trigPin, OUTPUT); // Sets the trigPin as an Output
pinMode(echoPin, INPUT); // Sets the echoPin as an Input
}

void loop() // starts the loop
{     
  digitalWrite(trigPin, LOW); 
delayMicroseconds(2);  
digitalWrite(trigPin, HIGH);
delayMicroseconds(10); // Sets the trigPin on HIGH state for 10 micro seconds
digitalWrite(trigPin, LOW); // Reads the echoPin, returns the sound wave travel time in microseconds
duration = pulseIn(echoPin, HIGH);
// Calculating the distance
distance= duration*0.034/2; // Calculating the distance
Serial.print("Distance: ");
Serial.println(distance); // Prints the distance on the Serial Monitor
  int ctsValue = analogRead(ctsPin);     

  if (ctsValue >= 400  && distance >6) // condition 1
  {    
    digitalWrite(ledPin, HIGH);   
    digitalWrite(m1,HIGH);
    digitalWrite(m2,LOW);  // output
    Serial.println("TOUCHED");  // Output in serial monitor

  }   
  if ( distance <5)  //condition 2
  {     
    digitalWrite(ledPin,LOW);  
    digitalWrite(m2,LOW);
    digitalWrite(m1,LOW);    // output
    Serial.println("not touched");  // Output in serial monitor

  }
  else // condition 3
  {
    digitalWrite(ledPin,LOW);  
    digitalWrite(m2,LOW);
    digitalWrite(m1,LOW);  // output
  }
}

Here, the ultrasonic will be fixed in front of the chair so the chair does not unfold on a person standing in front of it. The touch switch won’t take an input in th event of someone standing in front.

Project Plan - Timeline

1:2 model

During the break week, I decided to make a 1:2 model to get more idea about the working of the folding mechanism.

finale

Final Components

Motors and Motor Driver

The previos model gave me an estimate of the weight of my final prototype. So accordingly, I bought the motors.

Specifications :

  1. Base Motor RPM: 6000
  2. Rated Voltage: 12 V
  3. Rated Torque: 22 kg-cm
  4. Stall Torque: 90 kg-cm
  5. Gearbox Dimensions: 72 x 47 x 20 mm(LxWxH)
  6. Shaft Length: 25.6 mm
  7. Shaft : 8mm
  8. No Load Current : 500MA (MAX), LOAD CURRENT= 700MA (MAX).

finale

finale

Updated board

finale finale finale

Testing the motor driver with the mototrs.

finale

#define rPWM 5
#define fPWM 6
#define rEN 7
#define fEN 8

void setup() {
  pinMode(rPWM, OUTPUT);
  pinMode(fPWM, OUTPUT);
  pinMode(rEN, OUTPUT);
  pinMode(fEN, OUTPUT);

}

void loop() {
  forward(255);
  delay(1000);
  pause();
  delay(500);
  reverse(255);
  delay(1000);
  pause();
  delay(500);
}

void forward(int speed)
{
  digitalWrite(rEN, HIGH);
  digitalWrite(fEN, HIGH);
  analogWrite(rPWM, speed);
  digitalWrite(fPWM, LOW);
}

void reverse(int speed)
{
  digitalWrite(rEN, HIGH);
  digitalWrite(fEN, HIGH);
  analogWrite(fPWM, speed);
  digitalWrite(rPWM, LOW);
}

void pause()
{
    digitalWrite(rEN, LOW);
  digitalWrite(fEN, LOW);
  analogWrite(fPWM, LOW);
  digitalWrite(rPWM, LOW);  
  }

The Mechanism

4

finale

finale

finale

For information on how to use the dxf file for CNC Cutting, visit week 8

finale

finale

Problems faced and fixes

finale

finale

finale

finale finale

finale

finale

Unsuccessful Solution 1 : I tried to reduce the weight of the members by removing extra material from the centre.

finale

Successful Solution 2 : I decided to use the same parts and change the design and the mechanism to manufacture my furniture prototype. This is how that transformation went.

finale finale

Mounting the pulley

Final Assembly

Programming the board

#include <Ultrasonic.h>
#define rPWM 5
#define fPWM 6
#define rEN 7
#define fEN 8
#define touchSW A1
#define limit1 A2
#define limit2 A3

Ultrasonic ultrasonic(11,12);
int distance;
int sw1;
int sw2;
int touch;
void forward(int speed)
{
  digitalWrite(rEN, HIGH);
  digitalWrite(fEN, HIGH);
  digitalWrite(rPWM, HIGH);
  digitalWrite(fPWM, LOW);
  digitalWrite(13,HIGH);
}

void reverse(int speed)
{
  digitalWrite(rEN, HIGH);
  digitalWrite(fEN, HIGH);
  digitalWrite(fPWM, HIGH);
  digitalWrite(rPWM, LOW);
  digitalWrite(13,LOW);
}

void pause()
{
    digitalWrite(rEN, LOW);
  digitalWrite(fEN, LOW);
  analogWrite(fPWM, LOW);
  digitalWrite(rPWM, LOW);  
  }

void setup() {

  pinMode(rPWM, OUTPUT);
  pinMode(fPWM, OUTPUT);
  pinMode(rEN, OUTPUT);
  pinMode(fEN, OUTPUT);
  pinMode(13,OUTPUT);
  pinMode(touchSW,INPUT);
  pinMode(limit1,INPUT_PULLUP);
  pinMode(limit2,INPUT_PULLUP);
  pinMode(13,OUTPUT);

  Serial.begin(9600);
}

void loop() {

  distance = ultrasonic.read();
  sw1 = analogRead(limit1);
  sw2 = analogRead(limit2);
  touch = analogRead(touchSW);
  Serial.println("distance");
  Serial.print(distance);
  Serial.println("sw1");
  Serial.print(sw1);
  Serial.println("sw2");
  Serial.print(sw2);
  Serial.println("touch");
  Serial.print(touch);
  if( touch >= 500  )
  {
    forward(255);
    delay(100);


  }
  else if (distance > 20)
  {
  reverse(255);
  //  pause();

  }


  if (sw2 <= 400)
  {
     pause();
  }

  }

finale

Files

Creative Commons License
2D chair by Dhruv Thakker