Recitation 3: Build sensors by Tao Wen

Infrared Distance Sensor

Following the instructions, we did quickly and well.

The sound was very low but detectable. There’s a little buzzing sound. I want to figure out how to copy the melody program here to make it a more decent circuit.

reference:https://wiki.dfrobot.com/SHARP_GP2Y0A41SK0F_IR_ranger_sensor__4-30cm__SKU_SEN0143

Joystick Module

Later, we built another circuit with joystick module. The first problem we ran into was to figure out how to plug the various wires into the right pin, since there’s a difference between the reference chart and the real thing.

We moved step by step. Firstly, we got one LED in the circuit, and programed it to light up as long as the button moves towards the left side. However, we failed at first to read the [X,Y] data, since we used the wrong Baud Rate section (15600 instead of 9600, corresponding with the sample code]. After this, we got it.

Then, we added one more LED, and later a third one. The final version worked like this: three LEDs refer to three directions, left, right and up. It wasn’t a nicely calculated program, so two lights would turn on at the same time when we move the button towards the area in between the two directions.

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

[There’s an error with uploading the videos and photos, I will try that tomorrow and republish it. Please don’t grade me for missing the deadline.]

Question 1:

We intended to build a distance sensor. It can be used in the subway station. When a person gets too close to the edge of the platform, the buzzer would go on. It can effectively warn people around him (if he’s attempting suicide) or the person himself (if he was just careless), and thus protecting him.

Question 2:

Code is read line by line in sequence, just like recipe or tutorial. The result would go differently if you miss one step or one element (ingredient).

Question 3:

Computers itself has become a part of human body language. For instance, on a meeting or lecture, when one is using the laptop, he is distanting himself from the speaker or others psychologically, which can affect the way other people treat him.

Leave a Reply