Thursday 2 August 2012

Week 2

Theme: "Making Interactions"

Introduction
Each team was requested to bring in small electronic devices with different technologies, applications and context of use. These devices would later be deconstructed and critically analysed. The aim behind this session was to pull apart the internal components of each device and make an input-output behaviour whilst salvaging useful parts. The electronics which were identified as beneficial and suitable included resistors, electrical wires, speakers, push buttons, slide buttons, LED's, motion detectors and temperature sensors. The process and investigation of the deconstruction projects are well documented with images and data which is relevant to each team member. In addition, the team also decided to collaborate and deconstruct an educational learning tablet for children in order to understand the basics of Arduino, an open-source single-board micro-controller and to conceptualize some ideas for the main project. 

Leap Frog Educational Learning Tablet
The Leap Frog tablet teaches children ages 2 and up, storytelling, phonics skills and the alphabet. Children are able to engage with the tablet through tactile buttons, animations, LCD screen, voice overs, in-built speakers and musical sounds. Children are also able to connect to the internet and personalize certain features such as songs, emails and stories. 


During the deconstruction process and with the aid of various tutors, numerous interesting components were identified as useful parts including a thin touch sensitive membrane which acted as the input and a small speaker and LCD screen which acted as the output. From here the group collected the speaker, various electrical wires and started going through each of the tutorials for programming with Arduino. The team did some initial brainstorming exercises and came up with a device that is used by lifeguards or emergency personal which detects the ambient temperature and relays the data through a speaker.

Arduino Programming
I started the Arduino exercises by finding scrap parts and other broken electrical devices to use their internal components and wiring. The main parts I was looking for included buttons, switches, wires, speakers and sensors. I then began by going through each tutorial to understand the terminologies and the fundamental principles of our products work. Below are images and short videos which show the process and configuration of each tutorial.

Tutorial 1: Digital Outputs




 Tutorial 2: Digital Inputs
 Tutorial 3: Digital I/O




Tutorial 4: Analog Output


 Tutorial 5: Analog Input


I managed to attempt tutorial 6, however, I was unable to successfully get the RC Servo Motor to spin. Therefore, I decided to stop at tutorial 6 and try to figure out the correct configuration for each of the parts. 

Group Work
Due to the fact that our group successfully completed tutorials 1-3, we decided to try and incorporate the speaker into our concept design but we encountered many obstacles and subsequent failures. However, it was later discovered by Alex Garrett via a closer inspection that one of the switches on the circuit board was broken and malfunctioning. More importantly, the team also identified that all of the resistors and associated wiring was in the correct position according to the notes on Blackboard and would have worked if the switch was operational. 

This was the programming code used in the failed attempted in tutorial 4 - analog output.

// Speaker (analog wave-form) output with Switches
// (with a complex use of Pulse-width Modulation)
// prepared by Yasu Santo July 2008
// refer to Language Reference at www.arduino.cc for
// detailed descriptions of commands
// --- part of this script was borrowed from
// http://www.arduino.cc/en/Tutorial/PlayMelody
#define pbPin1 1 // assign 2 to constant "pbPin1"
#define pbPin2 2 // assign 3 to constant "pbPin2"
// PWM can be used with pin 3, 5, 6, 9, 10 and 11.
#define speakerPin 6 // assign 9 to constant "speakerPin"
#define tc 3817 // 1 / (262Hz) = 3817 milliseconds
#define tcs 3610 // 1 / (277Hz) = 3610 milliseconds
#define td 3401 // 1 / (294Hz) = 3401 milliseconds
#define tds 3215 // 1 / (311Hz) = 3215 milliseconds
#define te 3030 // 1 / (330Hz) = 3030 milliseconds
#define tf 2865 // 1 / (349Hz) = 2865 milliseconds
#define tfs 2703 // 1 / (370Hz) = 2703 milliseconds
#define tg 2551 // 1 / (392Hz) = 2551 milliseconds
#define tgs 2410 // 1 / (415Hz) = 2410 milliseconds
#define ta 2273 // 1 / (440Hz) = 2273 milliseconds
#define tas 2146 // 1 / (466Hz) = 2146 milliseconds
#define tb 2024 // 1 / (494Hz) = 2024 milliseconds
#define tcc 1912 // 1 / (523Hz) = 1912 milliseconds
int button1 = 0; // assign "0" to variable "button1"
int button2 = 0; // assign "0" to variable "button2"
void setup(){
Serial.begin(9600); // open serial port with a specified baud rate
pinMode(pbPin1, INPUT); // set the digital pin as INPUT
pinMode(pbPin2, INPUT); // set the digital pin as INPUT
pinMode(speakerPin, OUTPUT); // set the digital pin as OUTPUT
}
void playTone(int tone, long duration){ // Fundtion to play a tone for a set duration
long elapsed_time = 0;
while(elapsed_time < duration){ // while elapsed time of this function is less than the set duration
digitalWrite(speakerPin, 1); // this and next 3 lines generate wave form for a specific tone.
delayMicroseconds(tone/2);
digitalWrite(speakerPin, 0);
delayMicroseconds(tone/2);
elapsed_time += tone; // add the duration of tone just played to the elapsed time.
}
}
void loop(){
button1 = digitalRead(pbPin1);
button2 = digitalRead(pbPin2);
if(button1 == 0 && button2 == 0){ // if both buttons are "0" or ON then
Serial.println("both ON"); // send a message to debug window
playTone(te, 100000);
}else if(button1 == 0){ // if only button 1 is "0" or ON then
Serial.println("(1) ON"); // send a message to debug window
playTone(tc, 100000);
}else if(button2 == 0){ // if only button 2 is "0" or ON then
Serial.println("(2) ON"); // send a message to debug window
playTone(td, 100000);
}
}

The team was able to learn much from this exercise including ensuring all components are accurately inspected to check they are fully operational and how to make use of internal components from other devices. Overall this weeks tutorial was challenging but made me as a designer open my eyes and see the bigger picture and realise that there is more to a product then just it's aesthetics and visual appeal. 

No comments:

Post a Comment