Oscilloscopes normally have a single trace, but Joulescope displays three. The red ones also disappear when you zoom in far enough. Why?

# What are the 3 traces on each oscilloscope window?

**mliberty**#2

As of v0.2.4, you see two red traces and one yellow trace.

When zoomed out, each x-axis pixel may represent many, many samples, which I’ll call that pixel’s sample “window”. The plot displays the statistics over each pixel. The yellow line is the mean (average). The red lines are the minimum and maximum. Power “glitches”, such as interrupt service routines, are very interesting for energy optimization. The minimum and maximum ensure that you do not miss these events, even when very zoomed out. When you eventually zoom in far enough, 1 pixel becomes 1 sample, and the minimum and the maximum are the same as the average.

Many sound editors have similar behavior to show the sound waveform. However, they usually only show a line from max to min since the mean is 0. Since the mean is often very important for Joulescope, we plot it directly and show the max and min as separate traces.