Name | Date | Size | #Lines | LOC | ||
---|---|---|---|---|---|---|
.. | 03-May-2022 | - | ||||
SimpleSoapy.egg-info/ | H | 03-May-2022 | - | 71 | 54 | |
LICENSE | H A D | 06-Jun-2016 | 1.1 KiB | 22 | 17 | |
MANIFEST.in | H A D | 06-Jun-2016 | 35 | 3 | 2 | |
PKG-INFO | H A D | 27-Apr-2017 | 2.3 KiB | 71 | 54 | |
README.rst | H A D | 20-Mar-2017 | 1.1 KiB | 50 | 34 | |
setup.cfg | H A D | 27-Apr-2017 | 38 | 5 | 3 | |
setup.py | H A D | 27-Apr-2017 | 1,003 | 32 | 28 | |
simplesoapy.py | H A D | 27-Apr-2017 | 18 KiB | 505 | 412 |
README.rst
1SimpleSoapy 2=========== 3 4Simple pythonic wrapper for SoapySDR library 5 6Requirements 7------------ 8 9- `Python 3 <https://www.python.org>`_ 10- `NumPy <http://www.numpy.org>`_ 11- `SoapySDR <https://github.com/pothosware/SoapySDR>`_ 12 13Limitations 14----------- 15 16Only receiving is implemented. Transmission may be implemented in future. 17 18Example 19------- 20:: 21 22 import simplesoapy 23 import numpy 24 25 # List all connected SoapySDR devices 26 print(simplesoapy.detect_devices(as_string=True)) 27 28 # Initialize SDR device 29 sdr = simplesoapy.SoapyDevice('driver=rtlsdr') 30 31 # Set sample rate 32 sdr.sample_rate = 2.56e6 33 34 # Set center frequency 35 sdr.freq = 88e6 36 37 # Setup base buffer and start receiving samples. Base buffer size is determined 38 # by SoapySDR.Device.getStreamMTU(). If getStreamMTU() is not implemented by driver, 39 # SoapyDevice.default_buffer_size is used instead 40 sdr.start_stream() 41 42 # Create numpy array for received samples 43 samples = numpy.empty(len(sdr.buffer) * 100, numpy.complex64) 44 45 # Receive all samples 46 sdr.read_stream_into_buffer(samples) 47 48 # Stop receiving 49 sdr.stop_stream() 50