Tag: Fritz!Box

Magic Mirror – Face Recognition and general Update

After being absent from this blog for quite some time, I’d like to give you a quick update on my mirror project. The filesystem of my Raspberry Pi’s SD-card got corrupted some time ago and I haven’t found the motivation to reinstall the system and all my scripts since then, well at least not until two days ago. Because I had to setup the system from scratch again anyway I used the opportunity to use the newest Raspbian version “Jessie” this time and also to match my modified mirror interface code with the original from Michael Teeuw again. Some thoughts about the new Linux version: I really like the way systemd handles process managing and starting, seems a lot simpler to me than it was before but that’s not the topic today.

A few months ago I took the code from the Raspberry Pi Face Recognition Treasure Box and modified it in a way so that it’s no longer just able to recognize one valid face but to differentiate between multiple faces and therefore to know who’s standing in front of the mirror. The python script  is now constantly trying to match people to a known set of trained faces and if one is recognized displays a welcome message and personalized information for that user.

Because the number of my components and running processes keeps increasing, I sketched a quick schematic yesterday to not loose sight of who is talking to whom.
Software:Hardware magischer Spiegel

On the bottom of the software side, we have the mirrorcontroller. It is responsible for all kind of GPIO-stuff, like monitoring the motion sensor and a button. In the future it will also controls the colors of some RGB LED’s I will use for lighting up the person in front of the mirror but that’s still to be implemented. If something moves, a relay turns on the display and a signal is send to the face recognition service, which then starts to take pictures and searches them for faces. If the service recognizes a face the data is send to the SocketIOServer, which further sends it to the web interface to display the welcome message and the information for the user. Other features of the SocketIOServer are:

  • Online Banking, to show the users current bank balance
  • Collecting statistics from my Vimeo-videos
  • Investigating how much space is still left on my server
  • Detecting incoming calls via the Fritz!Box (a German internet router and phone system) call monitor
  • Pulling invoices my clients still need to pay from Invoice Ninja

In a future update I will also add gathering my ToDo’s from Wunderlist but until now that’s it.

The Magic Mirror – Raspberry Pi

I recently started a new projected, which of course is a great reason to write an article about it!

I had a DVI-monitor laying around in my room for quite a considerable time now. It was always connected to my Raspberry Pi with ever changing functionality. In the beginning I used it as a XBMC media center to watch movies and listen to music on my stereo. After that I wanted to use it to display useful information but found it strange pretty quickly to have a monitor standing around just to display information. Besides I didn’t even know what kind of information to show on it, so I again used it as a media center again.

Some time ago – while searching for interesting Raspberry Pi projects – I rediscovered the “Magic Mirror” build by Michael Teeuw and spontaneously decided to build one myself. I then found my self dissembling the monitors housing and starting to think how to best accommodate the Pi in this setup. I also changed some bits of Michaels original interface, from showing the same compliments in the UI all day to showing compliments based on the time of the day (my first Git-Pull-Requests; yeah!).

I didn’t really like the idea of having a monitor in my room, running 24/7 even if no-one was present who could actually look at the screen, so I ordered a relay and a motion sensor and wrote a small Python script to turn the monitors power only on when someone is in the room. Jonathan from Studio Einz helped me build this small circuit to switch the relay’s 5V circuit with the 3V from the Pi’s GPIO-pin’s. (Look at that fancy LED! We sadly didn’t have a diode so the LED had to do the trick :D)

Transistor Board

Relais

Bewegungsmelder

Raspberry Pi

Some users of the FRITZ!Box (a German internet router and phone system) may know: The device has a build in call monitor, which is easily read for example with Node.js and this handy module. Incoming calls then get redirected  to the web interface trough Socket.IO, which further displays this nice alert.

Anruf

There also is a feature to alert me when someone is ringing at the door in my code but before that’ll work I first have to connect my bell to the FRITZ!Box. Now I just need an actual mirror and a housing for the project.

Oh! If someone has an idea what else I could display on the mirror: I am listening!

Copyright © 2024 MeType

Theme by Anders NorenUp ↑