Recitation 4: Drawing Machine by Liyang Zhu (Tom)

Step 1: Build Circuit

H-bridge circuit diagram

Image from https://wp.nyu.edu/shanghai-ima-interaction-lab/category/recitations/

I followed the diagram to build the circuit. And I loaded codes stepper_oneRevolution from Arduino>File>Examples>Stepper>stepper_oneRevolution. By running this code, the stepper motor would turn revolution continuously.

Step 2: Control rotation with a potentiometer

In this step, I added one potentiometer to the circuit and loaded code MotorKnob from Arduino>File>Examples>Stepper>MotorKnob. By rotating the knob of the potentiometer, the rotation of the stepper motor would change.

Step 3: Building a Drawing Machine

By doing step 2 twice, I got two controllable stepper motors. I fixed them on a laser-printed panel and installed a mechanical arm on them. Then a drawing machine was done!

 

Questions

answer 1

I want to build a device that can help me fold the clothes. Everyone here needs to do laundry at least once per week. However, folding the clothes after the laundry seems to be troublesome to me. So, I want to build a device to help me solve this issue.

The device should be able to fold the clothes. Thus, it has several mechanical arms driven by servo motors, which can be accurately controlled to move at any given speed and stop at any given position. Also, there should be a camera installed so the machine would be able to detect the type of clothes it is going to fold.

answer 2

In Ken Rinaldo and Matt Howard’s “Autotelematic Spider Bots”, the robots would form a community where each individual mimics the behavior of real ants and spiders. They aren’t controlled by humans, instead, they are able to sense others through ultrasonic camera eyes and infrared cameras and communicate with others. In the recitation, our drawing machines are controlled by potentiometers which directly receives information from humans. In contrast, the spider robots here don’t require any control. They are mostly self-controlled and interfered by other members of the community. I guess the artists chose servos here as the actuators. This is because servo motors are accurate, and with them, we can determine the exact posture of the robot.

Group Project Reflection: Gone with Tea by Liyang Zhu (Tom)

Last we had a group project. For this project, we need to make a device that reflects how we interpret “interaction”.

Understanding of Interaction

My understanding of “interaction” is quite simple. In my view, interaction is the loop of information receive and response between two actors. The article The Art of Interaction Design inspired me a lot. According to it, interaction is “a cyclic process in which two actors alternately listen, think, and speak”. I agree that interaction must happen between two actors (usually human and machine). However, I think that the input of interaction can be something rather than listening, such as seeing, smelling, or even reading brain waves. Moreover, the output can also be something else than speak. Most importantly, interaction is cyclic, which means that the input and the output are in a loop cycle rather than one line. I think in the real interaction, the output will somehow affect the input we give next time. That’s what cyclic means.

Project one

I think this project fail to fit my interpretation of interaction. This project really has lots of aesthetic value, it doesn’t have the key factor of interaction. It involves two actors–human and the table itself. It receives whether the cup is placed as input, and it changes the color of some blocks on the table as an output. However, such a progress of input->process->output is not cyclic. In other words, the color of the block won’t affect the way we place the cup in the future. So there is no closed loop of input and output. It’s reacting to input, but not really interactive.

project two

I think this project better fits my view of interaction. Though the device’s principle is not very complex. It just detects the user’s motion and changes the position of the person in the game. However, it involves two actors and has both input (motion) and output (screen). More importantly, the position of the man on the screen really affects the player’s decision. So the output will continue to affect the input in some way. Consequently, there is cyclic progress here. I think this project is a good example of interaction.

our group work

As for our group project, we mainly designed a helmet which can read the user’s brain wave and respond to him/her through brain wave. We had this idea because we wanted to emphasize that the input and output of interaction are not necessarily those traditional ways. It can also be brain wave reading and writing. In the performance, we tried to illustrate some communication between the AI in the helmet and the user’s brain. We think it still forms interaction. 

Another point we wanted to emphasize was that interaction is always cyclic. The user and the helmet can communicate back and forth. The input determines the output, while the output changes the way the user inputs next time. It’s like operating a computer. The user must look at the screen to decide where to click next time. That’s how output affects input. And that’s what we wanted to show.

Recitation 3: Sensors by Liyang Zhu (Tom)

In this week’s recitation, we tested some sensors.

Moisture Sensor

First, I followed this form and connected sensor to Arduino.

Arduino Port Sensor Port
5V Red
GND Black
White
A0 Yellow

Then I found a sample code on http://wiki.seeedstudio.com/Grove-Moisture_Sensor/.

int sensorPin = A0;
int sensorValue = 0;

void setup() {
    Serial.begin(9600);
}
void loop() {
    // read the value from the sensor:
    sensorValue = analogRead(sensorPin);
    Serial.print("Moisture = " );
    Serial.println(sensorValue);
    delay(1000);
}

Upload. Done! Here are the photo and video.

Infrared Distance Sensor

First I followed the circuit diagram.

Picture of The Circuit

Image from https://www.instructables.com/id/How-to-Use-the-Sharp-IR-Sensor-GP2Y0A41SK0F-Arduin/

Then, I uploaded the code.

