“Don’t worry son…I will email your mom when you sleep. No need to spend half an hour writing an email when you are tired. I promise she won’t know that this message was sent by a robot.” By Paschal and Alanna’s Robot
Arduino Yun, a web server, conductive fabrics, wires, Arduino software, a piece of fabric and wool
Imagine you have a very busy day. You have been working all day and you are back at home. The only thing you want to do is sleep and call it a day…but wait! You also need to tell your loved ones that you are safe and you are doing ok. This information exchange which may be neglected is actually very necessary in order to establish a good relationship. So then, in order to do that you need to spend more than half an hour writing a text or an email to your loved ones. But what if it happens that you forget to send the message? Failure to do so may endanger your relationship like in a case of my friend who almost broke up with his girlfriend because he rarely texted her at night to say goodnight because he was too busy with other stuff.
In order to avoid all this and secure people’s relationships (including ours of course), Alanna and I came up with an idea, whose prototype is described in this documentation.
Two pieces of fabrics were cut in a flower shape and then sewed together. A layer of conductive fabrics was attached to each side of the fabrics. Their ends were then attached to crocodile wires which acted as a connection between the pillow and the Arduino.
When the pillow is pressed, the circuit is completed by forcing the two conductive fabrics to touch each other.
Wools were staffed inside the fabrics in order to make it feel like a pillow. And here is a picture of the completed project
This was the hardest part of the project because neither I nor Alanna has ever programmed the Arduino to be connected to the internet. But thanks to the internet! We watched several videos and got it working.
We chose the Arduino Yun for the project because it can be connected to the internet without any additional hardware or software. After the Arduino was connected to the computer, the computer was connected to the WIFI which was broadcasted by the Arduino and then used a browser to navigate to arduino.local/. Then, we set a username and password for our Arduino and choose a WIFI network to connect it.
The email sending process involved three things: a trigger (the button in the pillow in this case), a web server and the software.
I created a PHP file which I then uploaded it to a web server. This file was coded in such a way that an email is sent to a certain email address everytime the page was loaded.
In order to send the email by using the Arduino, the Https Client example was used and modified accordingly. The codes were modified such that the Arduino only load the page which sends the email only and only if the state of the pillow button is HIGH.
How to access the Http Client example file. These codes give an Arduino web browsing capability as a normal browser but with less feature like you cannot use the Arduino to watch a YouTube video.
The Arduino codes
The PHP codes. They can be accessed directly at www.summertz.org/sendmail1.php
Wiring of the Arduino
And here is the message to mom!
Configuring the Arduino with the internet took more than 2 hours after more than 10 failed attempts before we consulted an IMA fellow. We learned from him that Arduino cannot access the college network. We then decided to use a tethering hotspot by using a phone.
I am glad that we were able to make our project work. But this is not 100% how we envisioned it. Originally we wanted to send text messages instead of emails. This is because emails are too formal and not very commonly used in normal conversation. This was not easy to implement since it needed a GSM module to be used with the Arduino. However, I would like to explore this implementation in the future.
To conclude, this is the most exciting IMA project I have ever done so far. It forced me to push myself to learn more and more. At the end, I was able to appreciate the beauty of technology.
Disclaimer: It is always a good idea to spend time talking to friends/relatives. The purpose of this program was not to discourage that human-human interaction and introduce a robot-human interaction. Therefore, this must only be used if there are no other alternatives to be connected with your loved ones.