Skip to main content

A Python package for software-defined radio

Project description

sdr

The sdr library is a Python 3 package for software-defined radio (SDR).

The goal of sdr is to provide tools to design, build, and analyze digital communications systems in Python. The library relies on and is designed to be interoperable with NumPy, SciPy, and Matplotlib. Performance is also very important. So, where possible, Numba is used to accelerate computationally intensive functions.

Additionally, the library aims to replicate relevant functionality from Matlab's Communications and DSP Toolboxes.

We are progressively adding functionality to the library. If there is something you'd like to see included in sdr, please open an issue on GitHub.

Enjoying the library? Give us a :star: on GitHub!

Features

  • Filtering: sdr.FIR, sdr.FIRInterpolator, sdr.IIR
  • Resampling: sdr.FarrowResampler
  • Modulation:
    • Classes: sdr.PSK
    • Pulse shapes: sdr.raised_cosine(), sdr.root_raised_cosine(), sdr.gaussian()
    • Symbol mapping: sdr.binary_code(), sdr.gray_code()
    • Symbol encoding: sdr.diff_encode(), sdr.diff_decode()
  • Synchronization: sdr.NCO, sdr.DDS, sdr.LoopFilter, sdr.ClosedLoopPLL
  • Measurement:
    • Energy: sdr.energy()
    • Power: sdr.peak_power(), sdr.average_power(), sdr.papr()
    • Voltage: sdr.peak_voltage(), sdr.rms_voltage(), sdr.crest_factor()
    • Errors: sdr.ErrorRate
  • Conversions:
    • From $E_b/N_0$: sdr.ebn0_to_esn0(), sdr.ebn0_to_snr()
    • From $E_s/N_0$: sdr.esn0_to_ebn0(), sdr.esn0_to_snr()
    • From $S/N$: sdr.snr_to_ebn0(), sdr.snr_to_esn0()
  • Simulation:
    • Channel models: sdr.bec(), sdr.bsc(), sdr.dmc()
    • Signal impairments: sdr.awgn(), sdr.frequency_offset(), sdr.sample_rate_offset(), sdr.iq_imbalance()
  • Link budgets:
    • Channel capacity: sdr.awgn_capacity(), sdr.bec_capacity(), sdr.bsc_capacity()
    • Path losses: sdr.fspl()
    • Antennas: sdr.parabolic_antenna()
  • Probability: sdr.Q(), sdr.Qinv()
  • Data manipulation: sdr.pack(), sdr.unpack(), sdr.hexdump()
  • Plotting:
    • Time-domain: sdr.plot.time_domain()
    • Frequency domain: sdr.plot.periodogram(), sdr.plot.spectrogram()
    • Modulation: sdr.plot.ber(), sdr.plot.ser(), sdr.plot.constellation(), sdr.plot.symbol_map()
    • Filters: sdr.plot.impulse_response(), sdr.plot.step_response(), sdr.plot.frequency_response(), sdr.plot.phase_response(), sdr.plot.phase_delay(), sdr.plot.group_delay(), sdr.plot.zeros_poles(), sdr.plot.filter()

Documentation

The documentation for sdr is located at https://mhostetter.github.io/sdr/latest/.

Install the package

The latest version of sdr can be installed from PyPI using pip.

python3 -m pip install sdr

Examples

There are detailed examples published at https://mhostetter.github.io/sdr/latest/examples/pulse-shapes/. The Jupyter notebooks behind the examples are available for experimentation in docs/examples/.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sdr-0.0.3.tar.gz (3.7 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

sdr-0.0.3-py3-none-any.whl (52.1 kB view details)

Uploaded Python 3

File details

Details for the file sdr-0.0.3.tar.gz.

File metadata

  • Download URL: sdr-0.0.3.tar.gz
  • Upload date:
  • Size: 3.7 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.17

File hashes

Hashes for sdr-0.0.3.tar.gz
Algorithm Hash digest
SHA256 a9a72ed2e1a3b81de97cf4975f092a495b6b0c36bc9cf6c0f8c1076187e0ff74
MD5 4e7b2d3ba757b091e683dc505e5a5690
BLAKE2b-256 53fa5d1bf371d5d3b4e8f51bd8f93ce7b3a802e7ccb93a9a2e64cb0f220e3582

See more details on using hashes here.

File details

Details for the file sdr-0.0.3-py3-none-any.whl.

File metadata

  • Download URL: sdr-0.0.3-py3-none-any.whl
  • Upload date:
  • Size: 52.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.17

File hashes

Hashes for sdr-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 8d38e4278653df901192891d3890d3ee16704fd7e831ac98548d62dbdfff3e6c
MD5 30ffcfb60ad790fb238a0ed26e7c73bd
BLAKE2b-256 9549071e99faf2f057c012af2afff8ace3df63946aff70d98b1d84557d7b0166

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page