# Raspberry Pi Aquarium Controller HAT

## Description

Raspberry Pi 4 HAT for a freshwater planted aquarium controller, with 5 V/3 A input, I2C module sockets, 1\-Wire and leak sensors, PWM MOSFET LED outputs, and an isolated feeder trigger\.

## Project Details

- **Owner:** daveww00
- **Created:** 9/3/2026
- **Last Updated:** 9/3/2026
- **Visibility:** Public

## Key Components

### D1 — [SMAJ5\.0A\-Q](https://flux.ai/lcsc/smaj5p0a-q~a86n.md)

- Role: Surge Protection
- Package or Case Code: SMA\_L4\.4\-W2\.8\-LS5\.1\-RD
- Manufacturer Part Number: SMAJ5\.0A\-Q
- Manufacturer Name: BOURNS
- Voltage Rating: 5V
- Functional Group: 5 V input/protection and Pi header
- Role Details: Unidirectional 5V TVS shunt on protected rail
- License: https://creativecommons\.org/licenses/by/4\.0/
- Part Type: TVS
- LCSC Part Number: C1869355
- Datasheet URL: https://www\.lcsc\.com/datasheet/C1869355\.pdf?spm=wm\.sxq\.inf\.ggs&lcsc\_vid=T1kIXgFeT1NaU1RXQFBbUlUHT1cKU1NXFVBeX1VSTlAxVlNeR1VeUVFRTlBbUzsOAxUeFF5JWBYZEEoKFBINSQcJGk4dAgUUFAk%3D

**Pins:**
- A [pin 2]
- C [pin 1]

### D2 — [PESD5V0S1BB,115](https://flux.ai/silicon-yard/pesd5v0s1bbc115~8w.md)

- Datasheet URL: https://assets\.nexperia\.com/documents/data\-sheet/PESD5V0S1BB\.pdf
- Manufacturer Part Number: PESD5V0S1BB,115
- Role: ESD Protection
- Part Type: Diode
- Manufacturer Name: Nexperia USA Inc\.
- Role Details: 5V\-standoff bidirectional ESD clamp on probe\-side data
- Functional Group: Wired sensors
- License: https://creativecommons\.org/licenses/by/4\.0/

**Pins:**
- A1 [pin 1]
- A2 [pin 2]

### D3 — [PESD5V0S1BB,115](https://flux.ai/silicon-yard/pesd5v0s1bbc115~8w.md)

- Datasheet URL: https://assets\.nexperia\.com/documents/data\-sheet/PESD5V0S1BB\.pdf
- Manufacturer Part Number: PESD5V0S1BB,115
- Role: ESD Protection
- Part Type: Diode
- Manufacturer Name: Nexperia USA Inc\.
- Role Details: 5V\-standoff ESD clamp on leak 1 connector signal
- Functional Group: Wired sensors
- License: https://creativecommons\.org/licenses/by/4\.0/

**Pins:**
- A1 [pin 1]
- A2 [pin 2]

### D4 — [PESD5V0S1BB,115](https://flux.ai/silicon-yard/pesd5v0s1bbc115~8w.md)

- Role Details: 5V\-standoff ESD clamp on leak 2 connector signal
- Role: ESD Protection
- Datasheet URL: https://assets\.nexperia\.com/documents/data\-sheet/PESD5V0S1BB\.pdf
- Manufacturer Part Number: PESD5V0S1BB,115
- Part Type: Diode
- Manufacturer Name: Nexperia USA Inc\.
- License: https://creativecommons\.org/licenses/by/4\.0/
- Functional Group: Wired sensors

**Pins:**
- A1 [pin 1]
- A2 [pin 2]

### D5 — [SM6T15A](https://flux.ai/jecstronic/sm6t15a~kvy.md)

- Functional Group: LED MOSFET outputs
- Part Type: Diode
- Role: Surge Protection
- Role Details: 15V unidirectional 600W TVS across \+12V\_LED and GND
- Voltage Rating: 15V
- Manufacturer Name: STMicroelectronics
- Manufacturer Part Number: SM6T15A
- Datasheet URL: https://www\.mouser\.com/datasheet/2/389/sm6t100a\-1916590\.pdf
- License: https://creativecommons\.org/licenses/by/4\.0/

