Skip to the content
PCBKitNew board
2 layersRocker, the printed circuit board in 3D

A simplicated switch for smart home devices

Copper layers
2
Thickness
1.6 mm
Parts
17
Nets
15
Pads
52
Tracks, vias
0, 0
Routed
Not yet
KiCad
KiCad 10.0 (file 20260206)
Created
6 Jun 2026
Updated
6 Jun 2026

Overview

Rocker is an open-source printed circuit board by jcranney, from the jcranney/smart-switch repository on GitHub, published under the Unlicense licence. It is a 2-layer board with 17 parts on 15 nets.

It is built around the LM324. Its parts include 5 resistors, 1 IC and 1 connector.

Main components

1

README

README.md

smart-switch

Simple devices in your home like lights and garden taps can be fun and rewarding to "smartify". Setting your garden lights to come on at sunset and turn off 3 hours later is immensely satisfying, but the beauty is shattered when you are having a dinner party and the lights flick off, and to turn them back on you need to go and find your phone to switch them back on. Sensors can help aleviate the problem, but there will always be edge cases where a good old fashioned switch is the best solution.

I looked up "smart switches" online and was confused and overwhelmed by the price and complexity of the commercial off-the-shelf solutions. So, to combat this confusion, I have set out on a long and arduous mission to build a simple, cheap, and dare-I-say, pretty, solution.

Design reference missions

A) I'm lying in bed and remember that I've left the garden lights on. The lights are controlled by an ESPHome relay and can be switched on and off by posting to a locally hosted MQTT broker on the topic /lights/garden/on and /lights/garden/off respectively. I reach to the side of my bedside table where I have a row of 4 switches and flick off the 3rd one which is labelled "garden lights".

B) I'm in the workshop and want to run the sprinklers in the vege patch for 15 minutes. I walk over to the switch panel near the door and flick the 2nd switch which has the top labelled "garden 15 min" and the bottom labelled "off". I flick the switch up, and the sprinklers run for 15 minutes. While they are running, a faint LED indicates that the switch is in the "top" state, but when the taps turn off automatically in 15 minutes time, the LED flicks back down to the bottom light, indicating that they are off.

C) I have a guest over and they walk past my array of switches in the sitting room without being offended by their sight.

Top Level Requirements

  1. The switch shall be compact, such that 8 switches in a row shall take up a width of less than 200 mm and height of 80 mm.
  2. The switches shall be modular, such that they can be replaced easily if they fail or if a new version is manufactured.
  3. The switches shall be non-offensive to any of the senses.
  4. The switches shall be cheap, each unit costing less than $10 (goal $5).
  5. The switches should interact with an MQTT broker via the internet to publish their state, and to subscribe to the state of the variable they control.

Derived Requirements

1.1) An individual switch shall have a footprint of less than 25 mm x 80 mm (W x H).

3.1) The switches should have LEDs to indicate the state of the swtiches, but the brightness of the LED should be configurable via MQTT topic (or similar), with the minimum brightness being fully off. 3.2) The switches must be silent, except when actuated when they may produce a tactile click or similar.

4.1) The switch body should be made primarily of cheap materials, preferably 3d printed PLA/PETG.

5.1) The switches themselves do not need to have wifi, but they should link to a wifi device that publishes the swtich events to an MQTT broker, and subscribes to MQTT topics regarding the state of the switch LEDs.

Design Notes

MECH-1) all of the v0.* versions have the same mechanical design principle. Flexures are used to constrain a captured rocker switch to the nominal "centre" position, but allow enough motion for the rocker hammer to press a small tacticle switch mounted onto a PCB with a 90 degree bend. Two of these tactile switches will sit on opposite sides of the hammer. MECH-2) the flexure springs are stiffer than I expected, so the main difference between v0.2->v0.5 is tweaks to the flexure springs.

Parts

17
QtyValueFootprintReferences
5880RResistor_SMD:R_0603_1608MetricRB1, RLA1, RLB1, RW1, RW3
43.3kRResistor_SMD:R_0603_1608MetricR1, R3, R4, RW2
2LEDLED_THT:LED_D1.8mm_W3.3mm_H2.4mmDA1, DB1
2SW_MEC_5GButton_Switch_THT:SW_Tactile_SKHH_AngledSWA1, SWB1
113.2kRResistor_SMD:R_0603_1608MetricR2
14.4kRResistor_SMD:R_0603_1608MetricRA1
1LM324Package_SO:SOIC-14_3.9x8.7mm_P1.27mmU1
1MCUConnector_PinHeader_2.54mm:PinHeader_1x04_P2.54mm_HorizontalJ1

Questions

What parts does the Rocker use?

17 parts, built around the LM324. The full list of its parts is on this page, with links to each part's symbol and footprint where PCBKit's library has them.

Where can I download the Rocker KiCad files?

From the jcranney/smart-switch repository on GitHub, at the commit this page was made from: the board is electronic/rocker/rocker.kicad_pcb and its schematic electronic/rocker/.kicad_sch. PCBKit opens the board in the browser, with nothing to install.

Can I use the Rocker design in my own project?

Its repository publishes it under the Unlicense licence: you may reuse it on that licence's terms (keep the author's notice, and for a copyleft licence share your changes alike).

Similar boards

  • 4 layers99 × 53.3 mmPSLab, the printed circuit board in 3D

    PSLab

    fossasia/pslab-hardware

    PSLab Hardware Design and Schematics https://pslab.io

    199 parts1.7kApache-2.0
  • 2 layers36.8 × 34.7 mmTinylab proto1, the printed circuit board in 3D

    Tinylab proto1

    espotek-org/Labrador

    EspoTek Labrador is a USB device that transforms your PC or smartphone into a fully-featured electronics lab. This repo holds all of the source code!

    79 parts1.2k
  • 4 layers82.6 × 82.5 mmJumperless2, the printed circuit board in 3D

    Jumperless2

    Architeuthis-Flux/Jumperless

    A jumperless breadboard

    208 parts914
  • 2 layers231.1 × 106.7 mmSnark barker, the printed circuit board in 3D

    Snark barker

    schlae/snark-barker

    A 100% compatible replica of the famed SB 1.0 sound card

    199 parts687
  • 4 layers82.6 × 82.6 mmJumperlessV5r8, the printed circuit board in 3D

    JumperlessV5r8

    Architeuthis-Flux/JumperlessV5

    The next generation jumperless breadboard

    650 parts332
  • 4 layers72.4 × 95.3 mmDingoPDM, the printed circuit board in 3D

    DingoPDM

    corygrant/dingoPDM

    Hardware - dingoPDM is an open source, affordable automotive PDM (Power Distribution Module). Pre-assembled and tested units are available or the design can be used to build a DIY version.

    156 parts128MIT
  • 2 layers191.5 × 76 mmPcb project, the printed circuit board in 3D

    Pcb project

    CrashOverride85/zc95

    4 channel EStim box inspired by the mk312bt, with Lua scripting support

    337 parts117GPL-3.0
  • 4 layers292.1 × 88.3 mmSnark barker mca, the printed circuit board in 3D

    Snark barker mca

    schlae/snark-barker-mca

    A Sound Blaster compatible sound card for Micro Channel bus computers

    177 parts69