aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVasil Velichkov <vvvelichkov@gmail.com>2018-09-12 12:28:54 +0300
committerPiotr Krysik <ptrkrysik@gmail.com>2018-09-13 15:35:44 +0200
commit00a9c400a87389a3b3f0a830eb64e909bdfc0209 (patch)
tree15c5508eac5ce3b5e4cd4ddadbc0b405ee059f8a
parentd6e8bb744e05a749ed1fa55479c0d702da37166c (diff)
grgsm_channelize: Add ichar data type
This is the output format of rtl_sdr and hackrf_transfer and this would allow direct channelization without an additional post processing. Change-Id: Ia489eca9ec7defc3a83946c42f1ae3f136efe4e8
-rwxr-xr-xapps/helpers/grgsm_channelize6
1 files changed, 5 insertions, 1 deletions
diff --git a/apps/helpers/grgsm_channelize b/apps/helpers/grgsm_channelize
index 9b00bd7..5eaeb3b 100755
--- a/apps/helpers/grgsm_channelize
+++ b/apps/helpers/grgsm_channelize
@@ -79,6 +79,10 @@ class grgsm_channelize(gr.top_block):
self.blocks_file_source = blocks.file_source(gr.sizeof_short, input_file, False)
self.source = blocks.interleaved_short_to_complex(False, False)
self.connect((self.blocks_file_source, 0), (self.source, 0))
+ elif data_type == "ichar":
+ self.blocks_file_source = blocks.file_source(gr.sizeof_char, input_file, False)
+ self.source = blocks.interleaved_char_to_complex(False)
+ self.connect((self.blocks_file_source, 0), (self.source, 0))
elif data_type == "complex":
self.source = blocks.file_source(gr.sizeof_gr_complex, input_file, False)
@@ -114,7 +118,7 @@ if __name__ == '__main__':
help="Sample rate of the output capture files [default=%(default)s]")
parser.add_argument("-i", "--input_file", dest="input_file", type=str, required=True,
help="Path to wideband GSM capture file")
- parser.add_argument("-t", "--data_type", dest="data_type", type=str, choices=["complex","ishort"], default="complex",
+ parser.add_argument("-t", "--data_type", dest="data_type", type=str, choices=["complex","ishort","ichar"], default="complex",
help="Type of the input file [default=%(default)s]")
parser.add_argument("-d", "--dest_dir", dest="dest_dir", type=str,
help="Destination directory - if not given defaults to input file name without extension")