Skip to the content
PCBKitNew board
2 layers100 × 100 mmSensor hub, the printed circuit board in 3D

Outdoor environmental monitoring system built on a Raspberry Pi Pico W. Sensors are read every 30 minutes, uploaded over WiFi to a FastAPI server running on a Raspberry Pi, and displayed in a browser dashboard.

Size
100 × 100 mm
Copper layers
2
Thickness
1.6 mm
Parts
64
Nets
57
Pads
246
Tracks, vias
691, 47
Pours
8
Routed
Yes
KiCad
KiCad 10.0 (file 20260206)
Created
14 May 2026
Updated
30 Sep 2026

Overview

Sensor hub is an open-source printed circuit board by CustomStuffs, from the CustomStuffs/sensor-projekt-V2 repository on GitHub. It is a 2-layer board of 100 × 100 mm with 64 parts on 57 nets, routed with 691 tracks and 47 vias.

It is built around the ADS1115IDGSR, VEML7700-TT and AD8603AUJZ-R2, with the AP2112K-3.3TRG1, 1N4148W and BC817-40 among its other parts. Its parts include 17 capacitors, 14 resistors, 11 connectors, 5 ICs and 3 diodes. It belongs with the sensors and measurement boards and the RP2040 boards of this library.

Main components

7

README

README.md

Sensor Hub

Outdoor environmental monitoring system built on a Raspberry Pi Pico W. Sensors are read every 30 minutes, uploaded over WiFi to a FastAPI server running on a Raspberry Pi, and displayed in a browser dashboard.

System overview

text
Pico W (MicroPython)
  └─ POST JSON ──► RPi FastAPI server (port 8080)
                      └─ SQLite DB
                      └─ Static files ──► Browser dashboard

Remote access via Tailscale VPN — no port forwarding, no auth layer needed.

Sensors

SensorChip / interfaceBoard connectionMeasures
TemperatureDS18B20, 1-Wire (GP8)W1 (J2)°C
HumidityDHT22, GP9W2 (J3)% RH + °C fallback
pHAD8603 buffer → ADS1115 AIN0 (I2C, GP2/3)BNC (J1), guarded inputpH 0–14
LightVEML7700, I2C (GP2/3)on the board, under a light pipe to the lidlux
Soil moistureCapacitive, Pico ADC (GP26)J11 solder holes (GP26–28)%
MotionPIR, GP11 (also wake IRQ), power-gated by GP12W3 (J4)boolean
Water levelFloat switch, GP16W4 (J5)float
Probe temperatureNTC → ADS1115 AIN1J8 pins 3/4°C (for compensation)
ECnot on the v1 board (LMP91200 is EOL; firmware driver exists, keep ec disabled)—µS/cm

All sensor fields are nullable — unconnected sensors send null.

Relays (two on-board channels)

The PCB carries two independent SPDT relays (K1 on GP10, K2 on GP15), rated 230 VAC / 5 A with reinforced insulation to the sensor side, as a hard minimum. Both relays can be switched and scheduled from the dashboard, and local sensor rules can target either one ("relay": 2 in a rule; default is relay 1). This allows two simultaneous actuator channels (e.g. pump + valve) without external modules. Future board variants can add more relays.

  • Auto rules: threshold-based (e.g. water when soil < 30 %) configured in firmware/src/config.json
  • Schedule: time-based rules, also in config.json
  • Manual override: one-click from the dashboard, queued via server command API

Repo layout

text
firmware/   MicroPython source + flash/dev tools
server/     FastAPI app, SQLite schema, systemd unit
dashboard/  Vanilla HTML/JS/CSS frontend
hardware/   KiCad project + generation scripts, BOM, JLCPCB order files

Each folder has its own CLAUDE.md with subproject-specific rules.

Getting started

Firmware

Requires MicroPython 1.28+ (RPI_PICO_W build).

bash
cd firmware
bash tools/setup.sh          # install mpremote, check device
cp src/config.json.example src/config.json   # fill in WiFi + server URL
bash tools/flash.sh          # copy all files to device
bash tools/monitor.sh        # watch serial output

For daily development, use the mount workflow instead of reflashing:

