SDRNative for Python
A library for direct control of SDR hardware, raw IQ sampling, DVB-T transport stream reception, w/ low-level device access. Provides tuning, synchronous and asynchronous capture.
Python 3.10+ is required. Supported hardware is currently limited to RTL2832U receivers with R820T-family tuners.
Installation
python -m pip install sdrnative
A supported RTL2832U receiver and the appropriate USB driver or access permissions are needed for hardware use. The native library is distributed with the platform-specific package; no separate CMake build is required.
python -m sdrnative
This prints the native version, ABI and detected receivers.
Basic Usage
Raw 8-bit IQ samples are returned as interleaved unsigned I/Q bytes. Frequencies and sample rates are specified in Hz.
from sdrnative import Device, list_devices
print(list_devices())
with Device.open(0) as dev:
dev.iq_start(100_700_000, 2_400_000)
with open("capture.iq", "wb") as output:
for _ in range(16):
output.write(dev.read(256 * 1024))
For native DVB-T reception, supply a local multiplex frequency and a supported bandwidth (6, 7 or 8 MHz):
from sdrnative import Device
with Device.open(0) as dev:
dev.dvbt_start(557_500_000, 7_000_000)
print("lock stage:", dev.wait_lock(5000))
print(dev.signal_quality())
with open("capture.ts", "wb") as output:
for _ in range(16):
output.write(dev.read())
For asynchronous reads, start the mode first and use AsyncStream:
from sdrnative import AsyncConfig, Device
with Device.open(0) as dev:
dev.iq_start(100_700_000)
with dev.async_stream(AsyncConfig(queue_depth=16)) as stream:
for block in stream.read_many(4):
print(block.sequence, len(block.data))
Device and AsyncStream support context managers. Synchronous read() can
return empty bytes on timeout; asynchronous read() returns None on timeout,
while iteration skips timeouts. Only one asynchronous consumer is supported per
device. Native failures raise SDRNativeError subclasses.
The source repository contains
further capture programs under examples/python/.
MPL-2.0.
Metadata
Release files for sdrnative 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| sdrnative-0.1.0.tar.gz | 118.5 kB | With provenance | Details |
Built distributions (wheels)
| File | Reset | |||
|---|---|---|---|---|
| sdrnative-0.1.0-py3-none-win_amd64.whl | Python 3 | none | Windows x86-64 | Details |
| sdrnative-0.1.0-py3-none-manylinux_2_28_x86_64.whl | Python 3 | none | Linux glibc 2.28+ x86-64 | Details |
| sdrnative-0.1.0-py3-none-macosx_15_0_arm64.whl | Python 3 | none | macOS 15.0+ ARM64 | Details |
| sdrnative-0.1.0-py3-none-macosx_14_0_x86_64.whl | Python 3 | none | macOS 14.0+ x86-64 | Details |
Total release size: 1.6 MB
Release files / sdrnative-0.1.0.tar.gz
| Download URL | sdrnative-0.1.0.tar.gz |
|---|---|
| Size | 118.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
69ea02cd3538bc1bfbd801954d45b1fa5e40afda2ad3d1a64a74a584cf536d95
|
|
BLAKE2b-256 checksum How to use checksums |
29f8d4e32b039422de6fb75019561dc9af6f06a4fc3c5e4b2020a3e6cc18010f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.
Transparency logRelease files / sdrnative-0.1.0-py3-none-win_amd64.whl
| Download URL | sdrnative-0.1.0-py3-none-win_amd64.whl |
|---|---|
| Size | 153.4 kB |
| Tags | Python 3 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
bcd1a90c0bd23ed03baf35e6d1a46a7e112e871e32d47a86a3daebb2c348ecad
|
|
BLAKE2b-256 checksum How to use checksums |
03268c1b63dff9ed13a6237f3389197658cbefc25e190bc0b41e9521622cda8d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.
Transparency logRelease files / sdrnative-0.1.0-py3-none-manylinux_2_28_x86_64.whl
| Download URL | sdrnative-0.1.0-py3-none-manylinux_2_28_x86_64.whl |
|---|---|
| Size | 1.1 MB |
| Tags | Linux glibc 2.28+ x86-64 Python 3 |
|
SHA-256 checksum How to use checksums |
0b43a4bfc80224e47dfa10618a65d55737beff99a3d6f096c313dc801074a9df
|
|
BLAKE2b-256 checksum How to use checksums |
408cc3ae1c7a5f6c031399bd327e6e7cde0ed8cd723fad9b82c231945f2e81e6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.
Transparency logRelease files / sdrnative-0.1.0-py3-none-macosx_15_0_arm64.whl
| Download URL | sdrnative-0.1.0-py3-none-macosx_15_0_arm64.whl |
|---|---|
| Size | 109.7 kB |
| Tags | Python 3 macOS 15.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
8d0c1516fafcbdb0de50a98d32afbec874a3df2db957f6bdc153b661fa88558d
|
|
BLAKE2b-256 checksum How to use checksums |
089b8b163ee2ed697693ce5c525c1ce4e832b5ae743dabd9e09e0b7cc350f01c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.
Transparency logRelease files / sdrnative-0.1.0-py3-none-macosx_14_0_x86_64.whl
| Download URL | sdrnative-0.1.0-py3-none-macosx_14_0_x86_64.whl |
|---|---|
| Size | 116.3 kB |
| Tags | Python 3 macOS 14.0+ x86-64 |
|
SHA-256 checksum How to use checksums |
c4da3e96ebc9d9df0ee2acf20ff715705a22b6816986fae0f4b62a04ef84069d
|
|
BLAKE2b-256 checksum How to use checksums |
7dae61db2247472fdf88898e527cb125880f433ad9215a379203efed87c0403a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.
Transparency logSecurity for sdrnative 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
All 5 files in this release have been uploaded with provenance metadata.
Attestation for sdrnative-0.1.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.