My “Letty’s Home” Project

I bought a Raspberry Pi (a miniature computer) a couple of years ago and was very excited to receive it. Once it came, I realized I had no idea what I was going to do with it, so it collected dust for a few months.

Letty was home last summer, and on nights when she was out with friends, Marcy had trouble falling asleep until she was home. The compromise they worked out was that Letty would text Marcy when she got home, so if Marcy fell asleep and woke up in the middle of the night, she could look at her phone and fall back asleep knowing that Letty was home safely.

A good system in theory, except about half of the time Letty would forget to send the text.

She would, however, remember to turn off the light in the front room. This gave me the idea for my RaspBerry Pi project. I ordered a light sensor, a breadboard and jumper wires, and built a DIY “Letty’s Home” sensor. The software part was my first ever experience coding in Python. Before we go to bed, we “arm” it by plugging it in. Every ten seconds, it wakes up, measures the light in the room, and if the lights are still on, it goes to sleep for another ten seconds.

When it detects that the lights were off, it sends Marcy and I a text that the lights were turned off.

And it works — most of the time. For reasons still unknown, it doesn’t always boot up properly and get to the armed state. To help diagnose the problem, I ordered an LED to use for feedback that it was armed. It arrived and collected dust for months, until yesterday, when I had a completely free Sunday.

I soldered the LED it to the board and figured out how to write text to it, and now I’ll be able to tell when it doesn’t start up correctly. It speaks! We used it last night:

I’m sure that there are better solutions, but it’s been fun to work on.

Leave a Comment