#define sensor A0 // Sharp IR GP2Y0A41SK0F (4-30cm, analog)

void setup() {
Serial.begin(9600); // start the serial port
}

void loop() {

// 5v
float volts = analogRead(sensor)*0.0048828125; // value from sensor * (5/1024)
int distance = 13*pow(volts, -1); // worked out from datasheet graph
delay(1000); // slow down serial port

if (distance <= 30){
Serial.println(distance); // print the distance
}
}

Here is what I’ve done.

Vibration Sensor

I first connect everything.

Image from https://www.arduino.cc/en/Tutorial/Knock

Then I loaded the code from Arduino IDE’s sample library.

Here is my work.

Ultrasonic Ranger

I connected the sensor to Arduino like this.

Arduino Port Sensor Port
4 Echo
5 Trig
5V VCC
GND GND

Then I used the code provided online.

int inputPin=4;
int outputPin=5;
int ledpin=13;
void setup()
{
Serial.begin(9600);
pinMode(ledpin,OUTPUT);
pinMode(inputPin, INPUT);
pinMode(outputPin, OUTPUT);
}
void loop()

{
digitalWrite(outputPin, LOW);
delayMicroseconds(2);
digitalWrite(outputPin, HIGH);
delayMicroseconds(10);
digitalWrite(outputPin, LOW);
int distance = pulseIn(inputPin, HIGH);
distance= distance/58;
Serial.println(distance); 
delay(50); 
if (distance >=50)
{
digitalWrite(ledpin,HIGH);
}
else
digitalWrite(ledpin,LOW);
}

My result:

Joystick Module

When dealing with this sensor, I had a problem with the internal button.

First, connect the module.

Image from https://www.brainy-bits.com/arduino-joystick-tutorial/

Since basically, this module is two potentiometers and one button, I tried to write the code on my own. Here is my initial code.

int X=A0;
int Y=A1;
int BUTTON=3;
void setup(void)
{
  Serial.begin(9600);
  pinMode(BUTTON,INPUT);
}

void loop(void)
{
  Serial.print("X=");
  Serial.print(analogRead(X));
  Serial.print(",");

  Serial.print("Y=");
  Serial.print(analogRead(Y));
  Serial.print(",");

  Serial.print("BUTTON state = ");
  Serial.println(digitalRead(BUTTON));

  delay(100);
}

However, as uploaded and ran the code, I found that though the X- and Y-axis worked well, the state of button stayed 0.

Later as I checked online code, I found that it was because I forgot to use the internal pull-up resistor.

To make the button working, I should either use INPUT_PULLUP as the parameter or explicitly use digitalWrite(BUTTON,HIGH); to enable internal pull-up resistor after assigning the pin as an input;

or, I build the external circuit.

Questions

Question 1

One of the sensors I intended to assemble was the ultrasonic distance sensor. For the pragmatic purpose, this sensor can be used on automatic robots. Such sensors can help robots to avoid collisions. When a robot is moving forward, the distance sensor helps it to make sure there is no obstacle ahead. If the sensors report a short distance, that means something is in front of the robot, and the robot can stop moving before severe collisions.

Question 2

From my perspective, I think the code is a bridge between human and machine. The code is what computers/microcontrollers follow strictly and what human writes to convey their purpose.  It can be both understood by human and machine. When a human wants computers to do something for them, he/she has to use code to let the computer do exactly what he/she wants.

Question 3

I think human will become lazier due to computers. Nowadays computers can help us to do lots of things. And in the future, computers will only be more powerful. More and more tasks of human will be done by computers. So computers will influence human to behave lazier.

Recitation 2: Arduino Basics by Liyang Zhu (Tom)

Circuit 1: Fade

Code: https://www.arduino.cc/en/Tutorial/Fade

Circuit 2: toneMelody

Code: https://www.arduino.cc/en/Tutorial/toneMelody

Circuit 3: Speed Game

The code and design for this circuit can be found here: https://www.tinkercad.com/things/6MzvN5rlZlr-race-the-led-spring19

Circuit 4: Four-player Speed Game

In this case, we copied most part of the circuit in the 2-player speed game.

The project on tinkercad: :https://www.tinkercad.com/things/fYISm1rWIUo-speed-game-4p/editel?sharecode=FNybhlM0WVxUFk2Kq_Lx_GX2MI_ng5ty5hPAk13_ZqI=

Problems we met when building Circuit 4

When building the circuit 4, we made our breadboard too messy. The LED is reversed, so it can’t be lit. Also, when I rewrote the code, I didn’t notice the conditions in the second if statement. So the behavior of LED is a bit strange in our final result. With the help of the professor, we finally found where the problem lies.

Questions

  1. Interaction takes place everywhere in our daily life. For example, it happens when I type on my computer, and the corresponding character appears on the screen; it also happens when I swipe my NYU card on the gate, and the gate opens in response.
    In my own opinion, interaction is very similar to algorithms. Algorithms usually include input, process, and an output; and interaction is the process of “receive information, process information by physical computing, and give feedback.” By building a circuit, I create a simple interaction. I was able to design internal logic (how is information processed), as well as the behavior of the circuit (how the circuit perceives the environment and gives feedback).
  2. If I have 100,100 LEDs, I will use them to build a grid of LED. This grid can be seen as a huge screen (though low in resolution). With certain programs, the grid can display interesting pattern and animation. It would be a perfect light show!

