Skip to content

Script to plot audio waves from I2S samples exported from sigrok/PulseView.

License

Notifications You must be signed in to change notification settings

lucasssvaz/SigPlotI2S

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 

Repository files navigation

SigPlotI2S

Script to plot audio waves from I2S samples exported from sigrok/PulseView. This was created to provide visual aid when debugging I2S drivers.

Requirements

Usage

python SigPlotI2S.py [Options] <input file>

Required arguments:
  <input file>          Path to the input file

Options:
  -h, --help            Show help message
  -o <output file>, --output <output file>
                        Path to the output file (.png or .pdf). Save image into a file
                        instead of opening a pop-up.
  -d <datawidth>, --datawidth <datawidth>
                        Number of bits per sample (default: 16)
  -c <channels>, --channels <channels>
                        Number of channels (default: 2)
  -s, --swap-channels, --no-swap-channels
                        Swap left and right channels (default: False)

Example

In this example we will use a 44.1kHz, 16-bit, stereo WAV file containing a sine wave and, from the I2S data recorded, generate the resulting waveform of the output audio.

  1. Scan the I2S bus to be analysed;

1

  1. Add and configure I2S decoder;

2

  1. Export I2S annotation as sinewave.txt;

3

  1. Run SigPlotI2S to convert and plot the I2S samples;
python SigPlotI2S.py -d 16 -c 2 sinewave.txt
  1. Get the resulting waveform.

5

About

Script to plot audio waves from I2S samples exported from sigrok/PulseView.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages