aboutsummaryrefslogtreecommitdiffstats
path: root/grc
diff options
context:
space:
mode:
Diffstat (limited to 'grc')
-rw-r--r--grc/CMakeLists.txt4
-rw-r--r--grc/flow_control/CMakeLists.txt25
-rw-r--r--grc/flow_control/gsm_burst_fnr_filter.xml42
-rw-r--r--grc/flow_control/gsm_burst_sdcch_subslot_splitter.xml44
-rw-r--r--grc/flow_control/gsm_burst_timeslot_splitter.xml24
-rw-r--r--grc/flow_control/gsm_dummy_burst_filter.xml24
-rw-r--r--grc/gsm_block_tree.xml13
-rw-r--r--grc/misc_utils/CMakeLists.txt8
-rw-r--r--grc/misc_utils/gsm_burst_file_sink.xml (renamed from grc/misc_utils/gsm_burst_sink.xml)6
-rw-r--r--grc/misc_utils/gsm_burst_file_source.xml (renamed from grc/misc_utils/gsm_burst_source.xml)6
-rw-r--r--grc/misc_utils/gsm_bursts_printer.xml21
-rw-r--r--grc/misc_utils/gsm_message_printer.xml16
-rw-r--r--grc/qa_utils/CMakeLists.txt25
-rw-r--r--grc/qa_utils/gsm_burst_sink.xml (renamed from grc/misc_utils/gsm_burst_sink_qa.xml)6
-rw-r--r--grc/qa_utils/gsm_burst_source.xml (renamed from grc/misc_utils/gsm_burst_source_qa.xml)6
-rw-r--r--grc/qa_utils/gsm_message_sink.xml19
-rw-r--r--grc/qa_utils/gsm_message_source.xml32
17 files changed, 295 insertions, 26 deletions
diff --git a/grc/CMakeLists.txt b/grc/CMakeLists.txt
index caf2660..2b94539 100644
--- a/grc/CMakeLists.txt
+++ b/grc/CMakeLists.txt
@@ -21,8 +21,8 @@ add_subdirectory(decoding)
add_subdirectory(decryption)
add_subdirectory(demapping)
add_subdirectory(receiver)
+add_subdirectory(flow_control)
add_subdirectory(misc_utils)
install(FILES
- gsm_block_tree.xml
- DESTINATION share/gnuradio/grc/blocks
+ gsm_block_tree.xml DESTINATION share/gnuradio/grc/blocks
)
diff --git a/grc/flow_control/CMakeLists.txt b/grc/flow_control/CMakeLists.txt
new file mode 100644
index 0000000..107fac7
--- /dev/null
+++ b/grc/flow_control/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Copyright 2011,2012 Free Software Foundation, Inc.
+#
+# This file is part of GNU Radio
+#
+# GNU Radio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3, or (at your option)
+# any later version.
+#
+# GNU Radio is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with GNU Radio; see the file COPYING. If not, write to
+# the Free Software Foundation, Inc., 51 Franklin Street,
+# Boston, MA 02110-1301, USA.
+
+install(FILES
+ gsm_burst_timeslot_splitter.xml
+ gsm_burst_fnr_filter.xml
+ gsm_dummy_burst_filter.xml
+ gsm_burst_sdcch_subslot_splitter.xml DESTINATION share/gnuradio/grc/blocks
+)
diff --git a/grc/flow_control/gsm_burst_fnr_filter.xml b/grc/flow_control/gsm_burst_fnr_filter.xml
new file mode 100644
index 0000000..d09b6e6
--- /dev/null
+++ b/grc/flow_control/gsm_burst_fnr_filter.xml
@@ -0,0 +1,42 @@
+<?xml version="1.0"?>
+<block>
+ <name>Burst framenumber filter</name>
+ <key>gsm_burst_fnr_filter</key>
+ <import>import grgsm</import>
+ <make>grgsm.burst_fnr_filter($mode, $fnr)</make>
+
+ <param>
+ <name>Mode</name>
+ <key>mode</key>
+ <type>enum</type>
+ <option>
+ <name>Less or equal</name>
+ <key>grgsm.FILTER_LESS_OR_EQUAL</key>
+ </option>
+ <option>
+ <name>Greater or equal</name>
+ <key>grgsm.FILTER_GREATER_OR_EQUAL</key>
+ </option>
+ </param>
+ <param>
+ <name>Framenumber</name>
+ <key>fnr</key>
+ <value>1500123</value>
+ <type>int</type>
+ </param>
+
+ <sink>
+ <name>in</name>
+ <type>message</type>
+ </sink>
+
+ <source>
+ <name>out</name>
+ <type>message</type>
+ <optional>1</optional>
+ </source>
+
+ <doc>
+Burst framenumber filter forwards only blocks with a framenumber satisfying the configured mode, i.e. if mode is "Less or equal", then only bursts with a smaller or equal framenumber are forwarded.
+ </doc>
+</block>
diff --git a/grc/flow_control/gsm_burst_sdcch_subslot_splitter.xml b/grc/flow_control/gsm_burst_sdcch_subslot_splitter.xml
new file mode 100644
index 0000000..4812d0b
--- /dev/null
+++ b/grc/flow_control/gsm_burst_sdcch_subslot_splitter.xml
@@ -0,0 +1,44 @@
+<?xml version="1.0"?>
+<block>
+ <name>Burst SDCCH subslot splitter</name>
+ <key>gsm_burst_sdcch_subslot_splitter</key>
+ <import>import grgsm</import>
+ <make>grgsm.burst_sdcch_subslot_splitter(
+#if int($ports())==4 #
+grgsm.SPLITTER_SDCCH4
+#else
+grgsm.SPLITTER_SDCCH8
+#end if
+ )</make>
+
+ <param>
+ <name>Mode</name>
+ <key>ports</key>
+ <type>enum</type>
+ <option>
+ <name>SDCCH/8</name>
+ <key>8</key>
+ </option>
+ <option>
+ <name>SDCCH/4</name>
+ <key>4</key>
+ </option>
+ </param>
+
+ <sink>
+ <name>in</name>
+ <type>message</type>
+ </sink>
+
+ <source>
+ <name>out</name>
+ <type>message</type>
+ <nports>$ports</nports>
+ <optional>1</optional>
+ </source>
+
+ <doc>
+Burst SDCCH subslot splitter distributes bursts to eight different output ports depending on the subslots to which the bursts belong.
+This means subslot 0 bursts are sent to port out0, subslot 1 bursts on port out1, and so on.
+ </doc>
+</block> \ No newline at end of file
diff --git a/grc/flow_control/gsm_burst_timeslot_splitter.xml b/grc/flow_control/gsm_burst_timeslot_splitter.xml
new file mode 100644
index 0000000..91db4db
--- /dev/null
+++ b/grc/flow_control/gsm_burst_timeslot_splitter.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0"?>
+<block>
+ <name>Burst timeslot splitter</name>
+ <key>gsm_burst_timeslot_splitter</key>
+ <import>import grgsm</import>
+ <make>grgsm.burst_timeslot_splitter()</make>
+
+ <sink>
+ <name>in</name>
+ <type>message</type>
+ </sink>
+
+ <source>
+ <name>out</name>
+ <type>message</type>
+ <nports>8</nports>
+ <optional>1</optional>
+ </source>
+
+ <doc>
+Burst timeslot splitter distributes bursts to eight different output ports depending on the timeslots of the bursts.
+This means timeslot 0 bursts are sent to port out0, timeslot 1 bursts on port out1, and so on.
+ </doc>
+</block>
diff --git a/grc/flow_control/gsm_dummy_burst_filter.xml b/grc/flow_control/gsm_dummy_burst_filter.xml
new file mode 100644
index 0000000..046abbf
--- /dev/null
+++ b/grc/flow_control/gsm_dummy_burst_filter.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0"?>
+<block>
+ <name>Dummy burst filter</name>
+ <key>gsm_dummy_burst_filter</key>
+ <import>import grgsm</import>
+ <make>grgsm.dummy_burst_filter()</make>
+
+ <sink>
+ <name>in</name>
+ <type>message</type>
+ </sink>
+
+ <source>
+ <name>out</name>
+ <type>message</type>
+ <optional>1</optional>
+ </source>
+
+ <doc>
+This block filters dummy bursts.
+
+For more information on dummy bursts, see GSM 05.02.
+ </doc>
+</block>
diff --git a/grc/gsm_block_tree.xml b/grc/gsm_block_tree.xml
index 6496fd3..26f607f 100644
--- a/grc/gsm_block_tree.xml
+++ b/grc/gsm_block_tree.xml
@@ -38,14 +38,19 @@
<block>gsm_tch_f_decoder</block>
</cat>
<cat>
+ <name>Flow control</name>
+ <block>gsm_burst_timeslot_splitter</block>
+ <block>gsm_burst_sdcch_subslot_splitter</block>
+ <block>gsm_burst_fnr_filter</block>
+ <block>gsm_dummy_burst_filter</block>
+ </cat>
+ <cat>
<name>Utilities</name>
<block>gsm_bursts_printer</block>
- <block>gsm_burst_sink</block>
- <block>gsm_burst_source</block>
+ <block>gsm_burst_file_sink</block>
+ <block>gsm_burst_file_source</block>
<block>gsm_message_file_sink</block>
<block>gsm_message_file_source</block>
- <block>gsm_burst_sink_qa</block>
- <block>gsm_burst_source_qa</block>
<block>gsm_extract_system_info</block>
<block>gsm_extract_immediate_assignment</block>
<block>gsm_controlled_rotator_cc</block>
diff --git a/grc/misc_utils/CMakeLists.txt b/grc/misc_utils/CMakeLists.txt
index 0ace0d8..99985a1 100644
--- a/grc/misc_utils/CMakeLists.txt
+++ b/grc/misc_utils/CMakeLists.txt
@@ -26,10 +26,8 @@ install(FILES
gsm_bursts_printer.xml
gsm_clock_offset_corrector.xml
gsm_tmsi_dumper.xml
+ gsm_burst_file_sink.xml
+ gsm_burst_file_source.xml
gsm_message_file_sink.xml
- gsm_message_file_source.xml
- gsm_burst_sink.xml
- gsm_burst_source.xml
- gsm_burst_source_qa.xml
- gsm_burst_sink_qa.xml DESTINATION share/gnuradio/grc/blocks
+ gsm_message_file_source.xml DESTINATION share/gnuradio/grc/blocks
)
diff --git a/grc/misc_utils/gsm_burst_sink.xml b/grc/misc_utils/gsm_burst_file_sink.xml
index a0e7532..e468e5f 100644
--- a/grc/misc_utils/gsm_burst_sink.xml
+++ b/grc/misc_utils/gsm_burst_file_sink.xml
@@ -1,9 +1,9 @@
<?xml version="1.0"?>
<block>
- <name>Burst sink</name>
- <key>gsm_burst_sink</key>
+ <name>Burst file sink</name>
+ <key>gsm_burst_file_sink</key>
<import>import grgsm</import>
- <make>grgsm.burst_sink($filename)</make>
+ <make>grgsm.burst_file_sink($filename)</make>
<param>
<name>Destination file</name>
diff --git a/grc/misc_utils/gsm_burst_source.xml b/grc/misc_utils/gsm_burst_file_source.xml
index 9e78069..e32a708 100644
--- a/grc/misc_utils/gsm_burst_source.xml
+++ b/grc/misc_utils/gsm_burst_file_source.xml
@@ -1,9 +1,9 @@
<?xml version="1.0"?>
<block>
- <name>Burst source</name>
- <key>gsm_burst_source</key>
+ <name>Burst file source</name>
+ <key>gsm_burst_file_source</key>
<import>import grgsm</import>
- <make>grgsm.burst_source($filename)</make>
+ <make>grgsm.burst_file_source($filename)</make>
<param>
<name>Source file</name>
diff --git a/grc/misc_utils/gsm_bursts_printer.xml b/grc/misc_utils/gsm_bursts_printer.xml
index abdb532..821e6bb 100644
--- a/grc/misc_utils/gsm_bursts_printer.xml
+++ b/grc/misc_utils/gsm_bursts_printer.xml
@@ -4,7 +4,8 @@
<key>gsm_bursts_printer</key>
<import>import grgsm</import>
<import>import pmt</import>
- <make>grgsm.bursts_printer(pmt.intern($prepend_string), $prepend_fnr, $prepend_frame_count, $print_payload_only)</make>
+ <make>grgsm.bursts_printer(pmt.intern($prepend_string), $prepend_fnr,
+ $prepend_frame_count, $print_payload_only, $ignore_dummy_bursts)</make>
<param>
<name>Prepend String</name>
@@ -55,6 +56,20 @@
<key>True</key>
</option>
</param>
+ <param>
+ <name>Ignore dummy bursts</name>
+ <key>ignore_dummy_bursts</key>
+ <value>False</value>
+ <type>bool</type>
+ <option>
+ <name>False</name>
+ <key>False</key>
+ </option>
+ <option>
+ <name>True</name>
+ <key>True</key>
+ </option>
+ </param>
<sink>
<name>bursts</name>
@@ -70,6 +85,8 @@ If "Prepend Frame Count" is enabled, then the frame count for A5 is prependend t
If "Print payload only" is enabled, then only the two data blocks of a burst are printed, tail bits, stealing bits and training sequence are omitted.
-Enabling all three options results in an output that is similar to the output of airprobe, i.e. the format is "frame_nr frame_count: databits"
+If "Ignore dummy bursts" is enabled, then the burst printer will not print dummy bursts (see GSM 05.02)
+
+Enabling first three options (or all four options) results in an output that is similar to the output of airprobe, i.e. the format is "frame_nr frame_count: databits"
</doc>
</block>
diff --git a/grc/misc_utils/gsm_message_printer.xml b/grc/misc_utils/gsm_message_printer.xml
index 8b44b22..7e390ed 100644
--- a/grc/misc_utils/gsm_message_printer.xml
+++ b/grc/misc_utils/gsm_message_printer.xml
@@ -4,7 +4,7 @@
<key>gsm_message_printer</key>
<import>import grgsm</import>
<import>import pmt</import>
- <make>grgsm.message_printer(pmt.intern($prepend_string))</make>
+ <make>grgsm.message_printer(pmt.intern($prepend_string), $print_gsmtap_header)</make>
<param>
<name>Prepend String</name>
@@ -13,6 +13,20 @@
<type>string</type>
<hide>part</hide>
</param>
+ <param>
+ <name>Print GSMTap header</name>
+ <key>print_gsmtap_header</key>
+ <value>False</value>
+ <type>bool</type>
+ <option>
+ <name>False</name>
+ <key>False</key>
+ </option>
+ <option>
+ <name>True</name>
+ <key>True</key>
+ </option>
+ </param>
<sink>
<name>msgs</name>
diff --git a/grc/qa_utils/CMakeLists.txt b/grc/qa_utils/CMakeLists.txt
new file mode 100644
index 0000000..1f57aa1
--- /dev/null
+++ b/grc/qa_utils/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Copyright 2011,2012 Free Software Foundation, Inc.
+#
+# This file is part of GNU Radio
+#
+# GNU Radio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3, or (at your option)
+# any later version.
+#
+# GNU Radio is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with GNU Radio; see the file COPYING. If not, write to
+# the Free Software Foundation, Inc., 51 Franklin Street,
+# Boston, MA 02110-1301, USA.
+
+install(FILES
+ gsm_burst_source.xml
+ gsm_burst_sink.xml
+ gsm_message_source.xml
+ gsm_message_sink.xml DESTINATION share/gnuradio/grc/blocks
+)
diff --git a/grc/misc_utils/gsm_burst_sink_qa.xml b/grc/qa_utils/gsm_burst_sink.xml
index c028da3..740960f 100644
--- a/grc/misc_utils/gsm_burst_sink_qa.xml
+++ b/grc/qa_utils/gsm_burst_sink.xml
@@ -1,9 +1,9 @@
<?xml version="1.0"?>
<block>
- <name>QA Burst sink</name>
- <key>gsm_burst_sink_qa</key>
+ <name>Burst sink</name>
+ <key>gsm_burst_sink</key>
<import>import grgsm</import>
- <make>grgsm.burst_sink_qa()</make>
+ <make>grgsm.burst_sink()</make>
<sink>
<name>in</name>
diff --git a/grc/misc_utils/gsm_burst_source_qa.xml b/grc/qa_utils/gsm_burst_source.xml
index bb04cca..9f55ac5 100644
--- a/grc/misc_utils/gsm_burst_source_qa.xml
+++ b/grc/qa_utils/gsm_burst_source.xml
@@ -1,9 +1,9 @@
<?xml version="1.0"?>
<block>
- <name>QA Burst source</name>
- <key>gsm_burst_source_qa</key>
+ <name>Burst source</name>
+ <key>gsm_burst_source</key>
<import>import grgsm</import>
- <make>grgsm.burst_source_qa($framenumbers, $timeslots, $bursts)</make>
+ <make>grgsm.burst_source($framenumbers, $timeslots, $bursts)</make>
<param>
<name>Frame numbers</name>
diff --git a/grc/qa_utils/gsm_message_sink.xml b/grc/qa_utils/gsm_message_sink.xml
new file mode 100644
index 0000000..e0d6ac0
--- /dev/null
+++ b/grc/qa_utils/gsm_message_sink.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0"?>
+<block>
+ <name>Message Sink</name>
+ <key>gsm_message_sink</key>
+ <import>import grgsm</import>
+ <make>grgsm.message_sink()</make>
+
+ <sink>
+ <name>in</name>
+ <type>message</type>
+ </sink>
+
+ <doc>
+This block is a message sink for testing purposes.
+
+The data can be retrieved using function get_messages()
+
+ </doc>
+</block>
diff --git a/grc/qa_utils/gsm_message_source.xml b/grc/qa_utils/gsm_message_source.xml
new file mode 100644
index 0000000..ab06f65
--- /dev/null
+++ b/grc/qa_utils/gsm_message_source.xml
@@ -0,0 +1,32 @@
+<?xml version="1.0"?>
+<block>
+ <name>Message Source</name>
+ <key>gsm_message_source</key>
+ <import>import grgsm</import>
+ <make>grgsm.message_source($messages)</make>
+
+ <param>
+ <name>Messages</name>
+ <key>messages</key>
+ <value>["02 04 01 00 00 00 c9 00 00 1d 3c e5 02 00 01 00 15 06 21 00 01 f0 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b",
+"02 04 01 00 00 00 ca 00 00 1d 3c e9 02 00 02 00 15 06 21 00 01 f0 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b",
+"02 04 01 00 00 00 cb 00 00 1d 3d 0e 01 00 00 00 59 06 1a 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ff e5 04 00",
+"02 04 01 00 00 00 cb 00 00 1d 3d 12 02 00 00 00 15 06 21 00 01 f0 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b"]</value>
+ <type>raw</type>
+ <hide>true</hide>
+ </param>
+
+ <source>
+ <name>msgs</name>
+ <type>message</type>
+ </source>
+
+ <doc>
+This block is a basic message source for testing purposes.
+
+It takes a list of strings as input, where each string
+is a whitespace-separated list of hexadecimal values representing the data bytes of a message including the gsmtap header.
+
+Such strings can be obtained using the message printer with option "Print GSMTap header"
+ </doc>
+</block>