**Pins:**
- A [pin 2]
- K [pin 1]

### F1 — [0451004\.MRL](https://flux.ai/adrian95/0451004pmrl~edp.md)

- Part Type: Fuse
- Manufacturer Part Number: 0451004\.MRL
- Functional Group: 5 V input/protection and Pi header
- Manufacturer Name: Littelfuse Inc\.
- Role Details: 4A low\-loss fuse sized above 3A continuous input target; no series diode
- Role: Overcurrent Protection
- Voltage Rating: 125V
- Datasheet URL: https://www\.littelfuse\.com/assetdocs/littelfuse\-fuse\-451\-453\-datasheet?assetguid=533cd5cc\-956c\-4243\-867f\-6ab5a62f6ba1
- Current Rating: 4A
- License: https://creativecommons\.org/licenses/by/4\.0/

**Pins:**
- P1 [pin 1]
- P2 [pin 2]

### J1 — [Pin Socket 02x20 2\.54mm](https://flux.ai/vasyl/pin-socket-02x20-254mm~nhe.md)

- Connector Gender: Female
- Part Type: Connector
- Connector Positions: 40
- Functional Group: 5 V input/protection and Pi header
- Role: Host Interface
- Connector Rows: 2
- Connector Pitch: 2\.54mm
- Role Details: Raspberry Pi 40\-pin female socket; physical header numbering 1\-40

**Pins:**
- Pin\_1 [pin 1]
- Pin\_10 [pin 10]
- Pin\_11 [pin 11]
- Pin\_12 [pin 12]
- Pin\_13 [pin 13]
- Pin\_14 [pin 14]
- Pin\_15 [pin 15]
- Pin\_16 [pin 16]
- Pin\_17 [pin 17]
- Pin\_18 [pin 18]
- Pin\_19 [pin 19]
- Pin\_2 [pin 2]
- Pin\_20 [pin 20]
- Pin\_21 [pin 21]
- Pin\_22 [pin 22]
- Pin\_23 [pin 23]
- Pin\_24 [pin 24]
- Pin\_25 [pin 25]
- Pin\_26 [pin 26]
- Pin\_27 [pin 27]
- Pin\_28 [pin 28]
- Pin\_29 [pin 29]
- Pin\_3 [pin 3]
- Pin\_30 [pin 30]
- Pin\_31 [pin 31]
- Pin\_32 [pin 32]
- Pin\_33 [pin 33]
- Pin\_34 [pin 34]
- Pin\_35 [pin 35]
- Pin\_36 [pin 36]
- Pin\_37 [pin 37]
- Pin\_38 [pin 38]
- Pin\_39 [pin 39]
- Pin\_4 [pin 4]
- Pin\_40 [pin 40]
- Pin\_5 [pin 5]
- Pin\_6 [pin 6]
- Pin\_7 [pin 7]
- Pin\_8 [pin 8]
- Pin\_9 [pin 9]

### J10 — [Pin Socket 01x04 2\.54mm Vertical](https://flux.ai/adrian95/pin-socket-01x04-254mm-vertical~kks.md)

- License: https://creativecommons\.org/licenses/by/4\.0/
- Role: Display Interface
- Part Type: Connector
- Role Details: Winstar WEA012864D\-03 order: 1 VCC, 2 GND, 3 SCL, 4 SDA; powered at 3\.3V
- Functional Group: I2C module sockets
- Connector Gender: Female

**Pins:**
- Pin\_1 [pin 1]
- Pin\_2 [pin 2]
- Pin\_3 [pin 3]
- Pin\_4 [pin 4]

### J11 — [Pin Socket 01x03 2\.54mm Vertical](https://flux.ai/adrian95/pin-socket-01x03-254mm-vertical~tj7.md)

