Joulescope data logging

With the latest 0.5.1 software, the “.jls” file format is about 8.6 MB/s, which is 92 GB for 3 hours. If you are only concerned with monitoring charge or energy, recording the 2 million samples per second is overkill. We recently added downsample_logging.py to pyjoulescope_examples that records downsampled 2 Hz Joulescope data to a CSV file. Here is what you need:

  • Install python 3.6+ and pyjoulescope. See the instructions. Although we recommend using a virtualenv, that step is optional.
  • Clone the pyjoulescope_examples repo.
  • python pyjoulescope_examples/bin/downsample_logging.py

Here are the commands for windows without virtualenv. Open a command line (terminal) and type:

cd {your_repo_path}
pip install joulescope
git clone https://github.com/jetperch/pyjoulescope_examples.git
python pyjoulescope_examples/bin/downsample_logging.py

The script will print the logging location, which is:

C:\Users\{your_user_name}\Documents\joulescope\jslog_YYYYMMDD_HHMMSS_uuuuuu.csv

By default, the CSV contains a single line column header. Here is the full help from the script:

>python bin\downsample_logging.py --help
usage: downsample_logging.py [-h] [--header {none,simple,comment}] [--resume]

Capture downsampled data.

optional arguments:
  -h, --help            show this help message and exit
  --header {none,simple,comment}
                        CSV header option. "none" excludes all header
                        information and just includes data. "simple" (default)
                        adds a first line with column labels. "comment"
                        contains multiple lines starting with "#" and also
                        inserts events into the CSV file.
  --resume, -r          Resume the previous capture and append new data.

>

Here are example output files:

Units are SI: second, ampere, volt, watt, coulomb, joule

3 Likes