mFi Controller Setup, Usage and Open APIs

The mFi product family has multiple members. All of them are capable of stand-alone operation. However, in order to present a unified interface to all the members in a particular network and also to implement the rules and scenes where one member can alter the state of another, we have a mFi controller instance running on a PC or supported embedded platform.

In order to configure the device, a PC or a mobile device is made to connect to its Wi-Fi SSID (a unique one for each device that appears when it has not been set up to connect to another SSID).

The details of the network to which it will connect to is configured, after which it can get an address via DHCP. Each device runs a web server and can be accessed for further configuration by logging into it with the default username / password combination - ubnt / ubnt.

The setup process of the InWall Light Switch and Dimmer as well as the InWall Outlet is similar to the one described in our initial mPower review. The gallery below shows how the InWall Light Switch and Dimmer was configured. By default, the device comes up in the switch mode (suitable for lights and also other devices - up to 120V @ 15 A). Altering the unit to the dimmer mode reduces the maximum load rating (to 120V @ 5A). We can also see how altering the dimming slider affects the power consumption of the lights.

The latest firmware allows many standalone operation options such as scheduling, vacation mode, port mirroring (keeping states of the outlets in sync) and automatic power shutoff (with minimums for voltage and maximums for voltage and current).

The adoption of the controller is a feature we didn't discuss in our earlier review. The mFi controller software is available for many platforms. Even the Raspberry Pi can be used. In our setup, we chose to install the software on Ubuntu.

We already have the QNAP TS-853Pro in long term testing and decided to install Ubuntu in a VM using the Virtualization Station package. Following the steps given in the Ubiquiti forums, we were able to get our mFi controller up and running in a VM on the QNAP NAS.

The controller can be used to set up rules and scenes as well as control the member devices, as shown in the gallery below.

The prevalence of smartphones and tablets have made mobile apps an indispensable part of any automation ecosystem (in both residential and business settings). Only recently has there been renewed interest in this area from Ubiquiti Networks. The officially-sanctioned Android app is still in beta, but delivers basic functionality for the mPower and InWall devices. The mPort devices are not supported yet.

However, the controller also has a mobile interface accessible at: https://<IP>:6443/mobile for comprehensive access to the system. A shortcut to the URL on the home screen of the mobile device can act as a very good substitute for a mobile app.

The interface allows control, viewing of instantaneous power consumption, rules and scenes.

All mFi devices run a Linux kernel. SSH access is available. HTTP APIs are well documented. Note that the availability of WebSockets allows for event-driven reactions and avoids the overhead caused by polling when trying to integrate mFi devices into other automation systems. Password protection provides security. As long as one's Wi-Fi network is secure, there is no security risk - mFi doesn't need any ports to be made open to the Internet. The security aspect is easily understood even by novice users.

That brings us to the only downside (in addition to the requirement of a standalone PC or embedded platform capable of running the mFi controller) - there is no way to access the controller and/or devices from an external network. This is easily solved by port forwarding. For a more secure solution, a VPN is preferable.

mFi and WeMo Product Lines WeMo Setup and Usage
Comments Locked

41 Comments

