Fresh Eyes – Smart Contact Lens Case

Made by Shawn Koid

Found in DioT 2019: Augmented Objects

Fresh Eyes is a smart contact lens case that non-intrusively tells users that their contact lens has been cleaned and when to replace a set of contact lens with a new pair. Most useful for users who wear monthly contacts–where they need to clean their contact lens daily and replace them every month.

0

Intention/Problem Statement

The inspiration behind Fresh Eyes came from a need that arose during a fieldwork interview with my sister, Cass. Cass is a doctor in NYC and often has 24 hr shifts at the hospital. Cass wears contact lens to make sure she can move from patient-to-patient with ease. (Her contact lens last almost a month and must be thrown out every 26 days). Additionally, Cass has to “clean” her contacts by letting them soak in solution for at least 6 hours daily. Due to her ever-changing schedule, Cass often finds it hard to keep track of when she needs to replace her contacts with a new pair and when her contacts are properly cleaned. 

We only get one set of eyes; and unfortunately, we don't realize that we are not taking care of our eyes until the damage has been done. Not only did I feel connected to helping my sister, I also felt that the contact lens case (something plenty of people use) has not been updated or redesigned for better use. 

0

Goal

Fresh Eyes is a simple "hack" to the regular contact lens case. Using a Hall Effect Sensor, which is attached to the base of the case, and a magnet, which is attached to one of the lids, Fresh Eyes can tell users when their contact lens has been cleaned (minimum of 6 hours, daily) and when it's time to replace the current pair of contact lens (every 26 days). Users will be alerted that their contacts are cleaned with a blue light signal and that their contacts must be thrown out and replaced with a yellow signal.

0

Process

1. Interview user and identify need

- Interviewed my sister, Cass, and identified that her contact lens case could be a good candidate for an IoT hack

2. Identify necessary components for project 

- I decided to use a Hall Effect Sensor to sense/monitor when the contact lens case has been opened and closed. To test this out, I needed: Hall Effect Sensor (1), magnet (1), LED (1), resistors (10K & 1K), jumper wires, as well as my Argon. 

3. First attempt 

- My first goal was to set up the circuit and successfully use the hall effect sensor and light up an LED to show that the magnet was detected by the sensor

- I learned that the Hall Effect Sensor needs 3.5V (while the Argon provides 3.3V), so we reconnected the power to USB. 

- After setting up the circuit, I found some starter code for the Hall Effect Sensor, which turned out to be not that useful; it had to be slightly edited for my sensor to successfully work (thank you TAs!) 

- Also had to program the blue LED to turn on after 6 hours (Please note that for demo purposes, the code was altered to 6 seconds, where 6 seconds represents 6 hours = contacts are cleaned)

4. Adding More Functionality

- Following this, I added an additional LED (yellow) to alert users when 26 days has passed and that this pair of contact lens needs to be thrown out and replaced (Please note that for demo purposed, the code was altered to 26 seconds, where 26 seconds represent 26 days = contacts need to be replaced)

- I also added a button to turn off the blue LED (after 6 hours, when the user puts on their clean contacts)

5. Adding the sensor to the object

- The Hall Effect Sensor needs to meet the north side of the magnet perpendicularly, so I had to experiment with the placement and securement of the sensor and the magnet. 

- I soldered the sensor to 3 jumper wires and covered them with electrical tape

- After testing that the sensor still worked, I attached the sensor to the contact case and attached the magnet on the right lid. 

0

Outcome

At this stage, you can see the functionality of the device and how it could enhance the original object. 

With the magnet attached to the lid of the case, when the lids are closed, the magnet meets the Hall Effect Sensor, setting off the timer for 6 seconds (rep. 6hrs). Users can use the blue button to turn off the blue LED will light (and essentially remove their cleaned contact lens). Within 26 seconds (rep. 26 days), the yellow LED will light up. A video of how Fresh Eyes works is below. 

Additionally, the video after that is the serial monitor view of the device working through its steps. 

1. "CLEANING STARTED" = Lid has been closed/magnet has met the sensor

2. "YOUR CONTACTS ARE CLEANED!" = 6 seconds (rep. 6 hours) has passed, blue LED turns on, and contacts have been cleaned

3. "TIME FOR A NEW PAIR OF CONTACTS" = 26 seconds (rep. 26 days) has passed, yellow LED turns on, and contacts should be thrown out/replaced by a new pair