Recitation 1: Electronics & Soldering by Liyang Zhu (Tom)

Materials

  • 1 * Breadboard
  • 1 * LM7805 Voltage Regulator
  • 1 * Buzzer
  • 1 * Push-Button Switch
  • 1 * Arcade Button
  • 1 * 220-ohm Resistor
  • 1 * LED
  • 1 * 100 nF (0.1uF) Capacitor
  • 1 * 10K ohm Variable Resistor (Potentiometer)
  • 1 * 12-volt power supply
  • 1 * Barrel Jack
  • 1 * Multimeter
  • Several Jumper Cables (Hook-up Wires)

Circuit 1: Door Bell

Here is the circuit diagram:

doorbell

Image from https://wp.nyu.edu/shanghai-ima-interaction-lab/recitation-1-electronics-soldering/

In this circuit, the LM7805 is a voltage regulator integrated circuit which converts the input 12V DC to 5V DC. The 100nF Capacitor connected in parallel with pin1 and pin2 of LM7805 can prevent the regulator from self-exciting. The buzzer we used in class is an active buzzer, which is integrated with an oscillating circuit. So it only needs a stable DC power to drive it. When the button is pressed, the speaker will work.

Here is our work:

Circuit 2: Lamp

Here is the circuit diagram:

lamp

Image from https://wp.nyu.edu/shanghai-ima-interaction-lab/recitation-1-electronics-soldering/

The most part of this circuit is similar to the first one. The only change is that we replaced the buzzer with LED. Moreover, a 220-ohm resistor is connected to LED in series to protect LED by limiting the current.

Here is our work:

Circuit 3: Dimmable Lamp

Here is the circuit diagram:

dimmable light

Image from https://wp.nyu.edu/shanghai-ima-interaction-lab/recitation-1-electronics-soldering/

I think this circuit is yet another improved version of the second circuit. By adding a 10K-ohm potentiometer, we can change the resistance of the potentiometer by turning the knob. Correspondingly, the current passes through the LED changes, and the brightness of the LED also changed.

Here is our work:

Thoughts and Knowledge

In the course of the operation, I was fortunate enough not to have any problems. However, I also have some ideas:

Be careful when using the breadboard

The holes on the breadboard are very dense. If you don’t look at it carefully, it is easy to connect jump wires incorrectly, which will cause the circuit to not work properly. So it is important to look at the breadboard from above when connecting the wires.

Measure resistor size by looking at their color rings

The size of a resistor can be measured by the multimeter, which is very helpful. However, the best way to get the accurate resistor size is to look at the color rings. Usually, the last ring indicates precision; each of the other color rings represents a single digit. It can be a bit difficult to find the correct direction, my technique is to observe the distance between rings. The color ring representing precision usually has a larger distance from other color rings. Here is a table for reference:

“电阻色环表”的图片搜索结果

Image from hahatv5.com

The capacitor is important

Initially, I didn’t know why we need to use a capacitor at the input of the regulator. After checking on the Internet, I know that this capacitor is used to filter the high-frequency signal at the input (capacitor can hinder the high-frequency signal), thus avoiding high-frequency self-excitation of the LM7805. Also, there are cases where another capacitor is used at the output (this time it is stabilizing the output signal).

The buzzer is an active buzzer

Buzzers are usually divided into two types–one is active buzzers, another is passive buzzers. Passive buzzer makes sounds through the vibration of the ceramic piece. To drive a passive buzzer, we need a square wave like this, which periodically drives the ceramic pieces:

“方波”的图片搜索结果

Image from phy.ntnu.edu.tw

However, the buzzer we used in class is active buzzers. These buzzers are integrated with oscillating circuit, which generates square wave. So we can directly drive them with DC power.

Questions and Answers

Question 1

After reading The Art of Interactive Design, in what way do you think that the circuits you built today include interactivity? Please explain your answer.

Answer 1

I think the circuits we built include interactivity. Though according to the reading The Art of Interactive Design, interaction should involve listening, thinking and speaking. In the reading, interaction is defined as “a cyclic process in which two actors alternately listen, think, and speak”. Though the logic of the circuits is very simple–just light up the LED when the button is pressed, they still include the key factor of interaction–input, process, and output. Obviously, they cannot speak nor listen, but they can buzz and receive a click. In this sense, we can say that they include interactivity.

Question 2

How can Interaction Design and Physical Computing be used to create Interactive Art? You can reference Zack Lieberman’s video or any other artist that you know.

Answer 2

In the video, interaction design and physical computing are combined to build a helpful system, which helps the artists living in the hospital continue creating. I think interactive art can be achieved only when interaction design and physical computing are combined. Without physical computing, interaction design cannot be turned into reality. In the video, the eye-tracking technology provides the possibility to the whole project. Also, interaction design is necessary. Without the design, physical computing is nothing else but dry technology.  In a nutshell, only when interaction design and physical computing are combined, interactive art can be created.