Back to Parent

Outcome


Outcome

    • The project I created is a simple reading time tracker for someone who wants to gauge how long it is taking them to get through each of their Designing for IoT readings each week with an automated reading light built in
    • You can see it in action below, but you will have to imagine it plugged into a bit more of a substantial light and button combination. If it were to be something I designed/prototyped more thoroughly, I would imagine it as a connected "easy button" and lamp
Show Advanced Options
Show Advanced Options

Process

In designing this little device, my first problem I encountered was the mess of wiring I had after learning to use a photovoltaic sensor. It drove me crazy enough that I rewired the whole thing to a similar layout, but one that made more sense to me. The next was in writing the code to control the output of the timer. My program creates an event on the Particle Dashboard when the button is pressed a second time to inform the user of the total time spent reading for that session/chapter. I kept getting some weird readings and had used the light to trouble shoot what was going on. I noticed the light would only stay lit sometimes and eventually realized I needed a short delay to allow the user to remove their finger, so as to not re-trigger the button press on accident. I made use of some time functions to help track the difference in time between button presses and output readings as strings.

From there my next challenge was finding an appropriate range for the photovoltaic sensor. It is rather finnicky and I used the output of the Brightness variable I created to understand what readings I was getting from the sensor. I used a pen cap to create a darker environment for the sensor, but still came to find that it was sensing a large amount of light anyways. Once I mapped the sensor and brightness values appropriately, I reset the brightness variable to what it should actually be tracking. Nonetheless, I came to find the sensor still on the fritz when I moved the board to a new location to record. Setting it up on the laptop, close to where it was before, allowed me to fix the issue.

Reflection

Overall, I learned how to modify my code to error check and wire my board a little better. In addition, I learned how to use a photovoltaic sensor and buttons. Something I would have done differently is adjust the mapping for the photovoltaic cell. I would have done some more testing to understand the amount of ambient light was in my room in the dark, as opposed to under a pen cap, and created a map based on that. In addition, I may have considered using another button instead of a momentary switch, however I did not feel a switch fit the mold of my concept. If I had a button that would have remained triggered instead, I would have used that.

Drop files here or click to select

You can upload files of up to 20MB using this form.