> ## Documentation Index
> Fetch the complete documentation index at: https://docs.embedder.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Joulescope

> Measure current, voltage, and energy with JS110, JS220, or JS320.

Use a Joulescope inline with an external supply to measure current and voltage during a known firmware workload. Captures appear in the Monitor's **Power** tab. Identify the model and serial number before measuring; JS110, JS220, and JS320 differ in ranges, sampling, and digital I/O.

## Prepare

Connect Joulescope by USB, close competing applications, and complete Embedder's requested dependency setup. JS320 requires Python 3.12 or newer and `pyjoulescope_driver` 2.3.4 or newer. Device firmware older than 1.1.3 is rejected on JS320.

## Wire the current and voltage paths

<Warning>
  Joulescope does not supply voltage. Connect it between an external supply and the target using the wiring for the installed model and front panel.
</Warning>

For a JS110-style panel, supply connects to IN and the target to OUT. For JS220 or JS320 terminals, route supply positive through `I+` and `I-` to target VDD, connect the voltage-sense terminals as required, and share the reference ground. In a two-wire setup, tie `V+` to `I+`; for Kelvin sensing, sense voltage at the target.

Use the exact device limits. Enabling the DUT current path permits current from the external supply; it does not set a supply voltage. On JS320, resolve the cause of a tripped fuse before asking Embedder to clear it and re-enable that path.

## Measure a workload

```text theme={"system"}
The JS220 is wired inline to an external 3.3 V supply. Capture current and
voltage for three seconds during the idle workload and open the Power view.
Report current, voltage, power, and energy for the capture.
```

Specify the supply, settling period, workload, duration, and final current-path state. Use automatic current ranging unless a known workload needs a fixed range. In a [hardware script](/debug-mode/hardware-scripts), `joulescope_measure()` performs a bounded capture; one-shot captures are limited to **60 seconds**.

When choosing ranges and sample rates, use the connected model's supported settings:

* **JS110:** supports the 2 A current range and 5 V voltage range; host samples can reach 2 MS/s.
* **JS220:** uses a 10 A range instead of JS110's 2 A range, supports 15 V or 2 V voltage ranges, and caps host output at 1 MS/s.
* **JS320:** supports 15 V or 2 V voltage ranges and a configurable autorange window. Its supported sample rates differ from the earlier models; ask for the accepted rates rather than reusing a JS110/JS220 rate.

These are measurement settings, not permission to exceed the device's input ratings. Check the applied settings before comparing results.

## Record a longer test

For a live view, open setup in the Monitor's **Power** tab and choose **Joulescope**, then select the available current and voltage ranges. Press **Start**, use **Pause** / **Resume** as needed, and press **Stop** to finish and save a capture. The live view's **Sample rate** controls statistics windows per second, separately from the raw acquisition sample rate. The DUT power control enables or disables the external supply's current path.

Choose the result you need:

* **Periodic statistics:** request current, voltage, and power statistics at a defined interval. Reset charge and energy accumulators when starting a new workload. A single statistics read returns the latest statistics window, not an aggregate of the entire time spent waiting.
* **Live samples:** start a stream, read samples during the test, then stop it and save the result you need.
* **Raw recording:** record selected current, voltage, or power signals to a `.jls` file, then stop the recording and open its result. JLS recordings support longer tests and offline inspection in Joulescope software.

```text theme={"system"}
Record current and voltage to idle-cycle.jls during a two-minute workload.
Stop recording when the workload ends and show the saved recording in Power.
Keep the external supply unchanged throughout the test.
```

Stop a live sample stream before starting a JLS recording. Record the workload, firmware revision, supply voltage, and settling period with the result so another run is comparable.

To revisit a completed recording, give its `.jls` path and ask Embedder to open it in **Power**. This view requires both current and voltage signals in the recording. Long recordings are summarized for display; retain the JLS file for full sample-level inspection.

## Correlate digital activity

For digital markers, give the GPI pin and target logic voltage. JS110 supports configurable I/O voltage; JS220 uses its internal 3.3 V reference or an externally wired Vref. On JS320, choose internal 3.3 V or the external VREF connection explicitly; wire external VREF to the target's logic supply when using it.

You can read GPI states, drive supported GPO pins, or measure between observed GPI edges. Specify a maximum duration and the final GPO state. The GPI-window measurement uses software polling and is suitable for longer state windows, not microsecond timing.

**JS220** can decode two 8N1 UART streams while measuring power. JS110 and JS320 do not expose this UART helper.

```text theme={"system"}
Decode the target TX line on JS220 gpi1 at 115200 baud while measuring for
five seconds. Report the received text and the whole-capture current statistics.
```

The UART result contains bytes without timestamps aligned to current samples. Use it to confirm that markers arrived during a capture. To compare current by state, hold the target in each known state and measure settled intervals separately.

## Update JS320 firmware

If a JS320 needs a firmware update, ask Embedder to prepare a dedicated hardware script using `joulescope_firmware_update()`. Stop measurements and disconnect the software session first, while leaving USB plugged in. Review and approve the update separately from a measurement; after it finishes, reconnect and verify the reported firmware version.

## Configure a live stream

Set the sample rate before you start. The rate counts statistics windows per second, not raw ADC samples. Each live sample is one on-device window with mean, minimum, and maximum values.

* JS110 and JS220 serve the `1`, `2`, `5`, `10`, `20`, `50`, and `100` Hz ladder.
* JS320 serves `1` Hz through `10` kHz.
* The device rounds a request to a rate it can serve. The toolbar shows the applied rate when it differs from the request.

Pick the voltage range and current range in the Setup panel before starting. A JS320 exposes a minimum and maximum current-range window; a JS110 or JS220 selects a single current range.

See [live power controls](/debug-mode/power-analyzer#stream-live-power-in-the-monitor) for pausing, recording, and stopping the stream.

## Troubleshoot

* **Zero current:** verify the current path and external supply; check for a tripped JS320 fuse.
* **Wrong voltage:** check voltage-sense wiring and the selected measurement range.
* **Range or sample rate rejected:** use settings supported by that model.
* **Device unavailable:** close competing applications and complete setup; JS320 may require a Python, driver, or firmware update.
* **Long capture fails:** use statistics, streaming, or a JLS recording instead of a one-shot capture.
* **Digital marker missing:** verify the pin, ground, I/O reference, and signal duration.

See [Combined workflows](/debug-mode/combined-workflows) for relating power to firmware behavior.
