Skip to content

5. E-textiles

Checklist for the week

test

Personal thoughts and Ideas

I have grown up seeing my dad work with wiring around our house and i would assist him in those home repairs since childhood. I have also have basic knowledge of circuits and creating lighting.

However, i have never personally worked with a Micro-controller before. I am aware of sensors and LEDs, but the coding always seemed like too daunting a task to ever feel inclined to attempt this.

So this week, i am feeling quite daunted at the task of Coding and working with Micro-controllers. My agenda for this week is to keep it simple and start with simple challenges, so as not to look hope and to build morale to be prepared for future electronics based assignment weeks.

Research & Inspiration

Seeing the spectrum of explorations possible in Liza Stark's session blew my mind this week. My favourite part was getting to see all the possible innovative integration of regular materials within electronics. It got me dreaming about all the conductive metal around me that was one step away from creating a circuit.

In the spirit of being focussed to sucessfully finish the assignment, i kept my research limited to past alumni work that had documented their process well enough for me to understand.

I really liked the straightforward approach to the assignment in Alice Sowa's documentation. Stephanie Vilayphiou's catergorical documentation helped me look at simpler quick examples of projects that she had looked at during her assignment week.

Both of their documentation helped me understnd the scope of what was expected to be done this week, and also how to do it. I was also very thankful to their meticulous labelling of the explorations, since i was extremely confused by the terminologies of Analogue vs Digital Sensors and Hard Soft Connectors with respect to the assignments.

Softwares & Tools

SOFTWARE
  1. Arduino IDE
  2. TinkerCAD
TOOLS
  1. ArduinoUNO
  2. Breadboard
  3. Wire connectors for Micro-controller
  4. Alligator Wires
  5. LEDs
  6. LDRs
  7. Flick switch
  8. Resistors (10ohm, 220ohm, 330ohm)
  9. Copper tape
  10. Conductive Thread
  11. Push-Buttons

Work Flow

Wire Circuit with Switch

To begin with, i decided to start off with doing something i know how to do. Started off with mapping out a simple circuit with 1 LED, 1 Switch, 1 220ohm resistor and a 1.5V battery.

test

Here i tried a basic Light On - Light Off mechanism.

test

Here is how smoothly this went

Wire Circuit with LDR

Next up, i wanted to up the challenge a bit. And i found LDR sensors in our Electronic Lab stock, so i decided to test using it. I also wanted to try it with the Micro-controller, so this was the first step.

I made a basic sketch on TinkerCAD first and then converted it into a real circuit. For this iteration i used 1 LED, 1 LDR, 1 Flip Switch, 1 220ohm resistor and a 1.5V battery.

With more elements comes more confusion and loosing track of connecting which ends to ensure flow of current. So the circuit sketches definitely helped. Especially with the 'Simulation' option in TinkerCAD, i was able to play with the LDR and understood how it could be used.

test

I was surpised that the circuit worked pretty well and was super easy. I could change the brightness of the LED based on how much light the LDR was getting.

test

This experiment was fun

Installing Arduino IDE

Now that i had warmed up a bit to most of the elemnts for the assignment, it was time to finally work on the Micro-controller. For this course, i will be using ArduinoUNO. And to start using it i had to install the ArduinoIDE software from their website. It is pretty straightforward.

Once installed, it is time to connect the Micro-controller to the computer and open ArduinoIDE. Then we need to ensure that the Software has detected/ is paired with the correct device.

test

test

test

After the above steps are done, we can begin coding / controlling the Micro-controller!

LDR test with Microcontroller

Since i had fun working with the LDR sensor, i decided to do my first experiment on Arduino using it. To do this, i asked ChatGPT to show me a basic layout and code for this.

I followed this up by creating a circuit sketch on TinkerCAD to ensure that what i understood the inststrutions correctly. TinkerCAD has this amazing option of being able to add Code and view the circuit test simulation. This has been superhelpfull since it helps in avoiding misktakes. For this circuit i used 5 Circuit wires, 1 LDR, 1 220ohm resistor, 1 breadboard and the ArduinoUNO.

test

