GitHub Digital Lab

Fox Red Labs / Builds / Motor control, power and sensing

Measure a board's running and sleep current

The LAUNCHXL-F2800137 has no current meter, so two wires from an MSPM0 L1306's EnergyTrace probe power the chip and read it: 35.4 mA running CoreMark at 120 MHz, 2.6 mA in STANDBY, above a 6.10 mA HALT reading.

MediumWiring needed1 evening

The LAUNCHXL-F2800137 this build runs on, drawn from its user guide. Drag to turn it.

What you need

Works on this board
On Linux or WindowsThe steps were recorded on a Mac; paths and port names in them are the Mac ones.

macOS (recorded)

TI's tools
/Applications/ti, or ~/ti
Serial port
/dev/cu.usbmodem<serial>1
Probe access
nothing to do

Linux

TI's tools
~/ti (also searched: /opt/ti)
Serial port
/dev/ttyACM0 (by name: /dev/serial/by-id/*<serial>*-if00*)
Probe access
one udev rule, how

Windows

TI's tools
C:\ti (also searched: %USERPROFILE%\ti)
Serial port
COM<n>, named "XDS110 Class Application/User UART" in Device Manager
Probe access
the XDS110 USB driver from UniFlash or CCStudio

Your probe's serial on any system: python3 tools/frl/frl.py detect. Not run on a board under Linux or Windows. Everything else that differs: the full table.

Steps

  1. Wire itBENCH

    Pin table
    PinGoes toWhat it isNeeded
    MSPM0 L1306 J101, top-row 3V3 pin (probe side)LAUNCHXL-F2800137 JP2 +3V3, chip-side pin3.3 V from the meter to the chiprequired
    MSPM0 L1306 J2, any GND pinLAUNCHXL-F2800137 JP5, any GND pincommon groundrequired
    MSPM0 L1306 J101 3V3 jumper(pull it out)stops the probe powering its own chiprequired
    LAUNCHXL-F2800137 JP2 +3V3 shunt(pull it out; leave the +5V0 shunt in)stops the board powering its own chiprequired
  1. Build the profile image.TERMINAL

    Profile 2 runs every phase in one image: a 2 s busy spin at 120 MHz, CoreMark (2k iterations from flash), 12 watchdog wakes in IDLE, a 3 s spin at 60 MHz, 12 watchdog wakes in STANDBY, then HALT with the PLL and oscillators off. Build it from flash with the same flags as the recorded image. Do this with the board on its own USB power and the JP2 shunt in.

    TAG=FLASH-O4s5 c2000-launchpad/bench/build.sh c2000-launchpad/bench/power/profile2 4 FLASH -DITERATIONS=2000 -DPERFORMANCE_RUN=1 --opt_for_speed=5

    You should see: The script prints the RAM and FLASH use and the path c2000-launchpad/bench/power/profile2/build-FLASH-O4s5/bench.out.

  2. Flash it and leave it running.TERMINAL

    Flash first: the board's own debugger cannot connect once the chip is powered from the wire (error -2131 on every attempt). Mode go writes the image to flash, starts it, disconnects and leaves it running.

    /Applications/ti/ccs2101/ccs/scripting/run.sh c2000-launchpad/tools/c2krun.js c2000-launchpad/bench/power/profile2/build-FLASH-O4s5/bench.out go

    You should see: The scripting runner loads the image and disconnects; the program keeps running on the board.

  3. Unplug both USB cables and rewire.BENCH

    Pull the 3V3 jumper from J101 on the MSPM0 L1306 and leave the other eight in. Pull the +3V3 shunt from JP2 on the LAUNCHXL-F2800137 and leave +5V0 in. Wire J101's probe-side 3V3 pin to the chip-side JP2 +3V3 pin, and a GND pin on J2 of the MSPM0 board to a GND pin on JP5 of the C2000 board. Do not plug the USB cables in yet.

    You should see: Two wires between the boards, two parts removed, both USB cables out.

  4. Start the capture, then plug both USB cables in.TERMINAL

    Start the capture first, so the trace begins at power-up, using the serial number of the MSPM0 L1306's probe (--list shows it). Then plug in both USB cables. The C2000's own USB still runs its debugger; the MSPM0 board's probe is the meter.

    Replace <MSPM0 probe serial> before you run this.

    python3 tools/energytrace/etcap.py --list python3 tools/energytrace/etcap.py --serial <MSPM0 probe serial> --seconds 150 --csv c2000-launchpad/bench/power/f28-run.csv --json c2000-launchpad/bench/power/f28-run.json

    You should see: The tool samples 2,000 times a second for 150 s and writes the CSV and a JSON file with read statistics.

  5. Read the phases off the trace.TERMINAL

    Open the CSV and find each phase by its edge. Subtract the HALT reading (the lowest, last phase) from the others: that reading holds the board's own CAN transceiver, power LED and encoder buffer, so every chip figure is 'above HALT'.

    You should see: Raw readings in the recorded run: busy spin 38.72 mA, CoreMark from flash 41.46 mA, IDLE 29.33 mA, 60 MHz spin 22.93 mA, STANDBY between wakes 8.68 mA, HALT 6.10 mA. Minus HALT: 35.4 mA running CoreMark, 23.2 mA IDLE, 2.6 mA STANDBY.

  6. Put the boards back.BENCH

    Unplug both USB cables. Put the 3V3 jumper back in J101 and the +3V3 shunt back in JP2.

    You should see: Both boards as they came.

What to build next

Every build

If something goes wrong

It cannot find the compiler or C2000WareThe two paths are at the top of build.sh; change them to your install. Not run on Linux or Windows.
The probe says a firmware update is requiredThe F2800137's probe needs firmware 3.0.0.43 before TI's tools connect (see c2000-launchpad/README.md).
The chip never starts after step 4The GND wire is missing: the 3.3 V has no return path.
A capture ends early with fewer samples than its lengthRun it again; the tool restarts the stream after 2 s of silence and records read errors in the JSON. A press of the C2000 board's reset button restarts the profile without a rewire.
The STANDBY phase reads about 30 mAThe same as IDLE, the chip was re-entered too soon after each watchdog wake; the image waits 30 ms first, so check you built profile2, not profile.
More troubleshooting
A board does not power on from USB afterwardOne of the two parts is not seated.

Every fix for this board: the FAQ.

Get the code

Paste this in a terminal. It hands off to an AI assistant.

git clone --depth 1 --filter=blob:none https://github.com/Fox-Red-Labs/fox-red-labs.git && cd fox-red-labs ./start.sh f2800137 battery-life --assistant claude
Not Claude Code? Copy this prompt instead.
Clone https://github.com/Fox-Red-Labs/fox-red-labs and read c2000-launchpad/AGENTS.md first. Then run Measure a board's current draw, for battery life on my LAUNCHXL-F2800137, following docs/builds/battery-life.md. Tell me when to plug in a board and what you saw at each step.

The code is in c2000-launchpad/, with notes for your AI assistant in AGENTS.md.

Reports from others, and the report forms

Clone the repository and open the board's folder below. AGENTS.md is a plain text file of notes for AI coding assistants, and llms.txt at the root indexes the site for one.

git clone https://github.com/Fox-Red-Labs/fox-red-labs.git

Code is BSD-3-Clause, writing is CC BY 4.0; third-party folders keep their own licenses.

Built it? Tell us

Built this, or got stuck? Report it on GitHub with a few short answers. Your report shows here in your words, marked as yours. A failure that repeats on the bench gets its fix here.

Evidence and limits35.4 mA running CoreMark at 120 MHz and 2.59 mA in STANDBY on the F2800137, read through an MSPM0 L1306 EnergyTrace probe; no coin-cell life figure was measured. Results, sources, timing and limits.

Expected result: A 150 s trace with clear edges between phases. Above the HALT reading: about 35.4 mA running CoreMark at 120 MHz, 23.2 mA in IDLE and 2.6 mA in STANDBY, 828.1 uJ per CoreMark iteration.

What this shows

  • A board with no meter of its own can be measured with another LaunchPad's EnergyTrace probe and two wires: 35.4 mA running CoreMark from flash at 120 MHz and 2.6 mA in STANDBY, above a 6.10 mA HALT reading.
  • Energy per CoreMark iteration: 828.1 uJ ((41.46 - 6.10) mA x 3.3 V x 14.19 s / 2,000).
  • About 263 uA per MHz between 60 and 120 MHz.
What this does not establish, and limits

What this does not establish

  • Coin-cell or battery life: not measured, and no battery was wired in.
  • The chip's own HALT current: the 6.10 mA reference includes the board's CAN transceiver, power LED and encoder buffer.
  • A second board of the same kind or a second run on another day: one board, one rewire (a second and third capture agree).
  • The model-inference profile: it was flashed but the probe stopped streaming at full rate, so no row exists (energy_inference is waiting).

Limits to keep in mind

  • Needs an MSPM0 L1306 (or another EnergyTrace-capable LaunchPad) as the meter.
  • The probe supplies about 75 mA at most; a motor or a BoosterPack on the C2000 board would trip it.
  • The board's own debugger cannot connect while the chip is on the wire; flash first.
  • Checked on one Intel Mac, CCStudio 21.0.1.

Sources

Versions, sizes and timing

Sampling2k samples a second through CCStudio's XDS110 driver, no IDEthe script
HALT reference6.10 mA raw (PLL and oscillators off), subtracted from every chip figurethe data (CSV)
STANDBY8.68 mA raw between wakes (sd 0.16); 30 ms wait after each watchdog wakethe data (CSV)

Evidence

  • 2026-10-07: 35.4 mA running CoreMark from flash at 120 MHz (828.1 uJ per iteration), 23.2 mA in IDLE, 2.6 mA in STANDBY, 263 uA per MHz between 60 and 120 MHz, all above the 6.10 mA HALT reading. One flash image, one rewire. F2800137 borrowed energytrace notes
  • Results rows sleep_current (2,590 uA) and energy_coremark (828.1 uJ) with their conditions. the data (CSV)
  • The capture traces: f28-profile2-run3.csv (profile 2, from the IDLE phase on) and f28-profile-150s.csv (profile 1, from power-up).

Other boards

What the status words mean

Works ran here and did what it shouldCould work some of it ran; real porting effort is left; hover for whatNot for this chip the chip or its vendor software cannot; hover for why

Result grid

Project
LP-MSPM0G3507MSPM0G3507 chip
LP-MSPM0L1306MSPM0L1306 chip
LP-EM-CC2340R5CC2340R52 chip
LAUNCHXL-F2800137TMS320F2800137 chip
Measure a board's current draw, for battery life
LP-MSPM0G3507
LP-MSPM0L1306
LP-EM-CC2340R5
LAUNCHXL-F2800137Could work35.4 mA running CoreMark at 120 MHz and 2.59 mA in STANDBY, read through an LP-MSPM0L1306 EnergyTrace probe;
Detailscoin-cell life not measured
Measured results (data file)

Works ran here and did what it shouldShould work it builds; only naming, packaging or build glue is in the way; hover for whichCould work some of it ran; real porting effort is left; hover for whatNot for this chip the chip or its vendor software cannot; hover for why

Experiments (2)

StatusWhat was triedResult
Could workWhy does EnergyTrace on the TI LP-MSPM0L1306 not work on a Mac in CCStudio 21, and can it be made to?
MSPM0 L1306, 2026-10-06
Two functions in the IDE's code switch trace off on macOS, with the comment "not supported". TI's Mac trace server library cannot load as shipped, because of a path from TI's build machine and a Linux-style search...
WorksCan the TI LAUNCHXL-F2800137, which has no EnergyTrace, borrow the LP-MSPM0L1306 probe to measure its chip's current?
LAUNCHXL-F2800137, 2026-10-07
Works: two wires from the MSPM0 L1306's EnergyTrace probe to the chip side of the C2000 board's JP2 jumper make it the meter. Above the HALT reading: 35.4 mA running CoreMark at 120 MHz, 2.6 mA in STANDBY. The C2000...

Source files