top of page
  • Writer's pictureAlex

Fall 2022 - Smart Home App Showcase

This term we worked on developing a smart home app that would be able to control devices via the new Matter smart home protocol. It's a new standardization for the way smart home devices will communicate with your existing ecosystems. Basically, if a device says it is "Matter certified", it'll work with any smart home ecosystems that supports Matter such as Google Home, Apple HomeKit, Amazon Alexa, and more. You can find out more information on the idea behind our project in this blog post.


We had three teams working hard on this project throughout the term

  1. View team (worked on the UI/UX design of the app)

  2. View Model team (worked on the backend logic or code behind the pages as well as integration between the other team's code)

  3. Matter team (worked on the code that communicates with the physical Matter device)


View team

The view team primarily designed the UI/UX of the app which is basically the look and feel as well as the experience in the app for the user. They used Figma for their design work and Android's XML layout designer for the actual Android implementation.


View Model team

The view model team primarily focused on setting up the communication between the backend server and our frontend app for storing user data onto a database via a REST API interface. They used the Retrofit library to accomplish this and packaged it up in a utility class for general purpose usage. This team also took care of setting up the Kotlin class models that represent the device objects for data modeling. The team also implemented the MVVM pattern for connecting the view to the view model and models. They essentially wired up all the logic behind every button click, page load, or user swipe to an action.


Matter team

The Matter team took care of implementing Google Home Matter SDK into our app so it could control the physical smart home light. We based our code on the sample app v1.0.3 from the instructions here: https://developers.home.google.com/codelabs/matter-sample-app#1. We pulled out the important pieces of code such as the base dependencies and files, toggling of devices, adding a device via the Google Home commissioning flow, getting devices, and removing a device from the account's repository of Matter devices. These functions would be triggered by the view model's team's implementation (e.g. the plus button on the home page starts an add device commissioning flow).


The device we used for testing was an ESP32 with code from the CHIP library at https://github.com/project-chip/connectedhomeip/tree/interop_testing_te9/examples/lighting-app/esp32. We have pre-built binaries and instructions for installing the firmware onto the device here: https://github.com/OSU-App-Club/MatterEsp32Firmware.



Final App Showcase

The final app turned out very good and was functional. At the time of recording, the Matter Google Home SDK was still under developer preview, but as of December 1st 2022, the Matter Google Home SDK should have version 1.0 released. The Matter commissioning flow was sometimes finicky and unreliable, but for the most part it worked and devices could be added to the account and controlled over the local network (tested on WPA2 network and hotspot, doesn't work on enterprise network) with or without an internet connection. The UI/UX reflected our view team's design and all the internal logic was working as intended.


Final App Explained + Next term's project idea


Resources

Figma Design:

View Model team repo:

Final app repo:

Backend API repo:

Matter device firmware repo:


90 views

Comments


bottom of page