Skip to the content
2 layers80 × 58 mmEnergyReplay, the printed circuit board in 3D

HW/SW for energy replay

Size
80 × 58 mm
Copper layers
2
Thickness
1.6 mm
Parts
57
Nets
107
Pads
241
Tracks, vias
553, 84
Pours
2
Routed
Yes
KiCad
KiCad 7 (file 20221018)
Created
28 Feb 2024
Updated
2 May 2025

Overview

EnergyReplay is an open-source printed circuit board by FoRTE-Research, from the FoRTE-Research/EnergyReplay repository on GitHub. It is a 2-layer board of 80 × 58 mm with 57 parts on 107 nets, routed with 553 tracks and 84 vias.

It is built around the MSP430FR5994IPN, TPS613222ADBV and 19-237/R6GHBHC-A04/2T, with the LTST-C155GEKT among its other parts. Its parts include 19 resistors, 12 capacitors, 7 connectors, 5 ICs and 2 diodes. It belongs with the MSP430 boards of this library.

Main components

4

README

README.md

Overview

This is a hardware system for replaying arbitrary energy harvesting traces to drive experimentation on batteryless systems. It does so by measuring the voltage at the load and the current across a shunt resistor to determine instantaneous power input into the load and comparing this actual power input to a desired time-varying setpoint; if the actual power is below (above) the setpoint, it increases (decreases) supply voltage produced by a DAC to approach the setpoint. Since this is all done in software, you are free to implement whatever arbitrary functions may affect the power in your imagined system - IV curves for a solar panel, voltage-dependent efficiencies for a converter/regulator, etc.

Project Status

V1.2 is available as part of this Github repo, but the PCBs have not been ordered. The only difference between V1.1 and V1.2 is the addition of the voltage divider (R18 and R19) to reduce measured load voltage. Because V1.1 measures load voltage directly, it cannot produce a load voltage higher than ~3.3V (software will stop voltage from increasing further if load voltage approaches this point to avoid damaging the hardware).

An assembled and validated PCB for V1.1 is available in the lab.

Hardware

Schematic and PCB designs are generated in KiCad version 9.

The central microcontroller is an MSP430FR5994, which drives an MCP4725 12-bit DAC. Both the MSP430 and DAC operate at 3.3V; the output of the DAC is fed into an amplifier to increase its dynamic range to 5V. Current flows across a 0.5 ohm shunt resistor through an optional diode and into the load. Load current is measured by taking the voltage across the shunt resistor using a 150x differential amplifier into one ADC pin of the MSP430. Load voltage is divided by 2 using a resistive voltage divider and fed into another ADC pin of the MSP430. The short-circuit current of the OPA2837 op amps used is roughly 50 mA, so at 5V the nominal maximum output power is about 250 mW.

LEDs and switches are available for basic debugging and interactive use.

Jumpers

J1: Debug header for programming the MSP430FR5994.

J2: Power select jumper for replay system. The center pin is connected to the system supply voltage; it can draw power either from the debug header or from the 3V3 pin on J5.

J3/J4: Jumpers to connect and disconnect the green and red LEDs.

J5: GPIO breakout header. Also provides access to ground and 3V3 pins for supplying the system from a non-debugger source.

J6: Jumper for optional diode use. RAW is connected to the load side of the shunt resistor and can be connected to the load if the diode is not desired. Closing this jumper connects the load side of the shunt resistor to an LM66100 ideal diode to prevent current backflow from the load. When J6 is closed, the load should be connected on the OUT pin of J7.

J7: Jumper providing access to output pin for connecting load and ground pin for convenience. Do not close this jumper.

Software

Code is generated as a Code Composer Studio version 11 project.

The energy trace to replay is defined in the dac.h file as a const float powerArray[] containing the setpoints and a #define TIMESTEP macro to set the time (in milliseconds) that power should stay at each setpoint. This timestep is used to calculate a period value for a hardware timer that tracks the time spent at each setpoint; when the timer rolls over, the setpoint increments.

The main application loop reads samples from the shunt and load ADC pins, converts those readings to an actual power measurement, and compares them to the desired setpoint. The output voltage is incremented/decremented by 1 on each iteration of the main loop; this is basically a PID controller with KP = 1 and KI = KD = 0. Improving the design of this control loop is one avenue for improvement in future iterations, although it currently works "well enough". ADC, timer, and software control are all decoupled - increasing software execution speed (e.g., by doing the actual power calculation in hardware using some clever op-amp circuits) should only have the effect of reducing the response time of the control loop and not mess with the timing of the power trace. If you do significantly increase the software execution speed, you should double check that the ADC measurements are blocking so that it doesn't overshoot based on stale power readings.

Parts