- Connector Gender: Female
- Functional Group: Wired sensors
- Part Type: Connector
- License: https://creativecommons\.org/licenses/by/4\.0/
- Role Details: Pin 1 3V3, pin 2 1\-Wire data, pin 3 GND; GPIO4
- Role: Temperature Probe Interface

**Pins:**
- Pin\_1 [pin 1]
- Pin\_2 [pin 2]
- Pin\_3 [pin 3]

### J12 — [Pin Socket 01x02 2\.54mm Vertical](https://flux.ai/adrian95/pin-socket-01x02-254mm-vertical~k8w.md)

- Role: Leak Sensor Interface
- Part Type: Connector
- Functional Group: Wired sensors
- License: https://creativecommons\.org/licenses/by/4\.0/
- Role Details: Pin 1 protected GPIO22 input, pin 2 GND; contact closure active

**Pins:**
- Pin\_1 [pin 1]
- Pin\_2 [pin 2]

### J13 — [Pin Socket 01x02 2\.54mm Vertical](https://flux.ai/adrian95/pin-socket-01x02-254mm-vertical~k8w.md)

- Part Type: Connector
- License: https://creativecommons\.org/licenses/by/4\.0/
- Role Details: Pin 1 protected GPIO23 input, pin 2 GND; contact closure active
- Role: Leak Sensor Interface
- Functional Group: Wired sensors

**Pins:**
- Pin\_1 [pin 1]
- Pin\_2 [pin 2]

### J14 — [1702558](https://flux.ai/silicon-yard/1702558.md)

- Voltage Rating: 400V
- Mount: Through Hole
- Datasheet URL: https://storage\.googleapis\.com/graviton\-electric\-symbols/document\_assets/user\-uploaded/aa8a2052276d2d573541bb1b7705191da19c38ad154e2eb95d82f895f5b72137\.pdf
- License: https://creativecommons\.org/licenses/by/4\.0/
- Role: LED Power and Outputs
- Current Rating: 20A
- Role Details: Pin 1 \+12V\_LED, pin 2 GND return, pins 3\-5 switched drains CH1\-CH3; 2\.5A max each
- Part Type: Connector
- Manufacturer Name: Phoenix Contact
- Manufacturer Part Number: 1702558
- Connector Positions: 5
- Connector Pitch: 5\.08mm
- Functional Group: LED MOSFET outputs
- Symbol Style: parametric\-v1
- Compliance: Green

**Pins:**
- 1 [pin 1]
- 2 [pin 2]
- 3 [pin 3]
- 4 [pin 4]
- 5 [pin 5]

### J15 — [1729128](https://flux.ai/adrian95/1729128~gmm.md)

- Package or Case Code: 1729128
- Manufacturer Name: Phoenix Contact
- Part Type: Connector
- Role: Isolated Output
- Datasheet URL: http://www\.phoenixcontact\.net/product/1729128
- Connector Pitch: 5\.08mm
- Functional Group: Optoisolated feeder output
- License: https://creativecommons\.org/licenses/by/4\.0/
- Role Details: Pin 1 PC817 collector, pin 2 emitter; no connection to board GND
- Manufacturer Part Number: 1729128

**Pins:**
- 1 [pin 1]
- 2 [pin 2]

### J2 — [1715789](https://flux.ai/adrian95/1715789~esl.md)

- Connector Positions: 8
- Functional Group: 5 V input/protection and Pi header
- Datasheet URL: https://www\.phoenixcontact\.com/en\-us/products/printed\-circuit\-board\-terminal\-mkds\-15\-8\-508\-1715789?type=pdf
- Mount: Through Hole
- Manufacturer Part Number: 1715789
- License: https://creativecommons\.org/licenses/by/4\.0/
- Role: Power Distribution
- Part Type: Connector
- Manufacturer Name: Phoenix Contact
- Connector Pitch: 5\.08mm
- Symbol Style: parametric\-v1
- Role Details: Pins 1\-2 \+5V\_RAW input feeding Raspberry Pi 5 V rail through existing F1; pin 3 GPIO5; pin 4 GPIO6; pin 5 GPIO13; pin 6 GPIO19; pins 7\-8 GND; no series diode

