As computing becomes more ubiquitous in our objects, designers need to be more aware of how to design meaningful interactions into electronically enhanced objects. At the University of Washington, a class of junior Interaction Design majors is exploring this question. These pages chronicle their efforts.

Friday, December 13, 2019

Ponder – Adam Ahmed & Amixa-Ray Calzado


Ponder is a chair that encourages people to take time out of their day to ask themselves a mindful self-reflection question, that is printed on a ticket. We hope each person captured an essence of time and thoughtfully look forward positively. There is no particular situation we’re detecting, but rather the presence of a user. The self-reflection questions are completely randomized, allowing for people to be asked questions that they may not have thought about before. The point of this object is to allow users to reflect and be more aware of themselves and their well being. The novelty of Ponder is that it may not fully grasp the moment of every person, but it may inspire them to become better humans overall.






For detection, we used a Force-Sensing Resistor (FSR), within the cushion seat. When pressure is applied the resistance value (in ohms) to the Arduino. In our code, we are detecting values greater than 200 ohms. Which will cycle into the loop to triggering the Adafruit Thermal Printer, the actuator, to process a ticket. One ticket will print as long as the user is still on the cushion seat, once they leave the code will cycle through the loop and print again when someone else is seated.




#include <Wire.h>


/* FSR testing sketch. 

Connect one end of FSR to 5V, the other end to Analog 0.
Then connect one end of a 10K resistor from Analog 0 to ground
Connect LED from pin 11 through a resistor to ground 

For more information see www.ladyada.net/learn/sensors/fsr.html */


#include "Adafruit_Thermal.h"


#include "SoftwareSerial.h"


#include "title.h"


#include "intro.h"


#define TX_PIN 6 // Arduino transmit  YELLOW WIRE labeled RX on printer
#define RX_PIN 5 // Arduino receive   GREEN WIRE labeled TX on printer


SoftwareSerial mySerial(RX_PIN, TX_PIN); // Declare SoftwareSerial obj first
Adafruit_Thermal printer(&mySerial);     // Pass addr to printer constructor


int fsrAnalogPin = 0; // FSR is connected to analog 0


int fsrReading;      // the analog reading from the FSR resistor divider


int printerLife;


String phrases[] = { 
"Am I using my time wisely?",
"Am I taking anything for granted?",
"Am I employing a\nhealthy perspective?",
"Am I living true to myself?",
"Am I waking up in the morning\nready to take on the day?",
"Am I thinking negative thoughts\nbefore I fall asleep?",
"Am I putting enough effort\ninto my relationships?",
"Am I taking care of\nmyself physically?",
"Am I letting matters that\nare out of my control\nstress me out?",
"Am I achieving the goals\nthat I've set for myself?",
};
String output;


int numberofphrases = 10;


#include "RTClib.h"


RTC_DS3231 rtc;


void setup() {
  Serial.begin(19200);   // We'll send debugging information via the Serial monitor


  pinMode(7, OUTPUT); digitalWrite(7, LOW);


  // NOTE: SOME PRINTERS NEED 9600 BAUD instead of 19200, check test page.
  mySerial.begin(19200);  // Initialize SoftwareSerial
  //Serial1.begin(19200); // Use this instead if using hardware serial
  printer.begin();        // Init printer (same regardless of serial type)


  delay(3000); // wait for console opening


  if (! rtc.begin()) {
    Serial.println("Couldn't find RTC");
    while (1);
  }


  if (rtc.lostPower()) {
    Serial.println("RTC lost power, lets set the time!");
  
  // Comment out below lines once you set the date & time.
    // Following line sets the RTC to the date & time this sketch was compiled
    rtc.adjust(DateTime(F(__DATE__), F(__TIME__)));
  
    // Following line sets the RTC with an explicit date & time
    // for example to set January 27 2017 at 12:56 you would call:
    // rtc.adjust(DateTime(2017, 1, 27, 12, 56, 0));
  }
}



  
void loop() {
  fsrReading = analogRead(fsrAnalogPin);
  Serial.println(fsrReading);
  DateTime now = rtc.now();
  
  delay(100);


      
    Serial.println("Current Date & Time: ");
    Serial.print(now.month(), DEC);
    Serial.print('/');
    Serial.print(now.day(), DEC);
    Serial.print('/');
    Serial.print(now.year(), DEC);
    Serial.print(" (");
    
    Serial.print(") ");
    Serial.print(now.hour(), DEC);
    Serial.print(':');
    Serial.print(now.minute(), DEC);
    Serial.print(':');
    Serial.print(now.second(), DEC);
    Serial.println();
    
    
    Serial.println();
    delay(1000);


  if (fsrReading >= 200 && printerLife == 0) {
     printer.feed(2);
     printer.justify('C');
     printer.println();
     printer.setSize('S');
     printer.println(F("-------------------"));
     printer.println();


     printer.setLineHeight(50);
     printer.setLineHeight();


     
     printer.setSize('L');
     printer.inverseOn();
    
     printer.printBitmap(intro_width, intro_height, intro_data);
     printer.setSize('S');
     printer.inverseOff();
     
     output = phrases[random(numberofphrases)];
     printer.println(output);
     printer.println();
     printer.println();
     printer.println(F("-------------------"));
     printer.println();
     printer.println();
     printer.println();


     printer.justify('L');
     printer.print(F("Date: "));
     printer.print(now.month(), DEC);
     printer.print('/');
     printer.print(now.day(), DEC);
     printer.print('/');
     printer.print(now.year(), DEC);
     printer.print("  ");
     delay(100);
     printer.justify('R');
     printer.print(F("Time: "));
     if(now.hour() < 10) {
      printer.print('0');
     }
     printer.print(now.hour(), DEC);
     printer.print(':');
     if(now.minute() < 10) {
      printer.print('0');
     }
     printer.print(now.minute(), DEC);
     printer.print(':');
     if(now.second() < 10) {
      printer.print('0');
     }
     printer.print(now.second(), DEC);
     printer.println();
     printer.println();
     printer.printBitmap(title_width, title_height, title_data);
     printer.println();


     printer.feed(4);
     printerLife++;
  }


  if (fsrReading < 200) {
    printerLife = 0;
  }


  


}

No comments:

Post a Comment