Smart sensor

This article describes how to create a DIY smart multi-sensor with HomeGenie Mini smart-sensor firmware and ESP32-C3/S3 SoC.

Found in nearly all modern gadgets, sensors gather and measure data about the environment or other factors. Examples include position, height, speed, temperature, vibrations, air quality, touch, color, smoke and gas, tilt, light, and proximity, to name a few. But this is not just about showing data, sensors are used to analyze and collect more accurate input in order to offer improved responses, functionality, or services.

A simple and common application is the control of lighting, for instance, through the use of a motion and light sensor to automate switching on and off, which is one of the features implemented by the smart-sensor firmware through the default schedules:

The video below shows how to configure the Motion.Blink schedule with the integrated RGB status led and other lights.

Product features:

The onboard RGB LED can be used to signal when motion is detected, or to report other user-defined states using different colors.

Smart Multi-Sensor kit v1.0 (igloo)

This kit consists of a translucent, small enclosure measuring 2,2 × 2,2 × 3,6 cm and a PCB shield for ESP32-C3/S3 Zero development board that can embed various sensors.

PCB shield

On the upper side of the PCB there are the light sensor and the motion sensor, while on the lower side there are the two 9-pin header rails on which the ESP32 board is connected.

The PCB can eventually also host the following components:

However, to keep it simple (yet smart =)), the kit only includes the components that are required to implement motion + light sensing.

Components listing

Casing

Printed using translucent PETG material, the enclosure takes about 30 minutes to print with a 0.4mm nozzle and 0.20mm layer height on an A1-mini 3D printer.

Assembly instructions

Project files

Smart Sensor kit

PCB Gerber download REV. 1

Enclosure 3MF download REV. 1

Smart Sensor project files by G-Labs licensed under CC BY-NC 4.0

Create this device now! 🪄

Connect your ESP32 / ESP8266 microcontroller to the USB port of this computer, select the desired firmware version, and click the "Create device" button to upload HomeGenie Mini firmware to the device.

1. Select device type

2. Select firmware flavor

3. Let the magic happen!

Installing firmware directly from this page works only in browsers with Web Serial API enabled.

See the Device setup page for further information about configuring a HomeGenie Mini device.

forum Q & A Discussion Forum

Source code

This firmware pre-compiled binaries and source code are available on GitHub:

folder_open smart-sensor folder_open smart-sensor-display

Modules and API

In addition to the common Device API, the following modules and API are implemented by this device.

mini module

Built-in sensor module.

Domain / Address

HomeAutomation.HomeGenie/mini

Properties

arrow_left  Previous
Next arrow_right 

More topics

Setup

Programming

forum Q & A Discussion Forum
HomeGenie
MINI 1.2 — Documentation