View All Comments

  • Daniel Egger - Monday, April 27, 2015 - link

    > But since an led light usually uses around 5 watt an hour

    Well that depends on your LED lighting, 5W will yield around 400lm which is equal to around 40W of incandescent lighting which is not really much unless you're talking cozy reading lamp. For my ambient living room lighting alone I have 2 PSUs with combined 210W output and running all channels at full brightness (which is crazily bright) they use around 130W. In addition I have 26W of Living Colors for accent lighting and another 12W lighting my bar.

    > how many decades do you need to keep the light on before a 50$ light switch and 2-300$ total solution pays for itself

    How would it *ever* pay for itself? Those solutions increase power consumption and do not offer any savings whatsoever: if I need my lights they're on, if I don't they're off -- it doesn't get simpler than that.
  • V900 - Monday, April 27, 2015 - link

    HOLY CRAP that's a lotta lights and wattage you got there!

    I think my whole living room is lit with 10-12 watts or so. Then again, in Europe power can easily cost ten times of what it costs in North America. Especially the parts of NA that get their power from nuclear power plants or through hydro electric means.

    And even in Europe with high power costs, LED bulbs has made conserving the lights and power sorta meaningless. Even when you pay 1-2$ pr kilowatts, forgetting to turn off the lights costs a lot less when your lightbulbs use 5-10 times less power.
  • Daniel Egger - Monday, April 27, 2015 - link

    > HOLY CRAP that's a lotta lights and wattage you got there!

    Yes, but a regular nighttime light scene only takes around 40W in total which is not much. Even the 200W halogen uplight I had a couple of years ago took 120W at the darkest dimm setting while only lighting a fraction of the area. Heck, even the projector over my head is using almost 200W right now.

    > I think my whole living room is lit with 10-12 watts or so.

    You must have a small living room or prefer candlelight setups. ;) As I said my bar has 4 downlights with 3W each (80lm/W) and is by far the best LED light I've ever seen, very halogen-like -- I totally love that beautiful setup and it's easily as good and bright as the 4x20W halogen downlights which are installed next to them in the kitchen. But it's not even remotely possible to light the whole living room just with those...
  • malcolmh - Wednesday, April 29, 2015 - link

    "$1-$2 per kilowatts"? Not sure where you get that assumption from.

    Here in the UK I'm paying £0.0945 / kWh, which is about 15 cents US. My plan also has a £0.25/day flat rate standing charge, but since that's a flat rate it's not really relevant here.

    I also can't see the point of these devices though. /Maybe/ if you integrated them to a whole-room voice activation system, that worked as reliably as the video promoting Amazon Echo...
  • ganeshts - Monday, April 27, 2015 - link

    Couple of examples:

    Vacation mode : You are out on vacation, but need to make your house look occupied to the outside world - If you could randomly turn on/off lights at night remotely / set such a schedule, that would be a deterrent against would-be burglars.

    Home Theater setting : If it is night and you are starting to watch a movie on your TV, slowly dim and then switch off the lights.

    Energy sensing outlets can help you determine what devices consume the most power and how you can optimize their usage. Check out reviews of smart outlets on Amazon - there are plenty of usage models. I do agree that they need to come down in cost - which is where the InWall outlets come into play - they don't really have that much premium over the generic outlets that are installed in the walls.
  • steven75 - Monday, April 27, 2015 - link

    "they don't really have that much premium over the generic outlets that are installed in the walls."

    I beg to differ. $59 vs about $1.50 for a duplex outlet at the local hardware store is a massive premium.

    I like the idea of this stuff very much, it's just that the price needs to be lower by a factor of about 10.
  • ganeshts - Monday, April 27, 2015 - link

    You are right.. I was having the dimmer switches in mind when I wrote that:

    http://www.homedepot.com/b/Electrical-Dimmers-Swit...

    The minimum is around $22 - the good ones around $30 ; There is a premium of around $30, but that is still less than the ~$60 premium for the outlets.
  • Daniel Egger - Monday, April 27, 2015 - link

    > Vacation mode : You are out on vacation, but need to make your house look occupied to the outside world - If you could randomly turn on/off lights at night remotely / set such a schedule, that would be a deterrent against would-be burglars.

    Right, because burglars are utterly stupid; they don't notice that the car is absent for weeks but are easily fooled by randomly flicked lights (because that's what people do, rather than say turn it on on demand and depending on the sunset). Not to mention that the best protection against burglars here are roller shutters which tend to counter the idea of making light inside for the outsider to see.

    > Energy sensing outlets can help you determine what devices consume the most power and how you can optimize their usage.

    You'll only have to do that once per device. There's no point in doing it constantly; it's a huge waste of energy without any information gain.
  • V900 - Monday, April 27, 2015 - link

    Actually, today's modern burglar doesn't have to sit in a parked car for hours to do surveillance on a potential house to burglarize.

    (I actually doubt they've ever done that, though that is the whole logic behind setting your lights on timers. No matter if we're talking about 3$ manual dollar store timers or 50$ Belkin internet timers.)

    Even today's poorly equipped burglar can go on Facebook to see whether the owners are home, or if the whole family is in the Dominican Republic for two weeks.

    And the 70$ Android handset put an end to the good old "What kinda burglar brings their smartphone to work?!?" argument.
  • Daniel Egger - Monday, April 27, 2015 - link

    > Actually, today's modern burglar doesn't have to sit in a parked car for hours to do surveillance on a potential house to burglarize.

    My point exactly. Even though I don't use Facebook et al, it's quite easy to spot -- just by driving by -- whether we're at home. Hm, maybe I should switch my parking spots every now and then to create the illusion I'm at home. ;)

Log in

Don't have an account? Sign up now