bash
bash tools/mount.sh   # edits in src/ take effect on Ctrl-D

Server

bash
cd server
pip install -r requirements.txt
uvicorn api.main:app --host 0.0.0.0 --port 8080

Or run as a systemd service:

bash
sudo cp sensor_hub.service /etc/systemd/system/
sudo systemctl enable --now sensor_hub

Dashboard

Served as static files by the FastAPI server — no build step. Open http://<pi-ip>:8080 in a browser.

Hardware

100 × 100 mm, 2-layer PCB (hardware/kicad/), generated and routed by the scripts in hardware/tools/. JLCPCB fabricates the board and places all SMD parts (hardware/fab/, regenerate with python3 hardware/tools/jlc_export.py); the through-hole parts — Pico WH sockets, relays, Wago push-in terminals, BNC, X2 capacitors, UART header — are hand-soldered. Details: hardware/CLAUDE.md and hardware/docs/.

Pico W hardware notes

  • VSYS ADC: use ADC(29) (GPIO29), not ADC(3). On Pico W, GPIO29 is the VSYS/3 voltage divider. ADC(3) reads GPIO3 (I2C SCL) and gives garbage.
  • VSYS measurement timing: read VSYS before wlan.active(True) — GPIO29 is shared with the WiFi SPI bus and returns wrong values while the radio is up.
  • Lightsleep after WiFi: machine.lightsleep(ms) can fail silently on Pico W after WiFi use. The firmware falls back to time.sleep() automatically and logs when this happens.
  • Serial monitor: uses mpremote (bash tools/monitor.sh), not minicom. On immutable distros (Bazzite/Silverblue), minicom is not available.
  • Flashing: the device enters lightsleep ~30 s after boot, making mpremote unreachable. Flash immediately after plugging in USB, or interrupt via REPL first.

Power budget (battery operation)

StateCurrent
Lightsleep0.30 mA
Sensing (all sensors)25 mA
WiFi active80 mA
Average (30 min cycle)~1.2 mA

A 10 000 mAh power bank lasts roughly 6–11 months.

License

MIT

Parts

64
QtyValueFootprintReferences
9100nFCapacitor_SMD:C_0603_1608MetricC1, C2, C6, C7, C8, C9, C10, C11, C12
410kResistor_SMD:R_0603_1608MetricR6, R7, R9, R17
410uFCapacitor_SMD:C_0805_2012MetricC13, C14, C15, C16
4MountingHole_3.2mm_M3MountingHole:MountingHole_3.2mm_M3H1, H2, H3, H4
34k7Resistor_SMD:R_0603_1608MetricR5, R10, R11
3MountingHole_2.2mm_M2MountingHole:MountingHole_2.2mm_M2H5, H6, H7
2100RResistor_SMD:R_1206_3216MetricR19, R20
2100kResistor_SMD:R_0603_1608MetricR2, R3
2100nF X2 275VACCapacitor_THT:C_Rect_L13.0mm_W6.0mm_P10.00mm_FKS3_FKP3_MKS4C19, C20
21N4148WDiode_SMD:D_SOD-123D2, D3
21kResistor_SMD:R_0603_1608MetricR8, R18
21uFCapacitor_SMD:C_0603_1608MetricC17, C18
2BC817-40Package_TO_SOT_SMD:SOT-23Q1, Q3
2G2RL-1-E DC5Relay_THT:Relay_SPDT_Omron_G2RL-1-EK1, K2
11-1478035-0Connector_Coaxial:BNC_TEConnectivity_1478035_HorizontalJ1
110MResistor_SMD:R_0603_1608MetricR1
1AD8603AUJZPackage_TO_SOT_SMD:TSOT-23-5U4
1ADS1115IDGSRPackage_SO:MSOP-10_3x3mm_P0.5mmU2
1AP2112K-3.3TRG1Package_TO_SOT_SMD:SOT-23-5U5
1BAV99Package_TO_SOT_SMD:SOT-23D1
1BSS84PXUMA1Package_TO_SOT_SMD:SOT-23Q2
1Debug-UARTConnector_PinHeader_2.54mm:PinHeader_1x04_P2.54mm_VerticalHDR1
1NetTie_2NetTie:NetTie-2_SMD_Pad0.5mmNT1
1Pico WHModule:RaspberryPi_Pico_Common_THTU1
1Spare-GPIOConnector_PinHeader_2.54mm:PinHeader_2x08_P2.54mm_VerticalJ11
1VEML7700-TTsensor_hub:VEML7700_TTU6
1Wago-DHT22TerminalBlock_WAGO:TerminalBlock_WAGO_2601-1103_1x03_P3.50mm_HorizontalJ3
1Wago-DS18B20TerminalBlock_WAGO:TerminalBlock_WAGO_2601-1103_1x03_P3.50mm_HorizontalJ2
1Wago-EC4pinTerminalBlock_WAGO:TerminalBlock_WAGO_2601-1104_1x04_P3.50mm_HorizontalJ8
1Wago-GP16TerminalBlock_WAGO:TerminalBlock_WAGO_2601-1103_1x03_P3.50mm_HorizontalJ5
1Wago-GP17TerminalBlock_WAGO:TerminalBlock_WAGO_2601-1103_1x03_P3.50mm_HorizontalJ6
1Wago-PIRTerminalBlock_WAGO:TerminalBlock_WAGO_2601-1103_1x03_P3.50mm_HorizontalJ4
1Wago-PowerTerminalBlock_WAGO:TerminalBlock_WAGO_2601-1102_1x02_P3.50mm_HorizontalJ9
1Wago-Relay1TerminalBlock_WAGO:TerminalBlock_WAGO_236-403_1x03_P5.00mm_45DegreeJ7
1Wago-Relay2TerminalBlock_WAGO:TerminalBlock_WAGO_236-403_1x03_P5.00mm_45DegreeJ10

