diff options
Diffstat (limited to 'gr-trellis/src/examples/python/test_sccc_soft.py')
-rwxr-xr-x | gr-trellis/src/examples/python/test_sccc_soft.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/gr-trellis/src/examples/python/test_sccc_soft.py b/gr-trellis/src/examples/python/test_sccc_soft.py index b1ffaae748..0b10c07bbc 100755 --- a/gr-trellis/src/examples/python/test_sccc_soft.py +++ b/gr-trellis/src/examples/python/test_sccc_soft.py @@ -8,8 +8,11 @@ import sys import random import fsm_utils - - +try: + from gnuradio import analog +except ImportError: + sys.stderr.write("Error: Program requires gr-analog.\n") + sys.exit(1) def run_test (fo,fi,interleaver,Kb,bitspersymbol,K,dimensionality,constellation,N0,seed): tb = gr.top_block () @@ -26,7 +29,7 @@ def run_test (fo,fi,interleaver,Kb,bitspersymbol,K,dimensionality,constellation, # CHANNEL add = gr.add_ff() - noise = gr.noise_source_f(gr.GR_GAUSSIAN,math.sqrt(N0/2),seed) + noise = analog.noise_source_f(analog.GR_GAUSSIAN,math.sqrt(N0/2),seed) # RX metrics_in = trellis.metrics_f(fi.O(),dimensionality,constellation,digital.TRELLIS_EUCLIDEAN) # data preprocessing to generate metrics for innner Viterbi |