Let there be light!

Description

I used 3 potentiometers to vary the brightness of 3 LEDs individually, wherein each LED can be controlled independently of the others. This setup enabled me to carry out some interesting effects with dimming and rising of the LEDs. The video can be seen here – https://goo.gl/photos/y1YiUhkJ8XSZjCb58

Components

1 Arduino Uno
3 LEDs
3 220Ω Resistors
3 potentiometers
1 Breadboard
Jumper wires
USB cable

int potPin = 0;
int potPin1 = 1;
int potPin2 = 2; // Analog input pin that the potentiometer is attached to
int potValue = 0;
int potValue1 = 0;
int potValue2 = 0; // value read from the pot
int led = 9;
int led1 = 10; // PWM pin that the LED is on. n.b. PWM 0 is on digital pin 9
int led2 = 11;

void setup() {
// initialize serial communications at 9600 bps:
Serial.begin(9600);
// declare the led pin as an output:
pinMode(led, OUTPUT);
pinMode(led1, OUTPUT);
pinMode(led2, OUTPUT);
}

void loop() {
potValue = analogRead(potPin);
potValue1 = analogRead(potPin1);
potValue2 = analogRead(potPin2); // read the pot value
analogWrite(led, potValue/4);
analogWrite(led1, potValue1/4);
analogWrite(led2, potValue2/4); // PWM the LED with the pot value (divided by 4 to fit in a byte)
Serial.println("hello"); // print the pot value back to the debugger pane
delay(10); // wait 10 milliseconds before the next loop
}

IMG_20160920_230003      IMG_20160920_230144      IMG_20160920_231022

Lights, Metaphors, Action!

Reading about embodiment and metaphors helped me organize the TUIs I have encountered in my life into neat categories. The Philips Living Colors light at my home makes for a great discussion after reading this paper.

It uses an array of LEDs to generate 16 million different types of colors which it projects at an angle. It comes with a wireless remote control which can be used to change the color of the light. Since it’s operated using a remote, the output device isn’t the same as an input device, the Living Colors light isn’t an example of full embodiment. It’s not an example of nearby embodiment either since the output isn’t taking place in close proximity of the input device. However, it is an example of environmental embodiment since the output takes place around the user. There is a link between the remote and the LED controller, but the output combination of light is viewed exclusive of these.

As for metaphors, the metaphor of noun is really weak in this case since it doesn’t directly draw an analogy between any other light outputting device that the user may have experienced. The transparent material looks fancy and attractive but speaking strictly in metaphorical terms, it’s hard to say if the affordance immediately dovetails with the user’s mental model. The remote control on the other hand, exhibits metaphor of verb. It uses the concept of a touch-sensitive circular shaped dial, which any person who has ever used the iPod classic will immediately associate with. Sliding your finger on any particular color on the dial results in a corresponding color change in the LED controller, which is output immediately for instant feedback to the user. Due to the strong presence of metaphors used as guiding principles in the design process, it is easy and quick to learn how to operate this light. And once you get the hang of it, it’s a deeply satisfying experience to watch the lights change softly in response to your touch.

Living Colors

Living Colors

Night light

Description

I altered the code to dim LEDs so it now takes input in form of ‘rrr’ or ‘gggggg’. I also tried different diffusers like paper and cloth, in addition to the cotton and styrofoam that we worked with in class. Finally, I settled on an LED lamp – which I removed the batteries from – and held it on top of my breadboard LEDs for the purposes of this assignment. This lamp can be kept in a corner and used as a nightlight, the color of which can be changed on your command.

Components

1 Arduino Uno
3 LEDs
3 220Ω Resistors
1 Breadboard
Jumper wires
USB cable


char serInString[100]; // array that will hold the different bytes of the string. 100=100characters;
char colorCode;
int colorVal;

int redPin = 9; // Red LED, connected to digital pin 9
int greenPin = 10; // Green LED, connected to digital pin 10
int bluePin = 11; // Blue LED, connected to digital pin 11

void setup() {
pinMode(redPin, OUTPUT); // sets the pins as output
pinMode(greenPin, OUTPUT);
pinMode(bluePin, OUTPUT);
Serial.begin(9600);
analogWrite(redPin, 127); // set them all to mid brightness
analogWrite(greenPin, 127); // set them all to mid brightness
analogWrite(bluePin, 127); // set them all to mid brightness
Serial.println("enter color command (e.g. 'rrrr') :");
}

void loop () {
// clear the string
memset(serInString, 0, 100);
//read the serial port and create a string out of what you read
readSerialString(serInString);

colorCode = serInString[0];
colorVal = 0;
if( colorCode == 'r' || colorCode == 'g' || colorCode == 'b' ) {
for (int i=0; i < strlen(serInString); i++) {
if( colorCode == 'r' || colorCode == 'g' || colorCode == 'b' )
{
colorVal += 1;
}
}

colorVal = (colorVal/200.0)*255;
Serial.print("setting color ");
Serial.print(colorCode);
Serial.print(" to intensity: ");
Serial.print(colorVal);
Serial.println();
serInString[0] = 0; // indicates we've used this string
if(colorCode == 'r')
analogWrite(redPin, colorVal);
else if(colorCode == 'g')
analogWrite(greenPin, colorVal);
else if(colorCode == 'b')
analogWrite(bluePin, colorVal);
}

delay(100); // wait a bit, for serial data
}

