Roost had a brilliant smart device, but their software wasn’t doing it justice. With their backend solution shutting down, a difficult-to-maintain codebase, and low AppStore ratings, they turned to PromptWorks for our expertise in cloud, mobile & IoT.

Roost is smart home devices company with a novel proposition: they believe that anyone should be able to afford smart home functionality.

Roost under a hot water heater

Their flagship product is a “smart” 9V battery with built-in WiFi. Just pop it into your existing “dumb” smoke alarm, and now you have a “smart” smoke alarm that’s connected to your phone and can alert you to smoke, fire, and a low battery no matter where you are. Instead of replacing smoke alarms at $200 each, you can purchase the smart battery for $30 and in about 10 years, a battery replacement for $10. It’s a simple, elegant, cost-efficient solution.

PromptWorks has worked with us as an integral part of our software team, and helped us with successful execution of several projects. They have over and again impressed us with how knowledgeable, skilled and professional they are. A major project that PromptWorks helped us with, was a Cloud migration project. The complexity of the project was worrisome, but PromptWorks helped us through the process and ensured a smooth transition.

Mickey Nasiri, VP Software for Roost

As Roost grew, they wanted to make sure their software design was as smart as their hardware design. How could their software be more reliable, scalable and easier to integrate with third parties?

They also had a pressing issue when Facebook shut down, which they had been using as their mobile backend service. Suddenly, the clock was ticking to find a replacement.

Parse Shutdown Reminder

They needed someone with expertise in cloud, mobile apps, and Internet of Things platforms – someone who could make their smart devices even smarter. They wanted to hire their own developers, but given all the demands placed on their small engineering team, they didn’t have the time to hire and found Silicon Valley talent too expensive.

And that’s why they turned to PromptWorks.

Step One: Analysis and Recommendations

Our role on the project took several forms, beginning with the role of analysis and education.

First, they asked us to educate them on options for cloud architecture and mobile strategy. We shared our in-depth knowledge of Amazon IoT, and provided an analysis on the simplest, most cost-efficient options for replacing their existing Parse backend. Ultimately, we advised that the best option in this scenario would be a lift-and-shift to Parse Server and Heroku.

Comparison Chart

Migration to an Open-Source, Cloud-Based Solution

To shift from Facebook’s deprecated service to the open-source Parse Server, we had to make some code changes, rework a bit of their architecture, and train their technical staff on best practices for working with 12-factor apps. We set up multiple environments on Heroku and a deployment pipeline to streamline their DevOps. The shift to Heroku was seamless thanks to separating their database and application tiers and migrating in phases. We smoothly transitioned their thousands of IoT devices and mobile clients to the new cloud without a hitch.

This new architecture made it easier for Roost engineers to manage their stack and for 3rd parties to integrate via custom Node.js APIs. We architected OAuth integration with ADT to provide monitoring for ADT security customers and assisted in building the IFTTT integration so their products could connect to thousands of other services and devices.

New Cross-Platform Mobile Apps

With the addition of Roost’s new water, temperature, and humidity sensors, the engineering team needed to add new features to their iOS and Android apps. They had hired offshore developers to build the original apps and the code was poorly architected, lacked automated tests, and would have taken an inordinate amount of time to repair before adding new features. The code got an ‘F’ in our automated Code Climate analysis. App store reviews gave it two stars.

Code Climate Grade

What’s more, all the problems were multiplied by two since they had separate codebases for the iOS and Android apps, developed by different developers in different countries. The iOS app had 70,000 lines of code and the Android app had 20,000. With no tests, refactoring was going to be a herculean effort.

PromptWorks engineer Dave Mox proposed rewriting the apps in React Native, a cross-platform JavaScript mobile development tool, and led the effort to replace the old apps with a single codebase that performed a superset of the original features. The team needed to complete the rewrite by the time the new hardware shipped, so they had to work quickly and make difficult prioritization decisions in collaboration with the product owner.

The team’s toughest technical challenge was re-implementing the “chirp” that communicates Wi-Fi connection information to the batteries and sensors via encrypted audio. Because it needed to directly drive the phone’s speaker, the team dropped down to native code within React Native and implemented separate chirp modules for iOS and Android elegantly and simply.

The code for the new app was developed using pair programming and test-driven development to ensure high quality and the right architecture.

Smoke detector and phone showing app

Smarter Software = Incredible Results

The results from PromptWorks’ time with Roost are nothing short of remarkable.

1. Roost’s new apps had 70,000 fewer lines of code to maintain, 93% test coverage, and scored an ‘A’ on Code Climate

Roost now has an IoT platform and mobile apps that are easier to maintain, and more future-proof. The entire technology stack, from the backend to the mobile apps is JavaScript, so finding developers becomes simpler and more cost-effective.

2. Roost is now able to easily and affordably scale their app

The infrastructure that hosts their platform is easy to manage. Ancillary services like the database are managed by cloud providers and rolling out new code is simple, automated, and safe. The costs associated with their Heroku cloud hosting are extremely budget-friendly. They can scale their resources up and down with the click of a mouse to meet demand during peaks and save money during quiet periods.

Installing the smart battery into a smoke detector

3. Customers have noticed the improvements, too, as AppStore customer reviews have improved from a 2-star avg. to ~4.5 star avg.

The new product they launched transformed the company from a smart-battery supplier to a IoT device ecosystem. The new sensor is selling well and will fuel the startup’s growth into other areas. Their new app has been well-received and its new features have added value to the product offering

Screenshots of the app

Roost’s new vibrancy has opened up new sales channels, particularly with insurance companies who want to use home telematics to mitigate claims, increase customer retention, and drive new business growth.