summaryrefslogtreecommitdiff
path: root/gr-trellis/src/examples/python/test_sccc_turbo.py
diff options
context:
space:
mode:
Diffstat (limited to 'gr-trellis/src/examples/python/test_sccc_turbo.py')
-rwxr-xr-xgr-trellis/src/examples/python/test_sccc_turbo.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/gr-trellis/src/examples/python/test_sccc_turbo.py b/gr-trellis/src/examples/python/test_sccc_turbo.py
index 90155860bc..979dfeca59 100755
--- a/gr-trellis/src/examples/python/test_sccc_turbo.py
+++ b/gr-trellis/src/examples/python/test_sccc_turbo.py
@@ -2,14 +2,17 @@
from gnuradio import gr
from gnuradio import trellis, digital
-from gnuradio import analog
from gnuradio import eng_notation
import math
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 make_rx(tb,fo,fi,dimensionality,constellation,K,interleaver,IT,Es,N0,type):
metrics_in = trellis.metrics_f(fi.O(),dimensionality,constellation,digital.TRELLIS_EUCLIDEAN) # data preprocessing to generate metrics for innner Viterbi