57
QtyValueFootprintReferences
6100nCapacitor_SMD:C_1206_3216MetricC1, C2, C3, C4, C11, C12
4Conn_01x02_PinConnector_PinHeader_2.54mm:PinHeader_1x02_P2.54mm_VerticalJ3, J4, J6, J7
4MountingHoleMountingHole:MountingHole_3.2mm_M3H1, H2, H3, H4
4NetTie_2NetTie-0.2mm:NetTie-2_SMD_Pad0.2mmNT1, NT2, NT3, NT4
2150kResistor_SMD:R_1206_3216MetricR16, R17
21kResistor_SMD:R_1206_3216MetricR14, R15
222uCapacitor_SMD:C_1206_3216MetricC9, C10
24.7kResistor_SMD:R_1206_3216MetricR7, R8
2820kResistor_SMD:R_1206_3216MetricR18, R19
2SW_PushTL59NF160Q:SW_TL59NF160QSW1, SW2
10.1uCapacitor_SMD:C_1206_3216MetricC7
110kResistor_SMD:R_1206_3216MetricR9
110uCapacitor_SMD:C_1206_3216MetricC5
1110Resistor_SMD:R_1206_3216MetricR4
1120Resistor_SMD:R_1206_3216MetricR3
1120kResistor_SMD:R_1206_3216MetricR11
112kResistor_SMD:R_1206_3216MetricR10
1150Resistor_SMD:R_1206_3216MetricR2
119-237/R6GHBHC-A04/2TEAST1616RGBA3:EAST1616RGB_SMD_B_EVELED2
12.2nCapacitor_SMD:C_1206_3216MetricC6
12.2uInductor_SMD:L_1210_3225MetricL1
120Resistor_SMD:R_1206_3216MetricR5
14.7uCapacitor_SMD:C_1206_3216MetricC8
143Resistor_SMD:R_1206_3216MetricR6
147kResistor_SMD:R_1206_3216MetricR1
1500mResistor_SMD:R_1206_3216MetricR13
168kResistor_SMD:R_1206_3216MetricR12
1Conn_02x07_Odd_EvenConnector_PinHeader_2.54mm:PinHeader_2x07_P2.54mm_VerticalJ1
1Conn_02x10_Counter_ClockwiseConnector_PinHeader_2.54mm:PinHeader_2x10_P2.54mm_VerticalJ5
1CrystalMS1V-T1K:XTAL_MS1V-T1K-32.768KHZ-12.5PF-20PPM-TA-QCY1
1LM66100DCKRLM66100DCKR:DCK6_TEXU5
1LTST-C155GEKTLTST-C155GEKT:DIODE_LTST-C155GEKT_LTOLED1
1MCP4725xxx-xCHPackage_TO_SOT_SMD:SOT-23-6U2
1MSP430FR5994IPNMSP430FR5994IPN:PN0080A_NU1
1OPA2387DGKROPA2387DGK:DGK0008A-IPC_AU3
1Power SelectConnector_PinHeader_2.54mm:PinHeader_1x03_P2.54mm_VerticalJ2
1TPS613222ADBVPackage_TO_SOT_SMD:SOT-23-5U4

Similar boards

  • 2 layers50 × 35 mmBms4 f051, the printed circuit board in 3D

    Bms4 f051

    GyrocopterLLC/bms4-rust

    Battery management system (bms) for 4 series Li-Ion cells programmed in Rust

    63 parts1MIT
  • 6 layers40 × 15 mmMiniDAQ, the printed circuit board in 3D

    MiniDAQ

    Aharoni-Lab/MiniDAQ

    Simplified bare bones DAQ for Miniscopes and Minicams

    162 parts
  • 2 layers74.9 × 55.9 mm6s 750mA, the printed circuit board in 3D

    6s 750mA

    jsarrett/StackedCharger

    Isolated stackable LiPo charger

    121 parts
  • 2 layers90 × 50 mmHamradiocard, the printed circuit board in 3D

    Hamradiocard

    juhapark21/hamcard

    A small dashboard showing propagation conditions

    62 parts
  • 2 layers65.1 × 30.1 mmPhoton Power Zero PCB r1 01, the printed circuit board in 3D

    Photon Power Zero PCB r1 01

    DavidMurrayP2P/PhotonPowerZero

    A Solar Powered Raspberry Pi Board

    56 parts59CERN-OHL-S-2.0
  • 2 layers38 × 200 mmSPACEDOS02A PCB01A, the printed circuit board in 3D

    SPACEDOS02A PCB01A

    UniversalScientificTechnologies/SPACEDOS02

    Solid-state PIN diode dosimeter for manned spacecraft. Liulin detector replacement.

    120 parts8GPL-3.0
  • 2 layers61.5 × 126.8 mmBadge eda, the printed circuit board in 3D

    Badge eda

    theparanoids/keyhole-badge

    The Paranoids have designed a sound-reactive LED electronic conference badge for DEFCON 2022. This repository contains the PCB design files for the badge and the source code to the firmware that runs on the…

    88 parts7

Questions

How big is the EnergyReplay PCB?

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

What parts does the EnergyReplay use?

57 parts, built around the MSP430FR5994IPN, TPS613222ADBV, 19-237/R6GHBHC-A04/2T and LTST-C155GEKT. 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 EnergyReplay KiCad files?

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

Can I use the EnergyReplay design in my own project?

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