I share my home office with my kids, an unfortunate necessity in a house with five bedrooms, five children, and no dedicated office space (the “office” is actually one of the bedrooms). All the kids are fully aware of the “never, ever touch anything on Daddy’s desk” rule, but apparently the stuff on my desk is just too tempting. Who would have imagined that a roll of tape could be such a powerful influence for evil? Needless to say, when something is missing, the kids often blame the disappearance on the mythical “not me.”
This morning, my oldest daughter, who at 11½ surely should know better, saw something interesting on my computer screen, which was visible because I was accessing it remotely from work (with Linux, when you connect to your desktop remotely, it is visible on the local monitor). I watched with amazement from work as she moved my mouse around and opened several of my documents.
When I realized what was going on, I locked the screen. To my even greater amazement, rather than this causing my daughter to come to her senses and realize that she wasn’t supposed to be touching my computer, she clicked the “Switch user…” button, thus breaking my remote connection and locking me out until I got home from work. (I’ve since fixed my configuration so that I can’t be locked out like that again, but that’s not the main point of this story.)
This was the last straw. No longer will I tolerate items mysteriously disappearing from my desk with none of the kids taking responsibility. Thanks to the wonderful open-source software package Motion, the Webcam atop my monitor will now capture and save images of anyone who touches anything on my desk. Busted!
What makes this interesting enough to be worth blogging about (in my opinion; yours, obviously, may differ!) is how I solved the problem of not filling up my disk with images of me using the computer. I wrote this script, which is designed to be run as a GNOME startup application. Whenever my screen is locked, it turns on the camera, and when the screen is unlocked and the camera is turned on, it prompts every 15 minutes to ask whether to turn it off (it prompts rather than always turning it off because I may be accessing the computer remotely and want the camera to remain on).
There are detailed comments at the top of the script explaining how it works and how to use it. I’m posting it here on the off chance that it might prove useful to someone else. Enjoy!