WhoBuilt

Home automation with React Native and Raspberry Pi

Sep 14, 2018· 21 min· 1.5K views·Watch on YouTube

Speaker

Ville Immonen explains how he replaced his parents’ aging electric heating controller with a Raspberry Pi system and a React Native app, in a talk for Callstack.

Replacing a decades-old controller

Immonen’s parents’ controller managed 13 heating zones with separate sensors and weekly schedules, but began changing temperatures unpredictably after more than 25 years. He kept its high-voltage relay board and replaced the faulty processor board, emphasizing curiosity over formal electrical engineering training.

Building the electronics

He used a Raspberry Pi to read PT100 resistance-based temperature sensors and control the relays. After studying manuals and component data sheets, he designed a circuit board in Eagle, ordered a small manufacturing batch for about 25 euros plus shipping, and soldered the components himself.

Running heating control and HomeKit

A Python program on the Pi runs once a minute, reads target temperatures from SQLite, checks each sensor, and switches room heating on or off. A Node.js server connects the system to HomeKit, letting the family use Apple’s Home app and Siri to adjust temperatures and control outdoor lights.

Adding schedules with React Native

HomeKit’s scheduling depended on an iPhone being on the home network or an Apple TV, so Immonen built a separate app for weekly schedules. He added a GraphQL API to the Pi server and used Expo, React Navigation, and Apollo Client; schedules are saved in SQLite for the control loop to apply.

Exploring connectivity options

Immonen describes ZeroConf, also known as Bonjour, as a way for devices to broadcast their names and IP addresses so apps can discover them automatically. He also points to Bluetooth Low Energy and React Native native modules as options for connecting apps to hardware.

Takeaways

  • A Raspberry Pi can run local heating control without relying on cloud services or a phone being present.
  • Read component data sheets and forums to understand unfamiliar hardware interfaces.
  • A one-minute control loop can connect sensor readings, stored temperature targets, and relay actions.
  • React Native can provide a cross-platform interface for device settings that HomeKit does not cover.
  • ZeroConf and Bluetooth Low Energy offer alternatives to manually entering a device’s IP address.

Mentioned in this talk

Search inside this talk

What was claimed 15

Show all 15 facts

Related talks