**Pins:**
- 1 [pin 1]
- 2 [pin 2]
- 3 [pin 3]
- 4 [pin 4]
- 5 [pin 5]
- 6 [pin 6]
- 7 [pin 7]
- 8 [pin 8]

### J6 — [Pin Socket 01x05 2\.54mm Vertical](https://flux.ai/adrian95/pin-socket-01x05-254mm-vertical~lr1.md)

- Functional Group: I2C module sockets
- Part Type: Connector
- License: https://creativecommons\.org/licenses/by/4\.0/
- Connector Gender: Female
- Symbol Style: parametric\-v1
- Role Details: Board\-defined order: 1 GND, 2 3V3, 3 RX/SCL, 4 TX/SDA, 5 OFF/NC; verify cable orientation to carrier
- Connector Pitch: 2\.54mm
- Role: I2C Module Interface

**Pins:**
- Pin\_1 [pin 1]
- Pin\_2 [pin 2]
- Pin\_3 [pin 3]
- Pin\_4 [pin 4]
- Pin\_5 [pin 5]

### J7 — [Pin Socket 01x06 2\.54mm Vertical](https://flux.ai/adrian95/pin-socket-01x06-254mm-vertical~yiu.md)

- Role: Logic\-level Shifting
- Connector Positions: 6
- Connector Pitch: 2\.54mm
- License: https://creativecommons\.org/licenses/by/4\.0/
- Functional Group: I2C module sockets
- Role Details: PCA module control socket order: 1 GND, 2 \+5V\_PCA\_VCC, 3 SCL\_5V, 4 SDA\_5V, 5 OE/NC, 6 V\+/NC; VCC and V\+ separated
- Connector Gender: Female
- Part Type: Connector

**Pins:**
- Pin\_1 [pin 1]
- Pin\_2 [pin 2]
- Pin\_3 [pin 3]
- Pin\_4 [pin 4]
- Pin\_5 [pin 5]
- Pin\_6 [pin 6]

### J8 — [Pin Socket 01x03 2\.54mm Vertical](https://flux.ai/adrian95/pin-socket-01x03-254mm-vertical~tj7.md)

- Functional Group: I2C module sockets,LED MOSFET outputs
- Role: PWM Signal Interface
- Part Type: Connector
- License: https://creativecommons\.org/licenses/by/4\.0/
- Role Details: Board\-defined order: 1 PWM0, 2 PWM1, 3 PWM2; approximately 5V output logic from PCA VCC

**Pins:**
- Pin\_1 [pin 1]
- Pin\_2 [pin 2]
- Pin\_3 [pin 3]

### J9 — [Pin Socket 01x04 2\.54mm Vertical](https://flux.ai/adrian95/pin-socket-01x04-254mm-vertical~kks.md)

- License: https://creativecommons\.org/licenses/by/4\.0/
- Role: I2C Module Interface
- Connector Gender: Female
- Part Type: Connector
- Functional Group: I2C module sockets
- Role Details: Board\-defined cable order: 1 GND, 2 3V3/Vin, 3 SCL, 4 SDA; module has 10k pull\-ups to Vin

**Pins:**
- Pin\_1 [pin 1]
- Pin\_2 [pin 2]
- Pin\_3 [pin 3]
- Pin\_4 [pin 4]

### Q1 — [AO3400A](https://flux.ai/adrian95/ao3400a~ug9.md)

- Datasheet URL: https://media\.digikey\.com/pdf/Data%20Sheets/Alpha%20&%20Omega/AO3400A\_ds\.pdf
- Manufacturer Part Number: AO3400A
- Role Details: CH1 2\.5A target; approx 36mΩ at \~5V gate, \~0\.225W estimate; thermal copper/ambient verification required
- Role: Low\-Side PWM Switch
- Functional Group: LED MOSFET outputs
- Voltage Rating: 30V
- Manufacturer Name: Alpha & Omega Semiconductor Inc\.
- Current Rating: 2\.5A
- License: https://creativecommons\.org/licenses/by/4\.0/
- Part Type: Transistor