test

This is the code

const int ldrPin = A0; // Analog pin connected to the LDR
int ldrValue = 0;      // Variable to store the LDR value

void setup() {
  Serial.begin(9600); // Initialize serial communication at 9600 bps
}

void loop() {
  ldrValue = analogRead(ldrPin); // Read the analog value from the LDR
  Serial.println(ldrValue);      // Print the value to the Serial Monitor
  delay(500);                    // Wait for 500 milliseconds
}

I also took this opportunity to understand how the Serial Monitor works.

TIP: Ensure that the 'BAUD rate' set in the Serial Monitor (dropdown at right hand corner of the window) matches the rate specified in the code!

It took me MULTIPLE tries to decipher what the issue was in the reading till ChatGPT helped diagnose this.

These are the range of readings that FINALLY showed on the Serial Monitor

After exploring LDRs and the guidance of ChatGPT, I next wanted to try something Basic from the Arduino Library itself. I also knew i wanted to try using LEDs, so i selected the 'Blink' Sktech from the Arduino library.

test

test

Before starting, i went to the Arduino website and read about the Blink documentation and the circuiut diagrams. To understand it better, i created my own version of the sketch on TinkerCAD and ran a simulation.

test

Once i was happy, i ventured to create the physical circuit. For this I used 1 Breadboard, 1 LED, 1 220ohm resistor and 2 connecting wires. And after an unexpected amount of wiggling the wires in place, it started working.

test

This is the code i used

/*
  Blink

  Turns an LED on for one second, then off for one second, repeatedly.

  Most Arduinos have an on-board LED you can control. On the UNO, MEGA and ZERO
  it is attached to digital pin 13, on MKR1000 on pin 6. LED_BUILTIN is set to
  the correct LED pin independent of which board is used.
  If you want to know what pin the on-board LED is connected to on your Arduino
  model, check the Technical Specs of your board at:
  https://www.arduino.cc/en/Main/Products

  modified 8 May 2014
  by Scott Fitzgerald
  modified 2 Sep 2016
  by Arturo Guadalupi
  modified 8 Sep 2016
  by Colby Newman

  This example code is in the public domain.

  https://www.arduino.cc/en/Tutorial/BuiltInExamples/Blink
*/

// the setup function runs once when you press reset or power the board
void setup() {
  // initialize digital pin LED_BUILTIN as an output.
  pinMode(LED_BUILTIN, OUTPUT);
}

// the loop function runs over and over again forever
void loop() {
  digitalWrite(LED_BUILTIN, HIGH);  // turn the LED on (HIGH is the voltage level)
  delay(1000);                      // wait for a second
  digitalWrite(LED_BUILTIN, LOW);   // turn the LED off by making the voltage LOW
  delay(1000);                      // wait for a second
}

The circuit worked! It blinks!!

Rico had asked to test the limits of the blinking by playing with the delay factor. He wanted us to figure out the number at which the blinking looks like a constantly switched on LED to the naked eye. So i went exploring...

Since the delay value in the code was originally 1000, i decided to take the plunge and enter the value of 100. The visible blinking got faster but not 10 times faster.

test

This is how it looked

Next i tried a delay value of 60 and it started blinking a LOT faster.

test

This is how it looked

At the delay value of 30, it was clear that i am close to the value of getting an almost 'Light on', since i could start seeing lesser of the gaps between the blinks.

test

This is how it looked

When i tried the delay value of 20, i knew i was very close to the perfect value, because the blink was hardly perceivable.

test

This is how it looked

Finally at the value of 15, the visible Blink completely disappered for me. So this is the winning

test

This is how it looked

Hard-Soft Connection with Wire Circuit and Button

I was excited and extremely confused about how to begin this part of the assignment. I knew i wanted to use Conductive thread and some hooks or push buttons

Prepping and Testing

Like i have been doing so far, i refered to the Circuit Diagram of my 'Wire Circuit with Switch' above, and replaced the wires with Conductive thread and the switch with a Push-Snap Button. And i also brought together 1 LED and a 1.5v batttery to complete the circuit.

