My Custom Modules for My Smart Mirror

Now that my smart mirror is finished I thought I'd write a post talking about each of the custom modules I've written and what they do.

Some of them are forks of other people's modules, and some are written completely from scratch. In total I have written 10 modules, and a few seem to be pretty popular amongst the folks on the Magic Mirror forum.

So in no particular order, here they are:

MMM-MyWeather



This module was my first foray. It is a fork of another module that is very similar, but I wanted to change the formatting a little, and turn off some of the features. Since this was "my" take on another's weather module, I aptly named it "MyWeather." As you'll see below, the "My" naming convention stuck!

MMM-MyCalendar

https://github.com/jclarke0000/MMM-MyCalendar


This one is a fork of the default calendar module. Once again, I just wanted to change up the formatting. Otherwise it is functionally identical to the default version.

MMM-MyCommute



This one started out as a fork of another module, once again just to tweak to display to match my emerging aesthetic, but it has become something entirely new. Its purpose is to display how long it's going to take you to get to work (or any other destination you choose). This one is very popular amongst Magic Mirror-ers (New word. Called it.), and it's highly configurable. It uses the Google Maps Directions API to retrieve traffic predictions for your configured routes. As you see in the screenshot above, it colour-codes the times based on traffic conditions, and you can optionally configure it to display times for alternative routes. You can choose to provide predictions for different modes of travel, including car, transit, bicycling and walking.

MMM-MyTTC



This is the first module I wrote from scratch. It displays arrival times for transit vehicles at stops you configure for the Toronto Transit Commission (gotta support the home team!). TTC provides a public real-time data feed using the NextBus API. NextBus supports several transit systems across North America, so I wrote a generic version of the module to support all of them.

MMM-MyNextBus

MMM-MyScoreboard

https://github.com/jclarke0000/MMM-MyScoreboard


There were already sports modules written for most of the sports I was interested in, but each of then looked and behaved just a little bit differently, and none of them were designed to hide themselves when no games were scheduled. So I wrote this one that consolidates several leagues into a single module -- you choose the sports and the teams you wish to follow, and if any games are scheduled for today, you'll see them listed. It currently supports NHL, NBA, MLB, and CFL (Canadian football). I'll be adding NFL as soon as the season gets underway. Sadly, no support for MLS soccer as there is no public data feed available. What's special about this module is that it's fairly easy to add other sports. As long as it can fit into the 2 teams with scores and game status format, it can be included (e.g.: Curling could work... tennis not so much). If you have many teams configured, this module can take up quite a bit of space. So you can choose from 6 different view styles that make better use of the screen space.

6 different configurable view styles

MMM-MyWastePickup



Here's another one for the home team! This one shows you your next two curbside waste pickup days and what is being collected on those days. Just for Toronto, folks, although the module works off of a CSV file, so it's pretty easy to make it work for your city if you already know the schedule.

MMM-MyNotes



I wanted the mirror to act as a bulletin board for the family, so I set up a GMail account just for the mirror (I know... nerdy right?). Any notes I create under this account will show up on the mirror. We use for pretty much any arbitrary information that we don't want to forget. To do lists, groceries we need to buy, or just a message I need to leave for other people in my family.

MMM-MyWink

https://github.com/jclarke0000/MMM-MyWink


I wrote this module to monitor the status of my door locks and my garage door. I have a bunch of smart home devices, many of which are connected to a Wink smart hub. At the moment, all this module does is monitor door locks and garage doors, but I plan to modify this for many more Wink compatible devices.

MMM-MyWordOfTheDay

https://github.com/jclarke0000/MMM-MyWordOfTheDay


This uses to Wordnik API to display the word of the day. There was already an existing module that did exactly this, but I couldn't get it to work right, and in my opinion it was way more complicated than it needed to be. So I wrote my own.

Utility Modules

I also wrote or modified a few utility modules. There was an existing module that reacted to input from a connected motion sensor for use in turning the display on and off. I modified it to add a third state that puts the mirror into a decorative screensaver mode, so after a few minutes of no motion detection, my mirror becomes a work of digital art for an hour, before it finally goes to sleep. I wrote a simple module to relay commands from an Amazon Echo to the mirror, things like shut down or switch profiles, and I modified the existing profile switcher module to have an extra feature to cycle through a list of profiles in reaction to a button press. The last two haven't been very useful though... see my previous post that talks about how useful voice control has been. And it turns out I really don't have a huge need for different display profiles. Pretty much all of the info on my mirror is useful to everyone in the family.

So this project comes to a close...

Generally I've learned quite a bit writing my own modules, and I've made my smart mirror truly my own creation. Additionally, I've become somewhat of an authority on how to write a Magic Mirror module, and so I frequent the forums helping people get their stuff working.

And have I mentioned the cool factor of my mirror? Everyone who visits is floored by this thing, especially by the amount of local information (TTC schedule, Toronto waste pickup, etc) I have included on it. So in the end, I think my mirror project is complete, and a huge success! I couldn't be happier with how it turned out.

Now on to the next nerdy project....

Comments

Popular Posts