Community project
Multi-Rail Battery Power Board
Badis Bouchama
Published July 25, 2026 · Updated July 25, 2026

The Multi-Rail Battery Power Board is a comprehensive power distribution system built around the TI BQ25798 buck-boost charger, delivering regulated 5 V and 3.3 V rails from a 12 V Li-ion battery pack while managing field input, reverse polarity protection, and thermal monitoring. An ESP32-S3 controller monitors charger status and battery health via I2C telemetry, enabling intelligent power sequencing and fault detection across the entire system.
This guide provides a complete wiring diagram, detailed parts list, staged assembly instructions, and controller firmware to build a robust multi-rail UPS suitable for remote or mission-critical applications. Readers will learn how to integrate battery charging, ideal-diode protection, pre-regulation, and dual buck converters into a single cohesive power architecture, with step-by-step power-up procedures and diagnostic test points for validation.
Wiring diagram
Interactive · read-only
Pan and zoom to explore the wiring. Remix the project to edit it in your own workspace.
Parts list
Bill of materials| Component | Qty | Notes |
|---|---|---|
| TI BQ25798 NVDC Buck-Boost Battery Charger / Power PathBQ25798 | 1 | 3S NVDC charger and uninterrupted power-path controller. J10 exports 3.3 V I2C, INT, PG/STAT, and active-low charge enable to the off-board ESP32 controller. |
| 7 A Input Protection and EMI Filter7 A / 36 V max input block | 1 | Field-input fuse, surge/EMI protection and filtering for 9–36 V DC. The 7 A fuse is a protection component, not a 90 W-at-9 V rating claim; final fuse curve, harness and thermal validation are required. |
| SGM25730 Ideal-Diode Reverse-Polarity StageSGM25730 + AON6512 | 1 | SGM25730 ideal-diode controller with AON6512 N-channel MOSFET, creating the low-loss reverse-polarity protection stage after the EMI filter. |
| SC8701 18 V Pre-Regulator18 V regulated output | 1 | Southchip SC8701 synchronous buck-boost pre-regulator. Receives the protected 9–36 V field input and provides a regulated 18 V charger-input rail. Inductor, compensation network, switching capacitors, and programmed current limit require verification from the selected SC8701 datasheet/reference design before PCB release. |
| 12 V Rechargeable Li-ion Battery Pack with Built-In BMS3S1P 18650, 3.5 Ah, 11.1 V nominal, BMS; 5 A continuous / 10 A pulse discharge; 3 A max charge | 1 | User-specified 3S1P pack: three 18650 3500 mAh cells, 11.1 V nominal / 12.6 V charge cutoff, 8.25 V ±1 V discharge cutoff. Built-in BMS is specified to protect against overcharge, over-discharge, over-current, and external short circuit. Limits: 5 A continuous discharge, 10 A pulse discharge, 3 A maximum charge. Pack size 70 × 38 × 38 mm; mass 188 g. The BQ25798 configuration must remain at or below 4.5 A continuous battery discharge and 3 A charge, subject to final pack/BMS and thermal validation. |
| SGM6132 5.0 V / 3 A Buck Rail5.0 V / 3 A | 1 | U3 downstream buck regulator providing the 5 V auxiliary rail for the display supply and isolated-interface converters. Final inductor, feedback resistors, input/output capacitors, thermal layout, and load-current budget must follow the verified SGM6132 application circuit. |
| SGM6132 3.3 V / 3 A Logic Buck Rail3.3 V / 3 A | 1 | U5 downstream buck regulator providing the board’s 3.3 V logic rail. It feeds the downstream controller board, storage/network logic and low-voltage interface side; the detachable ESP32-S3 service board remains USB powered during bring-up. |
| 5 V Auxiliary Rail Distribution5.0 V / 3 A | 1 | Board output distribution for the 5.0 V / 3 A auxiliary rail. It feeds external display and isolated-interface assemblies, which are intentionally outside this power-board project. |
| 3.3 V Logic Rail Distribution3.3 V / 3 A | 1 | Board output distribution for the downstream 3.3 V logic domain: separate controller board, MicroSD, W5500 logic, RTC, ADM2483 logic side, and SGM4553 VCCA. Those loads remain outside this power-board project. |
| J1 Field Input Terminal2-pin 3.81 mm, 10 A | 1 | 2-pin 3.81 mm locking terminal block, 10 A rated. Field 12–24 V DC input connector. |
| J2A Battery Connector2-pin JST XH, 2.54 mm | 1 | 2-pin JST XH battery power connector for protected 3S Li-ion pack leads. |
| J2B Battery NTC Connector2-pin JST PH, 2.0 mm | 1 | 2-pin JST PH connector for the 10 kΩ NTC lead from the 3S battery pack to BQ25798 TS. |
| J3 Universal Power Distribution Connector6-position 2.54 mm connector; parallel SYS_BUS/GND contacts | 1 | Six-position distribution interface: 5 V, two parallel SYS_BUS contacts, 3.3 V, and two parallel ground contacts. SYS_BUS is the battery-backed 3S-class rail only (8.25–12.6 V), never 18 V. Parallel-contact current sharing requires final connector, terminal, harness, and PCB-copper validation. |
| J10 Telemetry and Control Harness7-position 2.54 mm telemetry/control connector | 1 | Seven-position 3.3 V telemetry/control interface for the external controller. It intentionally contains no cellular or filament PWM signals. |
| J10 ESD, Backfeed and Signal ProtectionB130WS-class blocking stage + ESD arrays + I2C pull-ups + 3×470 ohm | 1 | Protection and bias boundary for the seven-pin telemetry/control harness: diode-isolated 3.3 V output, ESD protection, local I2C pull-ups, and 470 ohm series protection on INT, STAT, and CE. No filament PWM paths are included. |
| Universal UPS Bring-Up Test Point and Grounding Provision SetTP1–TP7 + 4× grounded M3 mounting holes | 1 | Top-side SMD test pads for protected field input, 18V_PRE, SYS_BUS, 5V_AUX, 3V3_LOGIC, ground, and SC8701 switching node, plus four grounded M3 mounting holes. GSM/cellular test points are intentionally omitted. |
| Five-Rail Hardware Diagnostic LED Bank5×0603 LED plus five series resistors | 1 | Five 0603 rail-presence indicators for VIN_FIELD, 18V_PRE, SYS_BUS, 5V_AUX, and 3V3_LOGIC. Each LED includes its own correctly rated series resistor; values are selected during schematic capture for the rail voltage and desired indicator current. |
| Resistor10 kΩ, 0805, ≥0.25 W | 1 | Through-hole resistor (current-limiting in series with an LED) |
| Resistor8.2 kΩ, 0805, ≥0.125 W | 1 | Through-hole resistor (current-limiting in series with an LED) |
| Resistor4.7 kΩ, 0805, ≥0.125 W | 1 | Through-hole resistor (current-limiting in series with an LED) |
| Resistor1.5 kΩ, 0805, ≥0.125 W | 1 | Through-hole resistor (current-limiting in series with an LED) |
| Resistor680 Ω, 0805, ≥0.125 W | 1 | Through-hole resistor (current-limiting in series with an LED) |
Assembly
7 stepsConfirm the separated project scope
Build this board only for the 3S UPS, 5 V rail, 3.3 V rail, J3 distribution, and J10 telemetry/control functions. Do not fit cellular-modem power parts, filament LED driver parts, PWM wiring, or a PCB-mounted master switch in this revision.
- Tip: Keep the 18V_PRE and SYS_BUS labels distinct throughout schematic capture and assembly.
- ⚠ 18V_PRE is mains-only charger input. SYS_BUS is the battery-backed 8.25–12.6 V rail; never connect 18 V to J3 SYS_BUS.
Install and inspect the field-input path
Fit J1, the input-protection/EMI stage, ideal-diode stage, and SC8701 pre-regulator in power-flow order. Observe polarized TVS, electrolytic capacitors, MOSFET orientation, and all inductor markings.
- Tip: Keep high-current and switching loops short during PCB layout and verify all footprints against final manufacturer data.
- ⚠ Do not energize the board until the final input fuse, field wiring, and connector ratings are reconciled with the chosen input range and power rating.
Install the battery and charger section
Fit the BQ25798 support circuit exactly from the verified reference design. Connect J2A directly to the protected 3S1P 18650 battery pack: PACK+ to BAT+ and PACK- to BAT-. The specified pack is 3.5 Ah, 11.1 V nominal, 12.6 V charge cutoff, 5 A continuous discharge, 10 A pulse discharge, and 3 A maximum charge, with a built-in BMS. Connect J2B only if the pack provides the required 10 kΩ NTC lead.
- Tip: Check battery and NTC connector pin order before attachment.
- Tip: Keep BQ25798 battery-discharge configuration at or below the pack’s 5 A continuous rating; the current architecture target remains 4.5 A continuous.
- Tip: There is no battery kill jumper or PCB battery-disconnect jumper in this revision.
- ⚠ Never short BAT+ to ground.
- ⚠ Do not exceed the specified 3 A maximum battery charge current without an actual pack/cell manufacturer approval and thermal validation.
- ⚠ The supplied pack specification must be confirmed against the exact purchased pack and its wiring before use.
Install the downstream rails and J3
Fit the 5 V and 3.3 V buck stages and connect them to J3. J3 pins 2 and 3 are parallel SYS_BUS contacts; pins 5 and 6 are parallel returns.
- Tip: Use matched harness conductors and verify terminal/current derating before relying on the parallel contacts for high current.
- ⚠ Do not inject external power into J3 rails without a separately reviewed power-path design.
Install J10 protection and controller harness
Fit the J10 protection/bias network and connect the seven-pin harness: 3.3 V, GND, SDA, SCL, BQ_INT, BQ_STAT, BQ_CE. Connect it to the external ESP32-S3 controller only after pin order is checked end-to-end.
- Tip: The controller firmware keeps BQ_INT and BQ_STAT high impedance with no internal pull-ups.
- ⚠ Do not connect legacy 10-pin PWM/cellular harnesses to this seven-pin interface.
Fit diagnostics and test pads
Fit the five rail-present LEDs with one dedicated series resistor per LED: LED1 VIN_OK uses led_r_vin_1 (10 kΩ, 0805, at least 0.25 W); LED2 18V_PRE_OK uses led_r_18v_1 (8.2 kΩ); LED3 SYS_BUS_OK uses led_r_sys_1 (4.7 kΩ); LED4 5V_OK uses led_r_5v_1 (1.5 kΩ); and LED5 3V3_OK uses led_r_3v3_1 (680 Ω). Fit TP1–TP7 and the grounded M3 mounting provisions.
- Tip: LED1’s 10 kΩ resistor is sized for the field-input domain and must be at least 0.25 W at a 36 V input.
- Tip: Keep every resistor physically in series between its named rail and the corresponding LED-bank input.
- ⚠ Do not substitute one common resistor value across 3.3 V, 5 V, 12.6 V, 18 V, and field-input rails.
- ⚠ Confirm LED polarity and the selected LED forward voltage before fabrication.
Perform staged power-up
Begin with a current-limited field supply and no battery. Verify VIN_FIELD, 18V_PRE, SYS_BUS, 5V_AUX, and 3V3_LOGIC at the labeled test pads. Then add the battery, verify charge behavior and seamless field-loss operation, and finally attach intended J3/J10 loads.
- Tip: Record input current, rail voltages, temperature, and BQ25798 status at each stage.
- ⚠ Do not claim 90 W operation until the final fuse, input wiring, thermal behavior, BQ25798 configuration, and load/charge allocation have been validated.
Pin assignments
Board wiring reference| Pin | Connection | Type |
|---|---|---|
| EXT | j1_field_terminal VIN+ → 7 A Input Protection and EMI Filter VIN | power |
| GND | j1_field_terminal GND- | ground |
| EXT | input_protection_1 VPROT → SGM25730 Ideal-Diode Reverse-Polarity Stage VIN | power |
| GND | input_protection_1 GND | ground |
| EXT | ideal_diode_1 VOUT → SC8701 18 V Pre-Regulator VIN | power |
| GND | ideal_diode_1 GND | ground |
| EXT | preregulator_1 VOUT → TI BQ25798 NVDC Buck-Boost Battery Charger / Power Path VBUS | power |
| GND | preregulator_1 GND | ground |
| EXT | battery_3s_1 PACK+ → J2A Battery Connector BAT+ | power |
| EXT | battery_3s_1 PACK- → J2A Battery Connector BAT- | ground |
| EXT | j2a_battery BAT+ → TI BQ25798 NVDC Buck-Boost Battery Charger / Power Path BAT | power |
| GND | j2a_battery BAT- | ground |
| EXT | j2b_ntc NTC_TS → TI BQ25798 NVDC Buck-Boost Battery Charger / Power Path TS | analog |
| GND | j2b_ntc NTC_GND | ground |
| GND | bq25798_1 GND | ground |
| EXT | bq25798_1 SDA → J10 ESD, Backfeed and Signal Protection SDA_BQ | i2c |
| EXT | j10_interface_protection_1 SDA_J10 → J10 Telemetry and Control Harness I2C_SDA | i2c |
| EXT | bq25798_1 SCL → J10 ESD, Backfeed and Signal Protection SCL_BQ | i2c |
| EXT | j10_interface_protection_1 SCL_J10 → J10 Telemetry and Control Harness I2C_SCL | i2c |
| EXT | bq25798_1 INT → J10 ESD, Backfeed and Signal Protection INT_BQ | digital |
| EXT | j10_interface_protection_1 INT_J10 → J10 Telemetry and Control Harness BQ_INT | digital |
| EXT | bq25798_1 PG → J10 ESD, Backfeed and Signal Protection STAT_BQ | digital |
| EXT | j10_interface_protection_1 STAT_J10 → J10 Telemetry and Control Harness BQ_STAT | digital |
| EXT | j10_telemetry BQ_CE → J10 ESD, Backfeed and Signal Protection CE_J10 | digital |
| EXT | j10_interface_protection_1 CE_BQ → TI BQ25798 NVDC Buck-Boost Battery Charger / Power Path CE | digital |
| EXT | bq25798_1 SYS → SGM6132 5.0 V / 3 A Buck Rail VIN | power |
| EXT | bq25798_1 SYS → SGM6132 3.3 V / 3 A Logic Buck Rail VIN | power |
| EXT | bq25798_1 SYS → J3 Universal Power Distribution Connector SYS_BUS_A | power |
| EXT | bq25798_1 SYS → J3 Universal Power Distribution Connector SYS_BUS_B | power |
| EXT | buck_5v_1 VOUT → 5 V Auxiliary Rail Distribution VIN | power |
| GND | buck_5v_1 GND | ground |
| EXT | rail_5v_output_1 VIN → J3 Universal Power Distribution Connector 5V_AUX | power |
| GND | rail_5v_output_1 GND | ground |
| EXT | buck_logic_1 VOUT → 3.3 V Logic Rail Distribution VIN | power |
| EXT | buck_logic_1 VOUT → J10 ESD, Backfeed and Signal Protection 3V3_IN | power |
| GND | buck_logic_1 GND | ground |
| EXT | rail_logic_output_1 VIN → J3 Universal Power Distribution Connector 3V3_LOGIC | power |
| GND | rail_logic_output_1 GND | ground |
| EXT | j10_interface_protection_1 3V3_J10 → J10 Telemetry and Control Harness 3V3_LOGIC | power |
| GND | j10_interface_protection_1 GND | ground |
| GND | j10_telemetry GND | ground |
| GND | j3_distribution GND_A | ground |
| GND | j3_distribution GND_B | ground |
| EXT | led_r_vin_1 P1 → 7 A Input Protection and EMI Filter VIN | digital |
| EXT | led_r_vin_1 P2 → Five-Rail Hardware Diagnostic LED Bank VIN_FIELD | digital |
| EXT | led_r_18v_1 P1 → SC8701 18 V Pre-Regulator VOUT | digital |
| EXT | led_r_18v_1 P2 → Five-Rail Hardware Diagnostic LED Bank PRE_18V | digital |
| EXT | led_r_sys_1 P1 → TI BQ25798 NVDC Buck-Boost Battery Charger / Power Path SYS | digital |
| EXT | led_r_sys_1 P2 → Five-Rail Hardware Diagnostic LED Bank SYS_BUS | digital |
| EXT | led_r_5v_1 P1 → SGM6132 5.0 V / 3 A Buck Rail VOUT | digital |
| EXT | led_r_5v_1 P2 → Five-Rail Hardware Diagnostic LED Bank AUX_5V | digital |
| EXT | led_r_3v3_1 P1 → SGM6132 3.3 V / 3 A Logic Buck Rail VOUT | digital |
| EXT | led_r_3v3_1 P2 → Five-Rail Hardware Diagnostic LED Bank LOGIC_3V3 | digital |
| GND | diagnostic_leds_1 GND | ground |
Firmware
ESP32/*
External ESP32-S3 controller for the Universal 3S UPS Power Board.
J10 is a seven-pin telemetry/control harness only:
3.3 V, GND, SDA, SCL, BQ_INT, BQ_STAT, BQ_CE.
Cellular and filament-control functions are intentionally deferred to
separate dedicated-power projects.
*/
#include <Arduino.h>
#include <Wire.h>
constexpr int I2C_SDA_PIN = 8;
constexpr int I2C_SCL_PIN = 9;
constexpr int BQ_INT_PIN = 4;
constexpr int BQ_STAT_PIN = 5;
constexpr int BQ_CE_PIN = 6;
void setup() {
Serial.begin(115200);
Wire.begin(I2C_SDA_PIN, I2C_SCL_PIN);
// No MCU pull-ups: a USB-powered controller must not source the unpowered
// power board through J10. Final line bias resides on the power board.
pinMode(BQ_INT_PIN, INPUT);
pinMode(BQ_STAT_PIN, INPUT);
pinMode(BQ_CE_PIN, INPUT); // Leave CE high impedance until commanded.
}
void loop() {
Serial.print("BQ_INT=");
Serial.print(digitalRead(BQ_INT_PIN) == LOW ? "active" : "idle");
Serial.print(" BQ_STAT=");
Serial.println(digitalRead(BQ_STAT_PIN) == LOW ? "active" : "idle");
delay(1000);
}“Deploy to device” opens this project in Schematik, where you can flash it to your board over USB.
Remix this project
Make it yours in one click
Open a full copy of this project in your own Schematik workspace — diagram, code, parts, and assembly steps included. Swap the sensor, add features, or redesign the whole thing with AI. The author's original stays untouched.