Workshop_03 ↓ Physical Computing

During the Physical Computing Workshop part 3/5, we had to try out modules in small groups. I tested the Sparkfun Easy Driver + Stepper Motor and the MPR121 Capacitive Touch Sensor, both pretty enjoyable to play with — well, that’s it if you don’t mix-up the wires and smell the burn…

For the homework, I had to use something I didn’t get to try previously so I chose the Servo Motor. Setting it up was pretty easy following this tutorial, and the Servo Motor swept back and forth without any trouble.

I added a Potentiometer to control this Servo Motor, and it still works out pretty well. On top of that, I added a LED that is also controlled by the Potentiometer to make it fade. However, I feel that the input of the two components are having a face-to-face and somehow cancel the fade effect…? The Potentiometer still lights up the LED at the end of its turn though.

Before I reach out to a solution, here the code ↓↓↓


Servo myservo;
const int potpin = 0;
int angle = 0;

const int ledPin = 10;
int brightness = 0;
int fade = 0;

void setup() {
pinMode(ledPin, OUTPUT);

void loop() {
angle = analogRead(potpin);
angle = map(angle, 0, 1023, 0, 180);

brightness = analogRead(potpin);
fade = map(brightness, 0, 1023, 0, 255);
analogWrite(ledPin, fade);

And the video ↓↓↓

On another note, this module seems pretty similar that of the Stepper Motor, but it is not as precise — the Stepper Motor is defined by steps and you can choose the angle of each step, while the Servo Motor turns around at once. Hence it seems to have less possibilities, but certainly I wasn’t able to make full use of it.

Workshop_02 ↓ Physical Computing

The exercice was to to do an intervention using what we’ve learned during last week’s class, aka the use of the push button and the potentiometer with LEDs.

I got in my possession a RGB LED that I’ve really wanted to try out. Basically, I wanted the push button to light on / off the LED, and the potentiometer to change the RGB value of the LED.

The RGB LED got 4 legs, the 2nd leg which is the longest one is (-) while the others legs are (+). I connected the three (+) legs into the digital input, and the (-) into the ground. For each (+) leg, I used a 330Ω resistor.

Then, I connected the push button and the potentiometer, following what I’ve been taught previously. I used a 10KΩ resistor for the push button.

Here is the code ↓↓↓

int redPin = 1;
int greenPin = 2;
int bluePin = 3;

int buttonPin = 7;
int potPin = A0;

int val = 0;

boolean ledState = LOW;
boolean prevBtnState = LOW;

void setup() {
pinMode(redPin, OUTPUT);
pinMode(greenPin, OUTPUT);
pinMode(bluePin, OUTPUT);

pinMode(buttonPin, INPUT);
pinMode(potPin, INPUT);

void setColor (int red, int green, int blue) {
analogWrite(redPin, 255 - red);
analogWrite(greenPin, 255 - green);
analogWrite(bluePin, 255 - blue);

void loop() {
boolean btnState = digitalRead(buttonPin);
int val = analogRead(potPin);

if (btnState == HIGH && prevBtnState == LOW) {
if (val < 100) {
setColor(255, 0, 0);
if (val >= 100) {
setColor(0, 255, 0);
if (val > 400) {
setColor(0, 0, 255);

digitalWrite(redPin, ledState);
digitalWrite(greenPin, ledState);
digitalWrite(bluePin, ledState);

//prevBtnState = btnState;

I’ve followed last week’s code to write this new one, and I researched tutorials (notably on Adafruit) to implement the RGB LED’s part.

However, it didn’t work out exactly the way I wanted since I can’t seem to work out the part where the switch stays on / off until its next state’s change. I can’t figure it out for now but it still works for the most part. Hopefully, as I get more comfortable with Arduino, I’ll get back to it later and solve it.

Neo-Tribalism_02 ↓ What is Slow?

With a quick search-engine search — to not say Google, it is easy to find informations and even more easy to get lost in that myriad of informations.

I clearly had anxiety when I flipped through the Wikipedia page of the Slow Movement. Just kidding, but hold on! How many sub-movements are there, are these organizations or templates used in enterprises, or…? I highly suspect that this directly clashed with my assumptions brought with the literal meaning I was under of.

Now I’m looking back into my first post which was indeed very spontaneous — and pretty close to a rant, since it is merely a mood I’ve felt at numerous occasions. I was quickly under the assumption that I’ve found a tribe, while I’ve only found a subject to study — which isn’t bad, as this clearly strikes my interest.
In reality, I have yet to find anything close to qualify it as a tribe, or should I say to be accurate — a neotribe in this particular context. I couldn’t possibly apply the concept of neotribalism to the Slow Movement without coming to an understanding of both concept and movement.

What I find interesting in the concept of neotribalism, is that Michel Maffessoli wrote it in a post-modernism stance.

However, I’ve found the TED Talk of Carl Honoré — journalist and writer of the bestseller « In Praise of Slow », that he gave back in 2007. It was the first real highlight I got about the Slow Movement. I highly recommend you to watch his talk. The main points I’ve got are similar to my first post — reaction to the high-speed society. I also appreciate how right this quote gets: « /It isn’t about doing things at a snail’s pace, but doing things at their right speed./ »

Workshop_01 ↓ Physical Computing

We started the workshop series on Physical Computing o/ We have covered some parts of the basics — of basics, and brought back home the first exercice: create a flashing pattern with LEDs.

Why not with music? I can literally listen to the song Lov U by Joji for hours: the loop is perfect and it was easy to figure out its beat. OK I may say this afterwards but I have sadly no sense of rythm, so it still wasn’t that easy to coordinate with the LEDs…

Also, I thought it would be interesting to add several LEDs. I noticed each color behaves differently: the white lights longer than the blue for example. Other than that, I have to admit my choice was purely based on aesthetics: blue LEDs definitely look cool.

Well that’s it, you can watch here ↓↓↓

And here the code ↓↓↓

int led1 = 13;
int led2 = 12;
int led3 = 11;

void setup() {
pinMode(led1, OUTPUT);
pinMode(led2, OUTPUT);
pinMode(led3, OUTPUT);

void loop() {
digitalWrite(led1, HIGH);
digitalWrite(led1, LOW);

digitalWrite(led2, HIGH);
digitalWrite(led2, LOW);

digitalWrite(led3, HIGH);
digitalWrite(led3, LOW);

digitalWrite(led3, HIGH);
digitalWrite(led3, LOW);

digitalWrite(led2, HIGH);
digitalWrite(led2, LOW);

Next thing I should study is maybe how to have the LEDs light up by sound detection?