Based on my previous realisation of electronics being fragile, i tested out the LED and checked if the conductivity and length of the COnductive thread worked at the power provided by the battery.

test

Once everything was working in the rough prototype, we were ready to start making the final version. For this, i decided to use the waste Felt piece from my Open Source Circular Fashion exercise.

It was weirdly shaped but had 4 corners and we began working on the 4 corners to affix and insert all the elements, while keeping the LED in the centre.

So far, i was working with electronics and connections on the same physical plane. But with stiching and the thread cutting across surfaces, it got super confusion of where we were in the circuit, so i decided to sketch out the circuit on the felt piece itself.

test

Initial Attempt

We stiched with the conductive thread and made the final circuit, only to realise on blunder! The Switch didn't work. Essentially in making the circuit using the Push/ Snap buttons, we had created a complete circuit that didn't need the buttons to be joined.

We realised this after completing everything, because the LED was on, even without being 'Switched ON'.

test

Final Circuit

As sad as this was, we knew how to solve this and decided to remake the circuit again completely. We took a fresh piece of waste Felt and began stiching. This time around, the stiches were neater and so were the connections.

test

It finally came together!

Hard-Soft Connection with Blinking LED using Microcontroller

Learning my lession to keep it simple, i decided to use my exploration of 'Blink test with Micro-Controller' and integrate that into the Band i made above.

Following the same Circuit diagram, i re-setup the connections and tested the LED working when connected to extension wires. Luckily this worked!!

Next i added the LED to the Green Felt Band and connected the extension wires to the underside, and Voila it was working!

test

Since i enjoyed working with the various delay values earlier, i decided to test those for how they would add to the aesthtics of the Band. So i changed the original delay of 1000 to 60 and then to 200.

test

test

test

This is how the final prototype turned out

It was actually quite intersting to see BOTH my circuits on the same Felt Swatch as previously i would not have me doing this. Ever. And also the fact that there could be two very different modes of circuits powering the same type of LEDs. This exploration was a really nice closure moment for me, in terms of having successfully applied what i learnt.

Learnings

  1. I realised that i like electronics, but not with breadboards and the connection issues that come up. As much as i understand that electronics are getting more compact and soft, for wider use cases; but these barbie sized fixtures that sudenly stop working or dont connect well, really tested my patience. I would much rather have the Alligator clips, where you are sure the connection is secured!

  2. All the wiring and tiny tiny elements that need to be pushed much harder than expected into the breadboard! Even though these look fragile, they still need brute force. Better to push and break the resistor to ensure the connection is made, rather than go mad figuring out which of the 15 element circuit is not working.

  3. It is always ALWAYS the simplest stupidest thing that is causing the circuit to not work. And more often than not, it is the Connection of objects in tehe circuit. Always double check the connections are tight and in the right position as per the Circuit Diagram.

  4. Circuit Diagrams are the BEST. LIFESAVERS. Always ALWAYS make the circuit diagram first.

  5. It is okay to be ambitious, but in brand new territory, it is better to take baby steps and first try the Simplest looking thing. There is no shame in doing a simple exercise well, and then pushing the boundaries of that, rather than failing at a complex exercise.

  6. Being PATIENT with electronics. Especially if you are working alone, it can lead you to spiral, but take deep breath and walk away from the circuit for a little while before you come back to it.

  7. I missed working with people, especially Shefali. I realised this only when i was working on completing this weeks later, with my dad. Troubleshooting with someone around makes it less stressfull and lonely.


People to thank for this week

My Dad: who diligently was beside me through the process of making the Hard Soft Connections, not only because he was getting to help me in-person after 9 months, but also because he was super fascinatd by the exercise and wanted to do it for himself. All sewing credit goes to him singlehandedly.

This week in emojis: ๐Ÿซฃ๐Ÿซข๐Ÿ˜ถ๐Ÿค”๐Ÿ˜’๐Ÿ˜ฎโ€๐Ÿ’จ๐Ÿ˜ช๐Ÿ˜‘๐Ÿ™„๐Ÿคจ๐Ÿ˜ฌ๐Ÿฅฒ