
Cell sim
atopile/cell-sim
This cell-sim is designed to mimic a LiPo battery pack for develpoment of the surrounding electronics, like a BMS.

This cell-sim is designed to mimic a LiPo battery pack for develpoment of the surrounding electronics, like a BMS.
Cell is an open-source printed circuit board by atopile, from the atopile/cell-sim repository on GitHub, published under the MIT licence. It is a 4-layer board with 63 parts on 57 nets, routed with 480 tracks and 75 vias.
Its parts include 25 resistors, 16 capacitors, 14 ICs, 3 diodes and 3 transistors. It belongs with the power boards of this library.
This cell-sim is designed to mimic a LiPo battery pack for develpoment of the surrounding electronics, like a BMS.


pip install -r requirements.txt
python example_set_voltages.py
You should see something like this:

Board is intended to be manufactured with JLC, files are in the main directory of the repository. Note, the highlighted isolated regulator needs to be depopulated:
We use PlatformIO to build and upload the firmware via USB.
pio run -t upload or install the PlatformIO VSCode extension and use the upload button.from lib.cellsim import CellSim
cellsim = CellSim(port)Each cell has a relay in series between the cell output and the connector, this can be used to simulate open-wire faults for example.
# Global enable/disable
cellsim.enableOutputAll()
time.sleep(1)
cellsim.disableOutputAll()
time.sleep(1)
# Enable/disable one at a time
# Turn relays on in a wave
for i in range(1, 17):
cellsim.enableOutput(i)
time.sleep(0.1)
time.sleep(1)
# Turn relays off in a wave
for i in range(1, 17):
cellsim.disableOutput(i)
time.sleep(0.1)Each output voltage can be specified between 0.5V and 4.4V
# Set all at once
cellsim.setAllVoltages(3.5)
time.sleep(1)
# Set one at a time
print("\nSetting rainbow voltage pattern...")
for i in range(16):
voltage = 1.0 + (3.0 * i / 15) # Spread 1V to 4V across 16 channels
cellsim.setVoltage(i + 1, voltage)Each channel has an onboard 16bit ADC that measures the cell output. Note this is not a kelvin connection to your DUT, the measurement will only be accurate when minimal current is being drawn by the DUT.
voltages = cellsim.getAllVoltages()
print(f"Voltages: {[f'{v:.3f}' for v in voltages]}")To take a precision measurement, each channel has a multiplexed output that connects to the DMM connector via a relay.
channel_to_measure = 3
# Enable DMM
cellsim.enableDMM(channel_to_measure)
# take measurment using external DMM
# that is connected to the DMM banana outputs
time.sleep(1)
cellsim.disableDMM()Each channel has a resistor + mosfet across its output, this can be used to speed up the discharge of the output capacitors. For example when transitioning from a high output voltage to a low output voltage, there will be an RC decay time before the voltage settles, typically in the ~100ms range. Turning on the load switch will make this much faster.
cellsim.enableLoadSwitchAll()
time.sleep(1)
cellsim.disableLoadSwitchAll()
time.sleep(1)Once your test is finished, you can use the following to close the serial session:
cellsim.close()| Qty | Value | Footprint | References |
|---|---|---|---|
| 11 | 62.5mW Thick Film Resistors 50V ±100ppm/℃ ±1% 10kΩ 0402 Chip Resistor - Surface Mount ROHS | lib:R0402 | R4, R5, R8, R9, R12, R15, R18, R20, R21, R24, R25 |
| 8 | 25V 10uF X5R ±10% 0805 Multilayer Ceramic Capacitors MLCC - SMD/SMT ROHS | lib:C0805 | C2, C3, C4, C6, C7, C8, C11, C12 |
| 4 | 16V 100nF X7R ±10% 0402 Multilayer Ceramic Capacitors MLCC - SMD/SMT ROHS | lib:C0402 | C5, C9, C13, C14 |
| 3 | 25V 1uF X5R ±10% 0402 Multilayer Ceramic Capacitors MLCC - SMD/SMT ROHS | lib:C0402 | C10, C15, C16 |
| 3 | 62.5mW Thick Film Resistors 50V ±100ppm/℃ ±1% 1kΩ 0402 Chip Resistor - Surface Mount ROHS | lib:R0402 | R13, R16, R17 |
| 3 | ? | lib:LED0603-RD | LED1, LED2, LED3 |
| 3 | ? | lib:SOT-23-6_L2.9-W1.6-P0.95-LS2.8-BL | U3, U4, U5 |
| 3 | ? | lib:SOT-23-3_L2.9-W1.3-P1.90-LS2.4-BR | Q1, Q2, Q3 |
| 2 | 62.5mW Thick Film Resistors 50V ±100ppm/℃ ±1% 13kΩ 0402 Chip Resistor - Surface Mount ROHS | lib:R0402 | R11, R14 |
| 2 | ? | lib:RELAY-SMD_HFD4-5-SR | U8, U9 |
| 2 | ? | lib:LED-SMD_4P-L2.0-W2.0-BR | U12, U13 |
| 1 | 125mW Thick Film Resistors 150V ±1% 100mΩ 0805 Chip Resistor - Surface Mount ROHS | lib:R0805 | R10 |
| 1 | 125mW Thick Film Resistors 150V ±100ppm/℃ ±1% 226Ω 0805 Chip Resistor - Surface Mount ROHS | lib:R0805 | R19 |
| 1 | 50V 2.2uF X5R ±10% 0805 Multilayer Ceramic Capacitors MLCC - SMD/SMT ROHS | lib:C0805 | C1 |
| 1 | 62.5mW Thick Film Resistors 50V ±100ppm/℃ ±1% 11.5kΩ 0402 Chip Resistor - Surface Mount ROHS | lib:R0402 | R22 |
| 1 | 62.5mW Thick Film Resistors 50V ±100ppm/℃ ±1% 14kΩ 0402 Chip Resistor - Surface Mount ROHS | lib:R0402 | R1 |
| 1 | 62.5mW Thick Film Resistors 50V ±100ppm/℃ ±1% 24kΩ 0402 Chip Resistor - Surface Mount ROHS | lib:R0402 | R2 |
| 1 | 62.5mW Thick Film Resistors 50V ±100ppm/℃ ±1% 37.4kΩ 0402 Chip Resistor - Surface Mount ROHS | lib:R0402 | R3 |
| 1 | 62.5mW Thick Film Resistors 50V ±100ppm/℃ ±1% 43kΩ 0402 Chip Resistor - Surface Mount ROHS | lib:R0402 | R6 |
| 1 | 62.5mW Thick Film Resistors 50V ±100ppm/℃ ±1% 6.2kΩ 0402 Chip Resistor - Surface Mount ROHS | lib:R0402 | R23 |
| 1 | 62.5mW Thick Film Resistors 50V ±100ppm/℃ ±1% 60.4kΩ 0402 Chip Resistor - Surface Mount ROHS | lib:R0402 | R7 |
| 1 | ? | lib:IND-SMD_L4.0-W4.0 | L2 |
| 1 | ? | lib:SOT-23-5_L3.0-W1.7-P0.95-LS2.8-BL | U14 |
| 1 | ? | lib:WSON-6_L2.0-W2.0-P0.65-TL-EP | U6 |
| 1 | ? | lib:MSOP-10_L3.0-W3.0-P0.50-LS5.0-BL | U2 |
| 1 | ? | lib:IND-SMD_L4.4-W4.2 | L1 |
| 1 | ? | lib:PWRM-TH_BXXXXS-2WR2 | U1 |
| 1 | ? | lib:SOIC-8_L4.9-W3.9-P1.27-LS6.0-TL | U11 |
| 1 | ? | lib:SOT-563_L1.6-W1.2-P0.50-LS1.6-TL | U7 |
| 1 | ? | lib:QFN-16_L3.0-W3.0-P0.50-BL-EP1.7 | U10 |
63 parts. 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.
From the atopile/cell-sim repository on GitHub, at the commit this page was made from: the board is elec/layout/cell/cell.kicad_pcb and its schematic elec/layout/cell/cell.kicad_sch. PCBKit opens the board in the browser, with nothing to install.
Its repository publishes it under the MIT licence: you may reuse it on that licence's terms (keep the author's notice, and for a copyleft licence share your changes alike).

