Skip to content

LennardBoediger/prettySwitch

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation


prettySwitch

Remote HomeKit

An elegant "smart" light switch system

Welcome to prettySwitch! This project is my personal take on creating a usable "smart" light system. The goal is to create a system where you can control all the lights in your home from one or two permanently mounted, stylish remotes.

Key Features

  • Permanently Mounted Remotes: prettySwitch is designed around the idea of beautiful, permanent wall-mounted remotes that give you complete control over your lighting.
  • Clap-to-Turn-Off Functionality: The 80's already got it right so prettySwitch also has a "clap-to-off" feature. Just a simple clap of your hands, and your entire flat goes dark.
  • iOS HomeKit Integration: As a bonus, I've integrated iOS HomeKit support. This allows you to control your lights using your iPhone, iPad, or even Siri, adding a layer of convenience while I wait for all the hardware components to arrive.

HomeKit Integration & Power Efficiency

I've integrated iOS HomeKit support as a bonus, which allows you to control your lights using your iPhone, iPad, or Siri. While this was super easy to implement using the Arduino library HomeSpan, this library isn't designed with power-saving functionality in mind. For a more power-efficient solution, the official Espressif Matter SDK would be the correct approach. However, since my primary goal is to avoid having to use my phone to control my lights, I likely won't do this. For a simple, power-efficient integration without HomeKit functionality, check out my Espressif SDK based implementation here: TODO add Link


Hardware: 433MHz Wireless Sockets

This project uses inexpensive 433MHz wireless sockets. These are produced by many different companies and are widely available. They are all very similar in their functionality and protocol. To ensure reliable operation, make sure to get the ones that use DIP switches and not the ones that are self-learning, as they lose their settings after a power outage. My specific ones are from Pollin and Brennenstuhl.

HomeKit

Funkschalt-Set RCS 1000 N Comfort.

Getting Started

git clone --recurse-submodules git@github.com:LennardBoediger/prettySwitch.git

Setting Up the DIP Switches

To link your remote control to your wireless sockets, you need to configure the DIP switches on both devices. This is a crucial step to ensure they communicate on the same channel.

1. Locate the DIP Switches:

  • On the socket: The switches are typically found in a small compartment, often on the side or back of the socket. You may need a small screwdriver to open the cover.

2. Configure the Family Code: The first five switches (usually labeled 1 through 5) define the "Family code" or "group." This code determines which remote controls can talk to which sockets.

  • Use a small object (like a tiny screwdriver or a ballpoint pen) to set the switches to either the ON (up) or OFF (down) position. Here are the Family Code for Devices 0 to 3 as used in ElroRemote.h:

  • Device 0: {0, 1, 1, 1, 1}

  • Device 1: {1, 0, 1, 1, 1}

  • Device 2: {1, 1, 0, 1, 1}

  • Device 3: {1, 1, 1, 0, 1}

Note: In the list above, 0 typically represents the OFF position and 1 represents the ON position for the DIP switches. Screenshot 2025-08-25 at 12 22 10 copy

3. Configure the Channel Code: The remaining switches (often labeled A, B, C, D, etc.) are used to assign a specific channel to a remote's button. For a single remote with four buttons (like the Brennenstuhl one), each button will correspond to a different channel setting on the socket.

  • The remote's channel switches are often located next to the Family code switches. You may have one for each button (e.g., A, B, C, D).
  • The socket's channel switches are also located in its compartment. You'll need to set the channel on the socket to match the specific button you want to use on the remote. For example, if you set a socket's channel switch to 'B', it will only respond to the 'B' button on your remote.
Screenshot 2025-08-25 at 12 22 10

About

This project is my personal take on creating a usable "smart" light system.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published