Skip to the content
4 layers65 × 56 mmSensor HAT, the printed circuit board in 3D

Open-hardware indoor air sensor (CO2, VOC/NOx, T/RH, light, sound): HAT for Raspberry Pi or standalone with Seeed XIAO + ESPHome. KiCad 10.

Size
65 × 56 mm
Copper layers
4
Thickness
1.6 mm
Parts
112
Nets
74
Pads
361
Tracks, vias
1,147, 184
Pours
20
Routed
Yes
KiCad
KiCad 10.0 (file 20260206)
Created
22 Oct 2026
Updated
30 Oct 2026

Overview

Sensor HAT is an open-source printed circuit board by Eniemooo, from the Eniemooo/Sensor-HAT repository on GitHub. It is a 4-layer board of 65 × 56 mm with 112 parts on 74 nets, routed with 1,147 tracks and 184 vias.

It is built around the SN74LV1T125DBVR-TP, SGP41-D-R4 and SHT40-AD1B-R2, with the VEML7700-TT, AP2112K-3.3TRG1 and LM66100DCK among its other parts. Its parts include 38 resistors, 27 capacitors, 13 ICs, 8 connectors and 3 diodes. It belongs with the sensors and measurement boards of this library.

Main components

12

README

README.md

Sensor HAT v3 "Universal"

Deutsch (ausführliche Anleitung): README.de.md

An open-hardware indoor-environment sensor board, designed in KiCad 10 (65 × 56 mm, 4 layers). It runs in one of two modes, never both at once:

  1. HAT for Raspberry Pi 2, 3, 4 and 5, with a HAT+ ID EEPROM and Python.
  2. Standalone with a plug-in Seeed Studio XIAO ESP32-S3, -C3 or -C6 (not included). It is powered over the XIAO's USB-C, runs ESPHome and shows up in Home Assistant.

3D render of the board

Status: the design is complete. KiCad ERC and DRC report no errors, and the ESPHome configs validate. It has not been tested in hardware yet. Build prototypes before ordering in quantity.

What is on the board

FunctionPartI²C address / Pi GPIO / XIAO pin
CO₂ (photoacoustic, not an eCO₂ estimate)Sensirion SCD41, own 3.3 V regulator0x62
Temperature, humiditySensirion SHT40 on a milled, thermally isolated island0x44
VOC and NOx indexSensirion SGP410x59
Ambient light (lux)Vishay VEML77000x10
Sound levelTDK ICS-43434 I²S microphonePi GPIO18/19/20, XIAO D1/D0/D2
RGB status LED (e.g. CO₂ traffic light)WS2812B-2020 with 5 V level shifterPi GPIO10, XIAO D10
ButtonSW1Pi GPIO27, XIAO D4
Buzzer (passive, 4 kHz)MLT-5020Pi GPIO13, XIAO D3
Particulate sensor port (Sensirion SEN6x/SEN5x)J4, JST GH 6-pin, own regulator0x6B / 0x69
mmWave radar / UART (e.g. HLK-LD2420; LD2410C with 5 V and a re-ordered cable)J3Pi GPIO14/15 (+GPIO17 OUT), XIAO D6/D7
1-Wire (e.g. DS18B20)J2Pi GPIO4, XIAO D5 (JP6)
Qwiic / STEMMA QTJ5, JST SH 4-pinI²C, 3.3 V
Spare GPIOs (Pi only)J6, 2×5 pads, not populatedGPIO5, 12, 22–26
HAT ID EEPROMonsemi CAT24C32ID_SD/ID_SC, 0x50

All parts are in active production. The one exception is the ICS-43434 microphone: it is obsolete but still widely stocked.

Two LM66100 ideal diodes keep the two power sources apart, so no current flows from the Pi into the XIAO's USB port or the other way round.

Using it

XIAO mode (ESPHome / Home Assistant)

  1. Copy the files for your XIAO from software/esphome/: sensor-hat-xiao-s3.yaml, -c3.yaml or -c6.yaml. You always need sensor-hat-common.yaml and a secrets.yaml as well. Start from secrets.yaml.example and fill in:

    • your Wi-Fi name and password
    • an API encryption key (openssl rand -base64 32), which also protects OTA updates
    • a password for the fallback hotspot (at least 8 characters)

    The placeholders in the template are rejected by esphome config on purpose. With more than one board, give each its own name: in the substitutions, for example sensor-hat-kitchen.

  2. Flash the XIAO once over USB without the board attached. Then plug it into J7/J8 with the USB-C facing outwards. Later updates go over Wi-Fi. When you add the device in Home Assistant, it asks for the API encryption key.

  3. Calibrate the readings:

    • set altitude_compensation to your altitude
    • after 15 minutes of running, enter the SHT40 offset against a reference thermometer