**Pins:**
- D [pin 3]
- G [pin 1]
- S [pin 2]

### Q2 — [AO3400A](https://flux.ai/adrian95/ao3400a~ug9.md)

- Datasheet URL: https://media\.digikey\.com/pdf/Data%20Sheets/Alpha%20&%20Omega/AO3400A\_ds\.pdf
- Manufacturer Part Number: AO3400A
- Current Rating: 2\.5A
- Manufacturer Name: Alpha & Omega Semiconductor Inc\.
- Role Details: CH2 2\.5A target; approx 36mΩ at \~5V gate, \~0\.225W estimate; thermal copper/ambient verification required
- Voltage Rating: 30V
- Functional Group: LED MOSFET outputs
- Role: Low\-Side PWM Switch
- License: https://creativecommons\.org/licenses/by/4\.0/
- Part Type: Transistor

**Pins:**
- D [pin 3]
- G [pin 1]
- S [pin 2]

### Q3 — [AO3400A](https://flux.ai/adrian95/ao3400a~ug9.md)

- Datasheet URL: https://media\.digikey\.com/pdf/Data%20Sheets/Alpha%20&%20Omega/AO3400A\_ds\.pdf
- Manufacturer Part Number: AO3400A
- Role: Low\-Side PWM Switch
- Current Rating: 2\.5A
- Voltage Rating: 30V
- Manufacturer Name: Alpha & Omega Semiconductor Inc\.
- Role Details: CH3 2\.5A target; approx 36mΩ at \~5V gate, \~0\.225W estimate; thermal copper/ambient verification required
- Functional Group: LED MOSFET outputs
- License: https://creativecommons\.org/licenses/by/4\.0/
- Part Type: Transistor

**Pins:**
- D [pin 3]
- G [pin 1]
- S [pin 2]

### Q4 — [BSS138](https://flux.ai/vasy_skral/bss138~3ld.md)

- Datasheet URL: https://www\.onsemi\.com/pdf/datasheet/bss138\-d\.pdf
- Role: Level Shifting
- Manufacturer Part Number: BSS138
- Functional Group: I2C module sockets
- Role Details: BSS138 bidirectional open\-drain SDA level shift, 3\.3V Pi side to 5V PCA side
- Manufacturer Name: onsemi
- Part Type: Transistor

**Pins:**
- D [pin 3]
- G [pin 1]
- S [pin 2]

### Q5 — [BSS138](https://flux.ai/vasy_skral/bss138~3ld.md)

- Datasheet URL: https://www\.onsemi\.com/pdf/datasheet/bss138\-d\.pdf
- Manufacturer Part Number: BSS138
- Functional Group: I2C module sockets
- Manufacturer Name: onsemi
- Role Details: BSS138 bidirectional open\-drain SCL level shift, 3\.3V Pi side to 5V PCA side
- Role: Level Shifting
- Part Type: Transistor

**Pins:**
- D [pin 3]
- G [pin 1]
- S [pin 2]

### U1 — [PC817](https://flux.ai/kicad-part-library/pc817~0c.md)

- Role Details: GPIO17 drives LED at \~4\.9mA through 430Ω; transistor collector/emitter remain isolated
- Datasheet URL: http://www\.soselectronic\.cz/a\_info/resource/d/pc817\.pdf
- Role: Optoisolator
- Functional Group: Optoisolated feeder output
- Package or Case Code: DIP\-4\_W7\.62mm
- Manufacturer Part Number: PC817

**Pins:**
- \~ [pin 1]
- \~ [pin 3]
- \~ [pin 2]
- \~ [pin 4]

*The full schematic, PCB layout, bill of materials, and interactive design are available at [https://flux\.ai/daveww00/raspberry\-pi\-aquarium\-controller\-hat\~c8](https://flux.ai/daveww00/raspberry-pi-aquarium-controller-hat~c8).*

---

*Generated from [https://flux\.ai/daveww00/raspberry\-pi\-aquarium\-controller\-hat\~c8](https://flux.ai/daveww00/raspberry-pi-aquarium-controller-hat~c8)*