diff options
author | Tom Rondeau <trondeau@vt.edu> | 2012-12-15 11:09:33 -0500 |
---|---|---|
committer | Tom Rondeau <trondeau@vt.edu> | 2012-12-15 11:09:33 -0500 |
commit | 0ddcb66881a7cd6e31be0e470097a79da1257be1 (patch) | |
tree | 47fd17ddd0b147d301cdd04cb78fc1bc89fddd7a /gr-blocks/python/parse_file_metadata.py | |
parent | 937865a8d1059b4d6202c6a59a1d8ded950f63d3 (diff) | |
parent | 6f7a9120c08badd42175737faaa896d001073fad (diff) |
Merge branch 'master' into next
Diffstat (limited to 'gr-blocks/python/parse_file_metadata.py')
-rw-r--r-- | gr-blocks/python/parse_file_metadata.py | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/gr-blocks/python/parse_file_metadata.py b/gr-blocks/python/parse_file_metadata.py index ec7bf6e804..c8ac2def94 100644 --- a/gr-blocks/python/parse_file_metadata.py +++ b/gr-blocks/python/parse_file_metadata.py @@ -22,11 +22,16 @@ import sys from gnuradio import gr -from gruel import pmt + +try: + import pmt +except ImportError: + from gruel import pmt + try: import blocks_swig as blocks -except: +except ImportError: from gnuradio import blocks ''' @@ -72,7 +77,7 @@ def parse_header(p, VERBOSE=False): if(VERBOSE): print "Version Number: {0}".format(version) else: - sys.stderr.write("Could not find key 'sr': invalid or corrupt data file.\n") + sys.stderr.write("Could not find key 'version': invalid or corrupt data file.\n") sys.exit(1) # EXTRACT SAMPLE RATE |