Notes:

  • Power supply: at least 5 V / 1.5 A with the particulate sensor and radar connected, otherwise at least 1 A. A PC USB port is not enough.
  • Battery: do not connect a battery to the XIAO.
  • Antenna: use a U.FL antenna. This also applies to the C6: its chip antenna sits 11 mm above the ground plane. On the C6, also set restore_mode: ALWAYS_ON for the antenna_select switch in sensor-hat-xiao-c6.yaml (GPIO14 high selects the U.FL socket).
  • Strapping-pin warnings: ESPHome warns about strapping pins on the C3 (GPIO2/8/9) and the S3 (GPIO3). These pins are pulled up or not sampled on this board, so the warnings are expected and harmless.

Raspberry Pi mode

  1. Leave the XIAO socket empty.
  2. Add the lines from software/config.txt.snippet to /boot/firmware/config.txt and reboot.
  3. Run software/sensor_test.py. The pip packages it needs are listed at the top of the file.
  4. To program the HAT+ ID EEPROM, see software/eeprom_settings.txt and the German README.

Solder jumpers: check them before you connect anything

JumperAs deliveredFunction
JP1 / JP3openJ3 supply: JP1 = 3.3 V, JP3 = 5 V. Never bridge both.
JP4 / JP5JP4 closedJ4 supply: JP4 = 3.3 V for SEN6x, JP5 = 5 V for SEN5x. 5 V destroys a SEN6x. Cut JP4, check with a multimeter that it is open, then bridge JP5.
JP61-2 closedXIAO D5 = 1-Wire (J2). For the radar OUT pin, cut 1-2 and bridge 2-3.
JP2openBridge it to make the HAT EEPROM writable (Pi only).
  • J3 radar: the pin order is V+, GND, module TX, module RX, OUT.
    • HLK-LD2420 and LD2410S fit directly (bridge JP1, 3.3 V).
    • LD2410C and LD2450 need JP3 (5 V) and a re-ordered cable.
    • In ESPHome, use sensor-hat-radar-ld2410.yaml for the LD2410/LD2410C and the ld2420 component for the LD2420. ESPHome has no UART support for the LD2410S, so only its OUT pin works (JP6 2-3).
  • J4 particulate sensor: use a 6-pin JST GH cable wired pin 1 to pin 1 (VDD).
    • Check the cable with a multimeter first: crossed cables exist.
    • In XIAO mode use a SEN6x. A SEN5x needs at least 4.5 V, which is marginal on USB power.

Ordering

production/ holds JLCPCB files: Gerber zip, BOM and CPL in two variants. The "komplett" variant also has JLCPCB solder the through-hole headers and XIAO sockets. The 40-pin Pi socket J1 is always soldered by hand.

Recommended settings:

  • 4 layers, 1.6 mm, ENIG
  • Standard PCBA, top side only, peak 245 °C
  • tooling holes added by JLCPCB. The board (65 × 56 mm) is smaller than the 70 × 70 mm Standard-PCBA minimum, so it needs edge rails: on the left and right edges and one on the top edge (about 75 × 70 mm in total), never on the bottom edge with the milled sensor island. Have JLCPCB confirm this.
  • no board washing

The complete order remark is in the German README, section "Bei JLCPCB bestellen".

Estimated landed cost per assembled board for the SMD-only variant, incl. 19 % German VAT. You buy and solder the headers J1–J3, J7 and J8 yourself. python3 -I scripts/cost.py recalculates it with live part prices:

Boards252050100
per board~125 €~77 €~50 €~42 €~37 €

Small orders are expensive because of fixed setup fees, so a community group buy at cost is planned (German: docs/Sammelbestellung.md).

Repository layout

PathContents
Sensor-HAT.kicad_pro/.kicad_sch/.kicad_pcbKiCad 10 project
production/Gerber, BOM, CPL for JLCPCB
docs/schematic and assembly PDFs, renders, group-buy documents (German)
software/ESPHome configs, Pi config, test script, EEPROM settings
lib/project symbols and footprints (3D models: see below)
scripts/the generator: design.py (parts and nets) and placement.py are the single source of truth; build.sh regenerates schematic and board and autoroutes them

Building from source

bash
pip install easyeda2kicad
python3 -I scripts/fetch_3d_models.py .   # LCSC 3D models, only needed for 3D view, renders, STEP
export FREEROUTING_JAR=/path/to/freerouting-2.5.0.jar
scripts/build.sh                          # schematic + ERC, board, autorouting, GND repair, DRC
python3 -I scripts/export.py .            # Gerber, BOM, CPL, PDFs, renders, STEP

Requirements:

The scripts expect KiCad on macOS at ~/Applications/KiCad/KiCad.app. For other installations, change the paths at the top of build.sh, kicadlib.py, gen_pcb.py, route.py, cleanup.py and export.py. If your Java is not Homebrew's openjdk, run export JAVA=$(which java) before build.sh.

Licence

  • Hardware (KiCad project, scripts/design.py and scripts/placement.py, production files, PDFs, renders): CERN-OHL-S-2.0
  • Software and the other scripts: MIT
  • Documentation: CC-BY-SA-4.0 or, at your choice, CERN-OHL-S-2.0

Source: https://github.com/Eniemooo/Sensor-HAT. Which licence covers which file is listed in LICENSE.md. Some symbols and footprints come from the LCSC/EasyEDA library, which has no licence of its own. These parts, and the trademarks, are listed in NOTICE.md.

Raspberry Pi is a trademark of Raspberry Pi Ltd. This project is not affiliated with Raspberry Pi Ltd or Seeed Studio. No warranty.

Parts

112
QtyValueFootprintReferences
14100Resistor_SMD:R_0603_1608MetricR16, R20, R22, R33, R34, R35, R36, R37, R38, R39, R40, R41, R42, R43
121uFCapacitor_SMD:C_0603_1608MetricC1, C2, C3, C14, C15, C17, C18, C27, C28, C29, C30, C31
10100nFCapacitor_SMD:C_0603_1608MetricC5, C6, C8, C9, C10, C16, C20, C23, C24, C26
9100kResistor_SMD:R_0603_1608MetricR4, R7, R11, R13, R14, R23, R29, R30, R32
410kResistor_SMD:R_0603_1608MetricR12, R15, R19, R31
41kResistor_SMD:R_0603_1608MetricR5, R8, R9, R10
4M2.5MountingHole:MountingHole_2.7mm_M2.5MH1, MH2, MH3, MH4
34.7kResistor_SMD:R_0603_1608MetricR1, R26, R27
3AP2112K-3.3SensorHAT:SOT-25-5_L2.9-W1.6-P0.95-LS2.8-BLU5, U6, U9
210uFCapacitor_SMD:C_0603_1608MetricC4, C13
210uF 25VCapacitor_SMD:C_0805_2012MetricC11, C12
23.9kResistor_SMD:R_0603_1608MetricR2, R3
2AO3400ASensorHAT:SOT-23_L2.9-W1.3-P1.90-LS2.4-BRQ2, Q3
2LM66100SensorHAT:SC-70-6_L2.0-W1.3-P0.65-LS2.1-BLU14, U15
1+3V3TestPoint:TestPoint_Pad_D1.5mmTP2
1+3V3_CO2TestPoint:TestPoint_Pad_D1.5mmTP3
1+5VTestPoint:TestPoint_Pad_D1.5mmTP1
10.5A PTCFuse:Fuse_1206_3216MetricF1
11-Wire GND/DQ/3V3Connector_PinHeader_2.54mm:PinHeader_1x03_P2.54mm_VerticalJ2
11N4148WSensorHAT:SOD-123F_L2.7-W1.6-LS3.8-RDD2
122uF 25VCapacitor_SMD:C_0805_2012MetricC19
133 0.5W 1206Resistor_SMD:R_1206_3216MetricR21
14.7Resistor_SMD:R_0603_1608MetricR28
174LV1T125SensorHAT:SOT-23-5_L3.0-W1.7-P0.95-LS2.8-BLU12
1AO3401ASensorHAT:SOT-23_L2.9-W1.3-P1.90-LS2.4-BRQ1
1BAV70SensorHAT:SOT-23-3_L3.0-W1.7-P0.95-LS2.9-BRD3
1ButtonSensorHAT:SW-SMD_4P-L5.1-W5.1-P3.70-LS6.5-TL_H1.5SW1
1CAT24C32SensorHAT:SOIC-8_L5.0-W4.0-P1.27-LS6.0-BLU4
1D5 = 1-Wire | radar OUTJumper:SolderJumper-3_P1.3mm_Bridged12_RoundedPad1.0x1.5mmJP6
1EEPROM write enableJumper:SolderJumper-2_P1.3mm_Open_RoundedPad1.0x1.5mmJP2
1EE_WPTestPoint:TestPoint_Pad_D1.5mmTP5
1GNDTestPoint:TestPoint_Pad_D1.5mmTP4
1GPIO expansion (DNP)Connector_PinHeader_2.54mm:PinHeader_2x05_P2.54mm_VerticalJ6
1I2C_SCLTestPoint:TestPoint_Pad_D1.5mmTP7
1I2C_SDATestPoint:TestPoint_Pad_D1.5mmTP6
1ICS-43434Sensor_Audio:InvenSense_ICS-43434-6_3.5x2.65mmU3
1J3 VCC = 3V3Jumper:SolderJumper-2_P1.3mm_Open_RoundedPad1.0x1.5mmJP1
1J3 VCC = 5VJumper:SolderJumper-2_P1.3mm_Open_RoundedPad1.0x1.5mmJP3
1MLT-5020 4kHzSensorHAT:BUZ-SMD_L5.0-W5.5-P4.60LS1
1PM VCC = 3V3Jumper:SolderJumper-2_P1.3mm_Bridged_RoundedPad1.0x1.5mmJP4
1PM VCC = 5VJumper:SolderJumper-2_P1.3mm_Open_RoundedPad1.0x1.5mmJP5
1PM sensor (SEN6x/SEN5x)SensorHAT:CONN-SMD_6P-P1.25_BM06B-GHS-TBT-LF-SN-NJ4
1Qwiic / STEMMA QTSensorHAT:CONN-SMD_BM04B-SRSS-TBJ5
1RPi GPIO 2x20Connector_PinSocket_2.54mm:PinSocket_2x20_P2.54mm_VerticalJ1
1SCD41-D-R2SensorHAT:LGA-20_L10.1-W10.1-P1.25-TL_SCD41-D-R2U1
1SGP41SensorHAT:DFN-6_L2.4-W2.4-P0.80-TL-EPU13
1SHT40SensorHAT:SHT4x_DFN-4_1.5x1.5mm_P0.8mm_NoCentralPadU2
1SRV05-4SensorHAT:SOT-23-6_L2.9-W1.6-P0.95-LS2.8-BRU8
1UART (e.g. PMS5003)Connector_PinHeader_2.54mm:PinHeader_1x05_P2.54mm_VerticalJ3
1VEML7700-TTSensorHAT:SENSOR-SMD_EML7700-TTU7
1WS2812B-2020SensorHAT:LED-SMD_4P-L2.2-W2.0-P1.00_WS2815C-2020-4PD1
1XIAO 5V-D7SensorHAT:HDR-TH_7P-P2.54-V-FJ8
1XIAO D0-D6SensorHAT:HDR-TH_7P-P2.54-V-FJ7