0
Fresh Eyes – Smart Contact Lens Case
Shawn Koid - https://www.youtube.com/watch?v=LO4_hdFOaww&feature=youtu.be
0
Fresh Eyes - Smart Contact Case (Serial Monitor)
Shawn Koid - https://youtu.be/rDGIxk0ir-Y
0
Circuit Diagram for Fresh Eyes
Screen shot 2019 01 31 at 3.19.07 pm
0
volatile byte half_revolutions;
 unsigned int rpm;
 unsigned long timeold;
 
 
 int led = D2; 
 int led2 = D7;
 int sen1 = D4;
 int bluebutton = D6;
 int duration = 6000; // Contact Lens needs to be cleaned for min of 6 hours; for the sake of display, 6 secs = 6 hrs
 int tstarted =-1;
 volatile int state = 0;
 bool detected = FALSE;
 int lastState = 0;
 
 int TS_DAY_MILLIS (1000 * 26); 
 // Actual code below; Contact lens need to be changed after 26 days; for the sake of display, 1 sec = 1 day 
    //  #define TS_DAY_MILLIS (24 * 60 * 60 * 1000 * 26) 
unsigned long lastSync = millis();

void setup() 
{
   Serial.begin(9600);
    pinMode(led, OUTPUT);
    pinMode(led2,OUTPUT);
    pinMode(sen1, INPUT_PULLUP);
    attachInterrupt(sen1, magnet_detect, CHANGE);
    
//   attachInterrupt(D4, magnet_detect, CHANGE);//Initialize the intterrupt pin 
   half_revolutions = 0;
   rpm = 0;
   timeold = 0;
   Particle.variable("x",detected);
   digitalWrite (led2, LOW);
   
   pinMode( bluebutton , INPUT_PULLUP); // sets blue button pin as input
 }
 
void loop() 
{
    delay(100);
    // if( lastState != state){
    //       Serial.println("detect change");
    //       Serial.println(tstarted);
    //         //detected = state;
    // }
    if(detected==true&&tstarted==-1)
{
    tstarted=millis();
    Serial.println("CLEANING STARTED");
    Serial.println(tstarted);
}    
    if((tstarted !=-1) && (tstarted+duration < millis()) && state ==0) {
        
        Serial.println("YOUR CONTACTS ARE CLEANED!");
        Serial.println(tstarted);

        lastState = state;
        
      //  detected = int(state);
        digitalWrite(led, HIGH); 
        state = 1;
    //   if (half_revolutions >= 20) { 
    //      rpm = 30*1000/(millis() - timeold)*half_revolution;s
    //      timeold = millis();
    //      half_revolutions = 0;
    //      //Serial.println(rpm,DEC);
         
         
    //   }
        delay( 500 );
    }
    
    if (millis() - tstarted > TS_DAY_MILLIS) { 
        // Request time synchronization from the Particle Device Cloud
        Particle.syncTime();
        // lastSync = millis();
        Serial.println("TIME FOR A NEW PAIR OF CONTACTS");
        digitalWrite(led2, HIGH);
        
        delay( 500 );
    }
    

    int bbuttonState = digitalRead( bluebutton );
    
     if( bbuttonState == LOW && state == 1)
    {
         // tun the LED Off
         digitalWrite (led, LOW);
    }

}
 
 void magnet_detect()//This function is called whenever a magnet/interrupt is detected 
 {
    
    detected = TRUE;
//    state = !state;
//   half_revolutions++;
//   Serial.println("detected");
//   Serial.println(state);
 }
Click to Expand
0

Next Steps

If I were to continue working on this project, I would have to rethink how to protect the sensor against liquid (in the event of human error, where the user spills some contact lens solution on the sensor). Additionally, I would fasten the sensor more securely and explore ways to incorporate the magnet in a more aesthetically pleasing fashion. 

0

Reflection

I'm happy with where I ended up with this project and I feel that concept could help improve contact users' lives. My biggest challenges were finding the appropriate code and programming it to fit what I was trying to accomplish with this project/meet the desired functionalities. 


x
Share this Project

Courses

49713 Designing for the Internet of Things

· 18 members

A hands-on introductory course exploring the Internet of Things and connected product experiences.


Focused on
Skills
Tools
About

Fresh Eyes is a smart contact lens case that non-intrusively tells users that their contact lens has been cleaned and when to replace a set of contact lens with a new pair. Most useful for users who wear monthly contacts–where they need to clean their contact lens daily and replace them every month.

Created

January 31st, 2019