atopile/cell-sim
This cell-sim is designed to mimic a LiPo battery pack for develpoment of the surrounding electronics, like a BMS.

atopile/cell-sim
This cell-sim is designed to mimic a LiPo battery pack for develpoment of the surrounding electronics, like a BMS.

atopile/cell-sim
This cell-sim is designed to mimic a LiPo battery pack for develpoment of the surrounding electronics, like a BMS.

atopile/cell-sim
This cell-sim is designed to mimic a LiPo battery pack for develpoment of the surrounding electronics, like a BMS.

atopile/cell-sim
This cell-sim is designed to mimic a LiPo battery pack for develpoment of the surrounding electronics, like a BMS.

loxodes/vna
Under development open hardware microwave vector network analyzer

pierre-muth/fast-flipdot
Driving a flipdot matrix differently. All dots simultaneously.

lab11/signpost
Exploring what happens when you put computers on sign posts.


AndersBNielsen/PhaseLatchMini
High-rate continuous streaming of interleaved dual ADC (I/Q) samples over USB Full‑Speed (FS) using only the built‑in CDC class on an STM32F103C8 ("Blue Pill" style) board.

jlcjak/neurband
Open, minimal sEMG wristband like the Meta Neural Band: 8-ch ADS1298 + nRF52832 BLE, dry gold electrodes on a flex, 3D-printed band. KiCad, FreeCAD, Zephyr, Python, simulations.