//read a string from the serial and store it in an array
//you must supply the array variable
void readSerialString (char *strArray) {
int i = 0;
if(!Serial.available()) {
return;
}
while (Serial.available()) {
strArray[i] = Serial.read();
i++;
}
}

IMG_20160912_025841

IMG_20160912_025517

IMG_20160912_025502

The handoff

The first thing that came to my mind when I read McCullough’s assertion that the computer is inherently a tool for the mind and not for the hands was a comment made by Steve Jobs during the early years of Apple – he said that the computer is the equivalent of a bicycle for our minds. While both statements reiterate that using computers help us accomplish tasks more efficiently, even these personalities, with a constant finger on technology’s pulse, couldn’t have predicted the rate at which the boundaries between tactility and cognition would begin to blur. Our hands continue to move in accord with the mind, but there’s

The idea of our mental and tangible facilities converging has existed in theory for a while, but only recently have we begun to experience it with virtual reality apps like TiltBrush. It is easy to get excited about such technology because it clearly represents a radical leap forward. However, I feel that studying what’s on the horizon is always helps put the current landscape in perspective. For instance, 3D TVs were all they rage when they came out, but it wasn’t until Oculus Rift that the user really began feeling the sense of ‘presence’ that content developers were aspiring for. Drawing an analogy, I would like to put VR in perspective by bringing in Project Soli.

Project Soli by Google utilizes an advanced radar sensor which is capable of sensing complex gestures and adept at translating them into computer input. For instance, twisting a virtual knob in mid-air can actually increase or decrease the volume of a pair of Soli-enabled speakers. Similarly, rubbing the index finger against the thumb can trigger the grab and scroll interaction on a Soli-connected screen.

Sensors like these open up an unprecedented world of interactions and allow for richer, more authentic user experiences. A technology like Soli can actually untether us from bulky VR headsets and enrich our surroundings with more natural interactions. Going back to McCullough’s assertion, I reckon that the computer is slowly becoming an appendage for the hand. Going ahead, we may not have to consciously retrieve steps from memory to accomplish day-to-day tasks. With a seemingly natural gesture of our hands, the computer shall do our bidding.

Fading LED

Description

After having the LED blink in accordance with the preloaded program, I proceeded to write my own. I wanted the LED to glow at its maximum brightness, slowly fade to zero and then rise again. I used a for() loop for accomplishing this. Also, I used analogWrite instead of digitalWrite so I can have varying levels of brightness instead of a binary HIGH or LOW.

Components

  • 1 Arduino Uno
  • 1 Breadboard
  • 1 LED
  • Jumper wires
  • 1 USB cable
  • 1 220 ohm resistor

Code

int green = 11;

void setup() {
pinMode(green, OUTPUT); // initialize analog pin 11 as an output.
}

void loop() {
int x = 1;
for (int i = 0; i > -1; i = i + x)
{
analogWrite(green, i);
if (i == 255) // if the LED reaches maximum brightness,
x = -1; // start dimming it by 1 point every second
delay(100);
}
}

 

Invitation by exhibition

Each day of our lives, we are lured by a touchscreen to glance at it, interact with it or even search for an excuse just to swipe at it. For most of us, this behavior has become second nature – and a lot of credit goes to effective design. As a child, I distinctly remember being fascinated by the claw arcade game at my neighborhood gaming parlor. After reading about activity theory, I think I understand why I felt drawn towards the game: observing the tool (claw) and it’s interface (joystick) in action meant that I understood the game instantly. Behind a transparent wall of glass, the claw promised to serve as an extension of my hands in grabbing a plush toy. But the magic lay in the joystick: it made the claw so easy and fun to operate that it had me reaching into my parents’ pockets throughout the evening.

As Kaptelinin and Nardi explain, internalization is cardinal in interacting with a new environment. Consequently, a system like a touchscreen or a claw machine which make their role in the interaction abundantly clear to the user, benefit from an easy learning curve. Once observed in action, these interfaces make it easy for the user to accomplish his/her goal without taxing the working memory, so much so that after a few transactions, using them feels intuitive. I would also like to talk about the cursor. Even though we see it blinking whenever we type, we scarcely pay any attention to it  – a close analog of the unassuming nature of the screen and the joystick. And yet, if it wasn’t for the cursor’s blink, we wouldn’t know where to start typing. The cursor, the screen and the joystick are my favorite examples of UI which by virtue of either form or function, invite the user without requiring explicit instructions. When Dourish talks about phenomenology in the opening chapter of his book, I feel that these UIs have a common thread connecting their individual perception and action, which in turn leads to better user experiences in the real world.