Similar boards

  • 4 layers50 × 50 mm50x50 2 Layer, the printed circuit board in 3D

    50x50 2 Layer

    UC-Aerospace/Electrical-Tut-26

    2026 Avionics tutorial example boards for UC Aerospace

    86 parts
  • 4 layers21 × 51 mmEasy2350, the printed circuit board in 3D

    Easy2350

    sequoia-hope/ultraroute

    PCB autorouting experiments around copperroute: route jobs, leaderboards, board morphing

    58 parts1MIT
  • 4 layers45 × 34.8 mmKywy Micro, the printed circuit board in 3D

    Kywy Micro

    KOINSLOT-Inc/kywy-hardware

    kywy hardware files

    92 parts1
  • 2 layers86 × 60 mmPmbh, the printed circuit board in 3D

    Pmbh

    3351666087/solar-vest

    Self-powered solar-harvesting wearable ECG vest: PCBs, 3D-printed enclosures, vest patterns, simulation and an interactive 3D explorer

    100 parts
  • 4 layers100 × 90 mmOpentouch s3, the printed circuit board in 3D

    Opentouch s3

    JoeMighty/opentouch-s3

    A modern remake of the Bare Conductive Touch Board: 12 capacitive touch electrodes, MP3/WAV/MIDI audio, and now WiFi, Bluetooth LE, USB-C, a proper LiPo power path, a fuel gauge, line-in, MIDI out, Qwiic and an RGB LED.

    185 parts
  • 4 layers50 × 70 mmRp569, the printed circuit board in 3D

    Rp569

    kelu124/rp569

    RP569 - PIOs to usb3 ( rp2350 x ch569 )

    146 parts3
  • 4 layers25 × 74 mmPTR mini pcb, the printed circuit board in 3D

    PTR mini pcb

    PTR-projects/PTR_mini_hardware

    Welcome to the KPPTR-hardware repository! This repository contains the design files for the hardware components used in the KPPTR project.

    140 parts1MIT
  • 6 layers104 × 104 mmFC REV A, the printed circuit board in 3D

    FC REV A

    desanv01/Flight-Controller-V1

    STM32H743 flight controller: staged design, six-layer PCB implementation, manufacturing data and engineering history.

    330 parts

Questions

How big is the Sensor HAT PCB?

It measures 65 × 56 mm and has 4 copper layers, 1.6 mm thick.

What parts does the Sensor HAT use?

112 parts, built around the SN74LV1T125DBVR-TP, SGP41-D-R4, SHT40-AD1B-R2 and VEML7700-TT. 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 Sensor HAT KiCad files?

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

Can I use the Sensor HAT design in my own project?

Its repository states no licence, so its author keeps all rights: ask Eniemooo before reusing the design.