diff options
author | Marc Lichtman <mlichtman@perspectalabs.com> | 2018-10-27 13:47:25 -0400 |
---|---|---|
committer | Marc L <marcll@vt.edu> | 2018-10-29 15:02:45 -0400 |
commit | 2399759b3b5dc4ae4c03bf196ca16fe0f8dfd18d (patch) | |
tree | 2d91833f02191359c7d8974e45a394d0ea2a71c3 /gr-analog/python | |
parent | d19c96111ff56501a9b527b1e19dc6b0b9fd2922 (diff) |
docs: fixed docstring for nbfm tx and rx
Diffstat (limited to 'gr-analog/python')
-rw-r--r-- | gr-analog/python/analog/nbfm_rx.py | 41 | ||||
-rw-r--r-- | gr-analog/python/analog/nbfm_tx.py | 27 |
2 files changed, 33 insertions, 35 deletions
diff --git a/gr-analog/python/analog/nbfm_rx.py b/gr-analog/python/analog/nbfm_rx.py index 3e8dcd5287..f849012178 100644 --- a/gr-analog/python/analog/nbfm_rx.py +++ b/gr-analog/python/analog/nbfm_rx.py @@ -34,28 +34,27 @@ from .fm_emph import fm_deemph class nbfm_rx(gr.hier_block2): + """ + Narrow Band FM Receiver. + + Takes a single complex baseband input stream and produces a single + float output stream of audio sample in the range [-1, +1]. + + Args: + audio_rate: sample rate of audio stream, >= 16k (integer) + quad_rate: sample rate of output stream (integer) + tau: preemphasis time constant (default 75e-6) (float) + max_dev: maximum deviation in Hz (default 5e3) (float) + + quad_rate must be an integer multiple of audio_rate. + + Exported sub-blocks (attributes): + squelch + quad_demod + deemph + audio_filter + """ def __init__(self, audio_rate, quad_rate, tau=75e-6, max_dev=5e3): - """ - Narrow Band FM Receiver. - - Takes a single complex baseband input stream and produces a single - float output stream of audio sample in the range [-1, +1]. - - Args: - audio_rate: sample rate of audio stream, >= 16k (integer) - quad_rate: sample rate of output stream (integer) - tau: preemphasis time constant (default 75e-6) (float) - max_dev: maximum deviation in Hz (default 5e3) (float) - - quad_rate must be an integer multiple of audio_rate. - - Exported sub-blocks (attributes): - squelch - quad_demod - deemph - audio_filter - """ - gr.hier_block2.__init__(self, "nbfm_rx", gr.io_signature(1, 1, gr.sizeof_gr_complex), # Input signature gr.io_signature(1, 1, gr.sizeof_float)) # Output signature diff --git a/gr-analog/python/analog/nbfm_tx.py b/gr-analog/python/analog/nbfm_tx.py index a7620451eb..2d9aaa7d10 100644 --- a/gr-analog/python/analog/nbfm_tx.py +++ b/gr-analog/python/analog/nbfm_tx.py @@ -33,23 +33,22 @@ from . import analog_swig as analog class nbfm_tx(gr.hier_block2): - def __init__(self, audio_rate, quad_rate, tau=75e-6, max_dev=5e3, fh=-1.0): - """ - Narrow Band FM Transmitter. - - Takes a single float input stream of audio samples in the range [-1,+1] - and produces a single FM modulated complex baseband output. + """ + Narrow Band FM Transmitter. - Args: - audio_rate: sample rate of audio stream, >= 16k (integer) - quad_rate: sample rate of output stream (integer) - tau: preemphasis time constant (default 75e-6) (float) - max_dev: maximum deviation in Hz (default 5e3) (float) - fh: high frequency at which to flatten preemphasis; < 0 means default of 0.925*quad_rate/2.0 (float) + Takes a single float input stream of audio samples in the range [-1,+1] + and produces a single FM modulated complex baseband output. - quad_rate must be an integer multiple of audio_rate. - """ + Args: + audio_rate: sample rate of audio stream, >= 16k (integer) + quad_rate: sample rate of output stream (integer) + tau: preemphasis time constant (default 75e-6) (float) + max_dev: maximum deviation in Hz (default 5e3) (float) + fh: high frequency at which to flatten preemphasis; < 0 means default of 0.925*quad_rate/2.0 (float) + quad_rate must be an integer multiple of audio_rate. + """ + def __init__(self, audio_rate, quad_rate, tau=75e-6, max_dev=5e3, fh=-1.0): gr.hier_block2.__init__(self, "nbfm_tx", gr.io_signature(1, 1, gr.sizeof_float), # Input signature gr.io_signature(1, 1, gr.sizeof_gr_complex)) # Output signature |