Questions

How big is the Sensor hub PCB?

It measures 100 × 100 mm and has 2 copper layers, 1.6 mm thick.

What parts does the Sensor hub use?

64 parts, built around the ADS1115IDGSR, VEML7700-TT, AD8603AUJZ-R2 and AP2112K-3.3TRG1. 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 hub KiCad files?

From the CustomStuffs/sensor-projekt-V2 repository on GitHub, at the commit this page was made from: the board is hardware/kicad/sensor_hub.kicad_pcb and its schematic PCB/V1 pico sensorhub/V1 pico sensorhub.kicad_sch. PCBKit opens the board in the browser, with nothing to install.

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

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

Similar boards

  • 2 layers65 × 56 mmLogHeat, the printed circuit board in 3D

    LogHeat

    IfTrueEqualsEqualsTrue/LogHeat

    This project is a temperature logging system developed during the 2024 Biomedical Engineering Master Class at Grenoble INP.

    33 parts2
  • 4 layers148 × 74 mmDevice, the printed circuit board in 3D

    Device

    jayis1/hardware-design-lab

    Full-cycle hardware device designs — each device in its own subfolder with architecture, schematics, PCB layout, and software stack

    21 parts
  • 4 layers65 × 56 mmSensor HAT, the printed circuit board in 3D

    Sensor HAT

    Eniemooo/Sensor-HAT

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

    112 parts
  • 4 layers173.2 × 52.5 mmCanSat, the printed circuit board in 3D

    CanSat

    budabalint/T.E.E.M.O

    442 parts
  • 2 layers87 × 30.8 mmEbus2usb, the printed circuit board in 3D

    Ebus2usb

    jkyprian/ebus2usb

    1TE DIN Rail eBus to USB Type-C Adapter

    59 parts10
  • 4 layers120 × 76 mmPanel, the printed circuit board in 3D

    Panel

    vbartusevicius/weather-station

    Open-source rooftop weather and air-quality station with no moving parts (Ø 96 × 235 mm, UV-stabilised ASA): ultrasonic wind, acoustic rain and hail, UV / sunlight / night-sky brightness, temperature, humidity…

    235 parts
  • 4 layers200 × 216 mmIntegrated, the printed circuit board in 3D

    Integrated

    KarpelesLab/ledger_implant_detector

    A small hand-held tool for spotting extra conductive structures hidden inside the plastic shell of a hardware wallet (e.g. a Ledger).

    101 parts