<p>ptrkrysik <strong>merged</strong> this change.</p><p><a href="https://gerrit.osmocom.org/c/gr-gsm/+/14945">View Change</a></p><div style="white-space:pre-wrap">Approvals:
  fixeria: Looks good to me, but someone else must approve
  ptrkrysik: Looks good to me, approved; Verified

</div><pre style="font-family: monospace,monospace; white-space: pre-wrap;">Add control channels demappers tests<br><br>3GPP TS 45.002 version 15.1.0 Release 15<br>Table 3 : Mapping of logical channels onto physical channels (see subclauses 6.3, 6.4, 6.5)<br>Table 4 : Mapping of logical channels onto physical channels (see subclauses 6.3, 6.4, 6.5)<br>Figure 8a: TDMA frame mapping for FCCH + SCH + BCCH + CCCH<br>Figure 8b: TDMA frame mapping for FCCH + SCH + BCCH + CCCH + SDCCH/4(0...3) + SACCH/4(0...3)<br><br>Five of the six tests currently fail and are marked with<br>@unittest.expectedFailure. Fixes in subsequent commits.<br><br>Change-Id: I33b0948832a0c2506bffd389cc134c3236c74d27<br>---<br>M include/grgsm/qa_utils/burst_sink.h<br>M include/grgsm/qa_utils/burst_source.h<br>M lib/qa_utils/burst_sink_impl.cc<br>M lib/qa_utils/burst_sink_impl.h<br>M lib/qa_utils/burst_source_impl.cc<br>M lib/qa_utils/burst_source_impl.h<br>M python/CMakeLists.txt<br>A python/qa_gsm_bcch_ccch_demapper.py<br>A python/qa_gsm_bcch_ccch_sdcch4_demapper.py<br>A python/qa_gsm_demapper_data.py<br>A python/qa_gsm_sdcch8_demapper.py<br>11 files changed, 653 insertions(+), 3 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/include/grgsm/qa_utils/burst_sink.h b/include/grgsm/qa_utils/burst_sink.h</span><br><span>index 774075f..ed811ed 100644</span><br><span>--- a/include/grgsm/qa_utils/burst_sink.h</span><br><span>+++ b/include/grgsm/qa_utils/burst_sink.h</span><br><span>@@ -54,6 +54,8 @@</span><br><span>       virtual std::vector<int> get_timeslots() = 0;</span><br><span>       virtual std::vector<std::string> get_burst_data() = 0;</span><br><span>       virtual pmt::pmt_t get_bursts() = 0;      </span><br><span style="color: hsl(120, 100%, 40%);">+      virtual std::vector<uint8_t> get_sub_types() = 0;</span><br><span style="color: hsl(120, 100%, 40%);">+      virtual std::vector<uint8_t> get_sub_slots() = 0;</span><br><span>     };</span><br><span>   } // namespace gsm</span><br><span> } // namespace gr</span><br><span>diff --git a/include/grgsm/qa_utils/burst_source.h b/include/grgsm/qa_utils/burst_source.h</span><br><span>index e74a8aa..2f249ad 100644</span><br><span>--- a/include/grgsm/qa_utils/burst_source.h</span><br><span>+++ b/include/grgsm/qa_utils/burst_source.h</span><br><span>@@ -54,6 +54,7 @@</span><br><span>       virtual void set_framenumbers(const std::vector<int> &framenumbers) = 0;</span><br><span>       virtual void set_timeslots(const std::vector<int> &timeslots) = 0;</span><br><span>       virtual void set_burst_data(const std::vector<std::string> &burst_data) = 0;</span><br><span style="color: hsl(120, 100%, 40%);">+      virtual void set_arfcn(uint16_t arfcn) = 0;</span><br><span>     };</span><br><span> </span><br><span>   } // namespace gsm</span><br><span>diff --git a/lib/qa_utils/burst_sink_impl.cc b/lib/qa_utils/burst_sink_impl.cc</span><br><span>index bdc2192..5151bf6 100644</span><br><span>--- a/lib/qa_utils/burst_sink_impl.cc</span><br><span>+++ b/lib/qa_utils/burst_sink_impl.cc</span><br><span>@@ -90,6 +90,8 @@</span><br><span>         d_framenumbers.push_back(frame_nr);</span><br><span>         d_timeslots.push_back(header->timeslot);</span><br><span>         d_burst_data.push_back(burst_str.str());</span><br><span style="color: hsl(120, 100%, 40%);">+        d_sub_types.push_back(header->sub_type);</span><br><span style="color: hsl(120, 100%, 40%);">+        d_sub_slots.push_back(header->sub_slot);</span><br><span>     }</span><br><span> </span><br><span>     std::vector<int> burst_sink_impl::get_framenumbers()</span><br><span>@@ -110,6 +112,14 @@</span><br><span>     {</span><br><span>         return d_bursts;</span><br><span>     }</span><br><span style="color: hsl(120, 100%, 40%);">+    std::vector<uint8_t> burst_sink_impl::get_sub_types()</span><br><span style="color: hsl(120, 100%, 40%);">+    {</span><br><span style="color: hsl(120, 100%, 40%);">+        return d_sub_types;</span><br><span style="color: hsl(120, 100%, 40%);">+    }</span><br><span style="color: hsl(120, 100%, 40%);">+    std::vector<uint8_t> burst_sink_impl::get_sub_slots()</span><br><span style="color: hsl(120, 100%, 40%);">+    {</span><br><span style="color: hsl(120, 100%, 40%);">+        return d_sub_slots;</span><br><span style="color: hsl(120, 100%, 40%);">+    }</span><br><span>   } /* namespace gsm */</span><br><span> } /* namespace gr */</span><br><span> </span><br><span>diff --git a/lib/qa_utils/burst_sink_impl.h b/lib/qa_utils/burst_sink_impl.h</span><br><span>index e87422d..15e3bcf 100644</span><br><span>--- a/lib/qa_utils/burst_sink_impl.h</span><br><span>+++ b/lib/qa_utils/burst_sink_impl.h</span><br><span>@@ -36,6 +36,8 @@</span><br><span>       std::vector<int> d_timeslots;</span><br><span>       std::vector<std::string> d_burst_data;</span><br><span>       pmt::pmt_t d_bursts;</span><br><span style="color: hsl(120, 100%, 40%);">+      std::vector<uint8_t> d_sub_types;</span><br><span style="color: hsl(120, 100%, 40%);">+      std::vector<uint8_t> d_sub_slots;</span><br><span>      public:</span><br><span>       burst_sink_impl();</span><br><span>       ~burst_sink_impl();</span><br><span>@@ -44,6 +46,8 @@</span><br><span>       virtual std::vector<int> get_timeslots();</span><br><span>       virtual std::vector<std::string> get_burst_data();</span><br><span>       virtual pmt::pmt_t get_bursts();</span><br><span style="color: hsl(120, 100%, 40%);">+      virtual std::vector<uint8_t> get_sub_types();</span><br><span style="color: hsl(120, 100%, 40%);">+      virtual std::vector<uint8_t> get_sub_slots();</span><br><span>     };</span><br><span> </span><br><span>   } // namespace gsm</span><br><span>diff --git a/lib/qa_utils/burst_source_impl.cc b/lib/qa_utils/burst_source_impl.cc</span><br><span>index f415eaf..276ed0e 100644</span><br><span>--- a/lib/qa_utils/burst_source_impl.cc</span><br><span>+++ b/lib/qa_utils/burst_source_impl.cc</span><br><span>@@ -52,7 +52,8 @@</span><br><span>       : gr::block("burst_source",</span><br><span>               gr::io_signature::make(0, 0, 0),</span><br><span>               gr::io_signature::make(0, 0, 0)),</span><br><span style="color: hsl(0, 100%, 40%);">-              d_finished(false)</span><br><span style="color: hsl(120, 100%, 40%);">+              d_finished(false),</span><br><span style="color: hsl(120, 100%, 40%);">+              d_arfcn(0)</span><br><span>     {</span><br><span>         message_port_register_out(pmt::mp("out"));</span><br><span>         set_framenumbers(framenumbers);</span><br><span>@@ -85,6 +86,11 @@</span><br><span>         d_burst_data = burst_data;</span><br><span>     }</span><br><span> </span><br><span style="color: hsl(120, 100%, 40%);">+    void burst_source_impl::set_arfcn(uint16_t arfcn)</span><br><span style="color: hsl(120, 100%, 40%);">+    {</span><br><span style="color: hsl(120, 100%, 40%);">+        d_arfcn = arfcn;</span><br><span style="color: hsl(120, 100%, 40%);">+    }</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span>     bool burst_source_impl::start()</span><br><span>     {</span><br><span>         d_finished = false;</span><br><span>@@ -122,7 +128,7 @@</span><br><span>                 tap_header->timeslot = d_timeslots[i];</span><br><span>                 tap_header->frame_number = htobe32(d_framenumbers[i]);</span><br><span>                 tap_header->sub_type = GSMTAP_BURST_NORMAL;</span><br><span style="color: hsl(0, 100%, 40%);">-                tap_header->arfcn = 0;</span><br><span style="color: hsl(120, 100%, 40%);">+                tap_header->arfcn = d_arfcn;</span><br><span>                 tap_header->signal_dbm = 0;</span><br><span>                 tap_header->snr_db = 0;</span><br><span> </span><br><span>diff --git a/lib/qa_utils/burst_source_impl.h b/lib/qa_utils/burst_source_impl.h</span><br><span>index cc7d9b4..bbcfd98 100644</span><br><span>--- a/lib/qa_utils/burst_source_impl.h</span><br><span>+++ b/lib/qa_utils/burst_source_impl.h</span><br><span>@@ -40,6 +40,7 @@</span><br><span>         std::vector<int> d_timeslots;</span><br><span>         std::vector<std::string> d_burst_data;</span><br><span>         bool d_finished;</span><br><span style="color: hsl(120, 100%, 40%);">+        uint16_t d_arfcn;</span><br><span>         void run();</span><br><span>      public:</span><br><span>         burst_source_impl(const std::vector<int> &framenumbers,</span><br><span>@@ -49,6 +50,7 @@</span><br><span>         virtual void set_framenumbers(const std::vector<int> &framenumbers);</span><br><span>         virtual void set_timeslots(const std::vector<int> &timeslots);</span><br><span>         virtual void set_burst_data(const std::vector<std::string> &burst_data);</span><br><span style="color: hsl(120, 100%, 40%);">+        virtual void set_arfcn(uint16_t arfcn);</span><br><span>         bool start();</span><br><span>         bool stop();</span><br><span>         bool finished();</span><br><span>diff --git a/python/CMakeLists.txt b/python/CMakeLists.txt</span><br><span>index 21f2507..97cb0a3 100644</span><br><span>--- a/python/CMakeLists.txt</span><br><span>+++ b/python/CMakeLists.txt</span><br><span>@@ -45,7 +45,7 @@</span><br><span> include(GrTest)</span><br><span> </span><br><span> set(GR_TEST_TARGET_DEPS gr-gsm)</span><br><span style="color: hsl(0, 100%, 40%);">-set(GR_TEST_PYTHON_DIRS ${CMAKE_BINARY_DIR}/swig:${CMAKE_BINARY_DIR}/python/misc_utils)</span><br><span style="color: hsl(120, 100%, 40%);">+set(GR_TEST_PYTHON_DIRS ${CMAKE_BINARY_DIR}/swig:${CMAKE_BINARY_DIR}/python/misc_utils:${CMAKE_BINARY_DIR}/python/receiver:${CMAKE_BINARY_DIR}/python/demapping:${CMAKE_BINARY_DIR}/python/transmitter)</span><br><span> GR_ADD_TEST(qa_arfcn ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/qa_arfcn.py)</span><br><span> GR_ADD_TEST(qa_decryption ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/qa_decryption.py)</span><br><span> GR_ADD_TEST(qa_burst_printer ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/qa_burst_printer.py)</span><br><span>@@ -61,6 +61,9 @@</span><br><span> GR_ADD_TEST(qa_tch_h_decoder ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/qa_tch_h_decoder.py)</span><br><span> GR_ADD_TEST(qa_tch_f_chans_demapper ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/qa_tch_f_chans_demapper.py)</span><br><span> GR_ADD_TEST(qa_tch_h_chans_demapper ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/qa_tch_h_chans_demapper.py)</span><br><span style="color: hsl(120, 100%, 40%);">+GR_ADD_TEST(qa_gsm_bcch_ccch_demapper ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/qa_gsm_bcch_ccch_demapper.py)</span><br><span style="color: hsl(120, 100%, 40%);">+GR_ADD_TEST(qa_gsm_bcch_ccch_sdcch4_demapper ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/qa_gsm_bcch_ccch_sdcch4_demapper.py)</span><br><span style="color: hsl(120, 100%, 40%);">+GR_ADD_TEST(qa_gsm_sdcch8_demapper ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/qa_gsm_sdcch8_demapper.py)</span><br><span> #GR_ADD_TEST(qa_msg_to_tag ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/qa_msg_to_tag.py)</span><br><span> #GR_ADD_TEST(qa_controlled_fractional_resampler_cc ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/qa_controlled_fractional_resampler_cc.py)</span><br><span> #GR_ADD_TEST(qa_uplink_downlink_splitter ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/qa_uplink_downlink_splitter.py)</span><br><span>diff --git a/python/qa_gsm_bcch_ccch_demapper.py b/python/qa_gsm_bcch_ccch_demapper.py</span><br><span>new file mode 100644</span><br><span>index 0000000..a57bc6b</span><br><span>--- /dev/null</span><br><span>+++ b/python/qa_gsm_bcch_ccch_demapper.py</span><br><span>@@ -0,0 +1,146 @@</span><br><span style="color: hsl(120, 100%, 40%);">+#!/usr/bin/env python</span><br><span style="color: hsl(120, 100%, 40%);">+# -*- coding: utf-8 -*-</span><br><span style="color: hsl(120, 100%, 40%);">+# @file</span><br><span style="color: hsl(120, 100%, 40%);">+# @author (C) 2019 by Vasil Velichkov <vvvelichkov@gmail.com></span><br><span style="color: hsl(120, 100%, 40%);">+# @section LICENSE</span><br><span style="color: hsl(120, 100%, 40%);">+#</span><br><span style="color: hsl(120, 100%, 40%);">+# Gr-gsm is free software; you can redistribute it and/or modify</span><br><span style="color: hsl(120, 100%, 40%);">+# it under the terms of the GNU General Public License as published by</span><br><span style="color: hsl(120, 100%, 40%);">+# the Free Software Foundation; either version 3, or (at your option)</span><br><span style="color: hsl(120, 100%, 40%);">+# any later version.</span><br><span style="color: hsl(120, 100%, 40%);">+#</span><br><span style="color: hsl(120, 100%, 40%);">+# Gr-gsm is distributed in the hope that it will be useful,</span><br><span style="color: hsl(120, 100%, 40%);">+# but WITHOUT ANY WARRANTY; without even the implied warranty of</span><br><span style="color: hsl(120, 100%, 40%);">+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the</span><br><span style="color: hsl(120, 100%, 40%);">+# GNU General Public License for more details.</span><br><span style="color: hsl(120, 100%, 40%);">+#</span><br><span style="color: hsl(120, 100%, 40%);">+# You should have received a copy of the GNU General Public License</span><br><span style="color: hsl(120, 100%, 40%);">+# along with gr-gsm; see the file COPYING.  If not, write to</span><br><span style="color: hsl(120, 100%, 40%);">+# the Free Software Foundation, Inc., 51 Franklin Street,</span><br><span style="color: hsl(120, 100%, 40%);">+# Boston, MA 02110-1301, USA.</span><br><span style="color: hsl(120, 100%, 40%);">+#</span><br><span style="color: hsl(120, 100%, 40%);">+#</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+import unittest</span><br><span style="color: hsl(120, 100%, 40%);">+import numpy as np</span><br><span style="color: hsl(120, 100%, 40%);">+from gnuradio import gr, gr_unittest, blocks</span><br><span style="color: hsl(120, 100%, 40%);">+import grgsm</span><br><span style="color: hsl(120, 100%, 40%);">+import pmt</span><br><span style="color: hsl(120, 100%, 40%);">+import qa_gsm_demapper_data as test_data</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+class qa_gsm_bcch_ccch_demapper (gr_unittest.TestCase):</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+    def setUp (self):</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb = gr.top_block ()</span><br><span style="color: hsl(120, 100%, 40%);">+        self.maxDiff = None</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+    def tearDown (self):</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb = None</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+    def test_downlink (self):</span><br><span style="color: hsl(120, 100%, 40%);">+        """</span><br><span style="color: hsl(120, 100%, 40%);">+           BCCH_CCCH demapper downlink test</span><br><span style="color: hsl(120, 100%, 40%);">+        """</span><br><span style="color: hsl(120, 100%, 40%);">+        src = grgsm.burst_source(test_data.frames, test_data.timeslots, test_data.bursts)</span><br><span style="color: hsl(120, 100%, 40%);">+        src.set_arfcn(0); # downlink</span><br><span style="color: hsl(120, 100%, 40%);">+        demapper = grgsm.gsm_bcch_ccch_demapper(timeslot_nr=0)</span><br><span style="color: hsl(120, 100%, 40%);">+        dst = grgsm.burst_sink()</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb.msg_connect(src, "out", demapper, "bursts")</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb.msg_connect(demapper, "bursts", dst, "in")</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb.run ()</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        b = test_data.bursts</span><br><span style="color: hsl(120, 100%, 40%);">+        self.assertEqual([</span><br><span style="color: hsl(120, 100%, 40%);">+            b[  2], b[  3], b[  4], b[  5], #BCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            b[  6], b[  7], b[  8], b[  9], #CCCH skip 10-11</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 12], b[ 13], b[ 14], b[ 15],</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 16], b[ 17], b[ 18], b[ 19], #skip 20-21</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 22], b[ 23], b[ 24], b[ 25],</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 26], b[ 27], b[ 28], b[ 29], #skip 30-31</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 32], b[ 33], b[ 34], b[ 35],</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 36], b[ 37], b[ 38], b[ 39], #skip 40-41</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 42], b[ 43], b[ 44], b[ 45],</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 46], b[ 47], b[ 48], b[ 49], #skip 50-52</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 53], b[ 54], b[ 55], b[ 56], #BCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 57], b[ 58], b[ 59], b[ 60], #CCCH skip 61-62</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 63], b[ 64], b[ 65], b[ 66],</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 67], b[ 68], b[ 69], b[ 70], #skip 71-72</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 73], b[ 74], b[ 75], b[ 76],</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 77], b[ 78], b[ 79], b[ 80], #skip 81-82</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 83], b[ 84], b[ 85], b[ 86],</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 87], b[ 88], b[ 89], b[ 90], #skip 91-92</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 93], b[ 94], b[ 95], b[ 96],</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 97], b[ 98], b[ 99], b[100], #skip 101-103</span><br><span style="color: hsl(120, 100%, 40%);">+            b[104], b[105], b[106], b[107]  #BCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            ], list(dst.get_burst_data()))</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        self.assertEqual([</span><br><span style="color: hsl(120, 100%, 40%);">+              1,   1,   1,   1, #BCCH</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2, #CCCH</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2,</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2,</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2,</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2,</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2,</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2,</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2,</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2,</span><br><span style="color: hsl(120, 100%, 40%);">+              1,   1,   1,   1, #BCCH</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2, #CCCH</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2,</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2,</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2,</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2,</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2,</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2,</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2,</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2,</span><br><span style="color: hsl(120, 100%, 40%);">+              1,   1,   1,   1, #BCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            ], list(dst.get_sub_types()))</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        self.assertEqual([</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #BCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #CCCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            1, 1, 1, 1,</span><br><span style="color: hsl(120, 100%, 40%);">+            2, 2, 2, 2,</span><br><span style="color: hsl(120, 100%, 40%);">+            3, 3, 3, 3,</span><br><span style="color: hsl(120, 100%, 40%);">+            4, 4, 4, 4,</span><br><span style="color: hsl(120, 100%, 40%);">+            5, 5, 5, 5,</span><br><span style="color: hsl(120, 100%, 40%);">+            6, 6, 6, 6,</span><br><span style="color: hsl(120, 100%, 40%);">+            7, 7, 7, 7,</span><br><span style="color: hsl(120, 100%, 40%);">+            8, 8, 8, 8, #CCCH 8</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #BCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #CCCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            1, 1, 1, 1,</span><br><span style="color: hsl(120, 100%, 40%);">+            2, 2, 2, 2,</span><br><span style="color: hsl(120, 100%, 40%);">+            3, 3, 3, 3,</span><br><span style="color: hsl(120, 100%, 40%);">+            4, 4, 4, 4,</span><br><span style="color: hsl(120, 100%, 40%);">+            5, 5, 5, 5,</span><br><span style="color: hsl(120, 100%, 40%);">+            6, 6, 6, 6,</span><br><span style="color: hsl(120, 100%, 40%);">+            7, 7, 7, 7,</span><br><span style="color: hsl(120, 100%, 40%);">+            8, 8, 8, 8, #CCCH 8</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #BCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            ], list(dst.get_sub_slots()))</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+    @unittest.expectedFailure</span><br><span style="color: hsl(120, 100%, 40%);">+    def test_uplink (self):</span><br><span style="color: hsl(120, 100%, 40%);">+        """</span><br><span style="color: hsl(120, 100%, 40%);">+           BCCH_CCCH demapper uplink test</span><br><span style="color: hsl(120, 100%, 40%);">+        """</span><br><span style="color: hsl(120, 100%, 40%);">+        src = grgsm.burst_source(test_data.frames, test_data.timeslots, test_data.bursts)</span><br><span style="color: hsl(120, 100%, 40%);">+        src.set_arfcn(0x2240); #uplink flag is 40</span><br><span style="color: hsl(120, 100%, 40%);">+        demapper = grgsm.gsm_bcch_ccch_demapper(timeslot_nr=0)</span><br><span style="color: hsl(120, 100%, 40%);">+        dst = grgsm.burst_sink()</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb.msg_connect(src, "out", demapper, "bursts")</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb.msg_connect(demapper, "bursts", dst, "in")</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb.run ()</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        b = test_data.bursts</span><br><span style="color: hsl(120, 100%, 40%);">+        self.assertEqual(b, list(dst.get_burst_data()))</span><br><span style="color: hsl(120, 100%, 40%);">+        self.assertEqual([3]*len(b), list(dst.get_sub_types()))</span><br><span style="color: hsl(120, 100%, 40%);">+        self.assertEqual([0]*len(b), list(dst.get_sub_slots()))</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+if __name__ == '__main__':</span><br><span style="color: hsl(120, 100%, 40%);">+    gr_unittest.run(qa_gsm_bcch_ccch_demapper, "qa_gsm_bcch_ccch_demapper.xml")</span><br><span>diff --git a/python/qa_gsm_bcch_ccch_sdcch4_demapper.py b/python/qa_gsm_bcch_ccch_sdcch4_demapper.py</span><br><span>new file mode 100644</span><br><span>index 0000000..c71a2e1</span><br><span>--- /dev/null</span><br><span>+++ b/python/qa_gsm_bcch_ccch_sdcch4_demapper.py</span><br><span>@@ -0,0 +1,211 @@</span><br><span style="color: hsl(120, 100%, 40%);">+#!/usr/bin/env python</span><br><span style="color: hsl(120, 100%, 40%);">+# -*- coding: utf-8 -*-</span><br><span style="color: hsl(120, 100%, 40%);">+# @file</span><br><span style="color: hsl(120, 100%, 40%);">+# @author (C) 2019 by Vasil Velichkov <vvvelichkov@gmail.com></span><br><span style="color: hsl(120, 100%, 40%);">+# @section LICENSE</span><br><span style="color: hsl(120, 100%, 40%);">+#</span><br><span style="color: hsl(120, 100%, 40%);">+# Gr-gsm is free software; you can redistribute it and/or modify</span><br><span style="color: hsl(120, 100%, 40%);">+# it under the terms of the GNU General Public License as published by</span><br><span style="color: hsl(120, 100%, 40%);">+# the Free Software Foundation; either version 3, or (at your option)</span><br><span style="color: hsl(120, 100%, 40%);">+# any later version.</span><br><span style="color: hsl(120, 100%, 40%);">+#</span><br><span style="color: hsl(120, 100%, 40%);">+# Gr-gsm is distributed in the hope that it will be useful,</span><br><span style="color: hsl(120, 100%, 40%);">+# but WITHOUT ANY WARRANTY; without even the implied warranty of</span><br><span style="color: hsl(120, 100%, 40%);">+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the</span><br><span style="color: hsl(120, 100%, 40%);">+# GNU General Public License for more details.</span><br><span style="color: hsl(120, 100%, 40%);">+#</span><br><span style="color: hsl(120, 100%, 40%);">+# You should have received a copy of the GNU General Public License</span><br><span style="color: hsl(120, 100%, 40%);">+# along with gr-gsm; see the file COPYING.  If not, write to</span><br><span style="color: hsl(120, 100%, 40%);">+# the Free Software Foundation, Inc., 51 Franklin Street,</span><br><span style="color: hsl(120, 100%, 40%);">+# Boston, MA 02110-1301, USA.</span><br><span style="color: hsl(120, 100%, 40%);">+#</span><br><span style="color: hsl(120, 100%, 40%);">+#</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+import unittest</span><br><span style="color: hsl(120, 100%, 40%);">+import numpy as np</span><br><span style="color: hsl(120, 100%, 40%);">+from gnuradio import gr, gr_unittest, blocks</span><br><span style="color: hsl(120, 100%, 40%);">+import grgsm</span><br><span style="color: hsl(120, 100%, 40%);">+import pmt</span><br><span style="color: hsl(120, 100%, 40%);">+import qa_gsm_demapper_data as test_data</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+class qa_bcch_ccch_sdcch4_demapper (gr_unittest.TestCase):</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+    def setUp (self):</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb = gr.top_block ()</span><br><span style="color: hsl(120, 100%, 40%);">+        self.maxDiff = None</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+    def tearDown (self):</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb = None</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+    @unittest.expectedFailure</span><br><span style="color: hsl(120, 100%, 40%);">+    def test_downlink (self):</span><br><span style="color: hsl(120, 100%, 40%);">+        """</span><br><span style="color: hsl(120, 100%, 40%);">+           BCCH_CCCH_SDCCH4 demapper downlink test</span><br><span style="color: hsl(120, 100%, 40%);">+        """</span><br><span style="color: hsl(120, 100%, 40%);">+        src = grgsm.burst_source(test_data.frames, test_data.timeslots, test_data.bursts)</span><br><span style="color: hsl(120, 100%, 40%);">+        src.set_arfcn(0); # downlink</span><br><span style="color: hsl(120, 100%, 40%);">+        demapper = grgsm.gsm_bcch_ccch_sdcch4_demapper(timeslot_nr=0)</span><br><span style="color: hsl(120, 100%, 40%);">+        dst = grgsm.burst_sink()</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb.msg_connect(src, "out", demapper, "bursts")</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb.msg_connect(demapper, "bursts", dst, "in")</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb.run ()</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        b = test_data.bursts</span><br><span style="color: hsl(120, 100%, 40%);">+        self.assertEqual([</span><br><span style="color: hsl(120, 100%, 40%);">+            b[  2], b[  3], b[  4], b[  5], #BCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            b[  6], b[  7], b[  8], b[  9], #CCCH    skip 2</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 12], b[ 13], b[ 14], b[ 15], #CCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 16], b[ 17], b[ 18], b[ 19], #CCCH    skip 2</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 22], b[ 23], b[ 24], b[ 25], #SDCCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 26], b[ 27], b[ 28], b[ 29], #SDCCH 1 skip 2</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 32], b[ 33], b[ 34], b[ 35], #SDCCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 36], b[ 37], b[ 38], b[ 39], #SDCCH 3 skip 2</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 42], b[ 43], b[ 44], b[ 45], #SACCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 46], b[ 47], b[ 48], b[ 49], #SACCH 1 skip 3</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 53], b[ 54], b[ 55], b[ 56], #BCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 57], b[ 58], b[ 59], b[ 60], #CCCH    skip 2</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 63], b[ 64], b[ 65], b[ 66], #CCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 67], b[ 68], b[ 69], b[ 70], #CCCH    skip 2</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 73], b[ 74], b[ 75], b[ 76], #SDCCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 77], b[ 78], b[ 79], b[ 80], #SDCCH 1 skip 2</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 83], b[ 84], b[ 85], b[ 86], #SDCCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 87], b[ 88], b[ 89], b[ 90], #SDCCH 3 skip 2</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 93], b[ 94], b[ 95], b[ 96], #SACCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 97], b[ 98], b[ 99], b[100], #SACCH 2 skip 3</span><br><span style="color: hsl(120, 100%, 40%);">+            b[104], b[105], b[106], b[107]  #BCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            ], list(dst.get_burst_data()))</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        self.assertEqual([</span><br><span style="color: hsl(120, 100%, 40%);">+              1,   1,   1,   1, #BCCH</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2, #CCCH</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2, #CCCH</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2, #CCCH</span><br><span style="color: hsl(120, 100%, 40%);">+              7,   7,   7,   7, #SDCCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+              7,   7,   7,   7, #SDCCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+              7,   7,   7,   7, #SDCCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+              7,   7,   7,   7, #SDCCH 3</span><br><span style="color: hsl(120, 100%, 40%);">+            135, 135, 135, 135, #SACCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            135, 135, 135, 135, #SACCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+              1,   1,   1,   1, #BCCH</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2, #CCCH</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2, #CCCH</span><br><span style="color: hsl(120, 100%, 40%);">+              2,   2,   2,   2, #CCCH</span><br><span style="color: hsl(120, 100%, 40%);">+              7,   7,   7,   7, #SDCCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+              7,   7,   7,   7, #SDCCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+              7,   7,   7,   7, #SDCCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+              7,   7,   7,   7, #SDCCH 3</span><br><span style="color: hsl(120, 100%, 40%);">+            135, 135, 135, 135, #SACCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+            135, 135, 135, 135, #SACCH 3</span><br><span style="color: hsl(120, 100%, 40%);">+              1,   1,   1,   1, #BCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            ], list(dst.get_sub_types()))</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        self.assertEqual([</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #BCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #CCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            1, 1, 1, 1, #CCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            2, 2, 2, 2, #CCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #SDCCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            1, 1, 1, 1, #SDCCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+            2, 2, 2, 2, #SDCCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+            3, 3, 3, 3, #SDCCH 3</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #SACCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            1, 1, 1, 1, #SACCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #BCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #CCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            1, 1, 1, 1, #CCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            2, 2, 2, 2, #CCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #SDCCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            1, 1, 1, 1, #SDCCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+            2, 2, 2, 2, #SDCCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+            3, 3, 3, 3, #SDCCH 3</span><br><span style="color: hsl(120, 100%, 40%);">+            2, 2, 2, 2, #SACCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+            3, 3, 3, 3, #SACCH 3</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #BCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            ], list(dst.get_sub_slots()))</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+    @unittest.expectedFailure</span><br><span style="color: hsl(120, 100%, 40%);">+    def test_uplink (self):</span><br><span style="color: hsl(120, 100%, 40%);">+        """</span><br><span style="color: hsl(120, 100%, 40%);">+           BCCH_CCCH_SDCCH4 demapper uplink test</span><br><span style="color: hsl(120, 100%, 40%);">+        """</span><br><span style="color: hsl(120, 100%, 40%);">+        src = grgsm.burst_source(test_data.frames, test_data.timeslots, test_data.bursts)</span><br><span style="color: hsl(120, 100%, 40%);">+        src.set_arfcn(0x2240); #uplink flag is 40</span><br><span style="color: hsl(120, 100%, 40%);">+        demapper = grgsm.gsm_bcch_ccch_sdcch4_demapper(timeslot_nr=0)</span><br><span style="color: hsl(120, 100%, 40%);">+        dst = grgsm.burst_sink()</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb.msg_connect(src, "out", demapper, "bursts")</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb.msg_connect(demapper, "bursts", dst, "in")</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb.run ()</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        b = test_data.bursts</span><br><span style="color: hsl(120, 100%, 40%);">+        self.assertEqual(b, list(dst.get_burst_data()))</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        self.assertEqual([</span><br><span style="color: hsl(120, 100%, 40%);">+              7,   7,   7,   7, #SDCCH 3</span><br><span style="color: hsl(120, 100%, 40%);">+              3,   3,           #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+            135, 135, 135, 135, #SACCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+            135, 135, 135, 135, #SACCH 3</span><br><span style="color: hsl(120, 100%, 40%);">+              3,   3,   3,   3, #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+              3,   3,   3,   3, #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+              3,   3,   3,   3, #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+              3,   3,   3,   3, #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+              3,   3,   3,   3, #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+              3,   3,   3,      #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+              7,   7,   7,   7, #SDCCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+              7,   7,   7,   7, #SDCCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+              3,   3,           #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+              7,   7,   7,   7, #SDCCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+              7,   7,   7,   7, #SDCCH 3</span><br><span style="color: hsl(120, 100%, 40%);">+              3,   3,           #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+            135, 135, 135, 135, #SACCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            135, 135, 135, 135, #SACCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+              3,   3,   3,   3, #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+              3,   3,   3,   3, #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+              3,   3,   3,   3, #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+              3,   3,   3,   3, #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+              3,   3,   3,   3, #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+              3,   3,   3,      #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+              7,   7,   7,   7, #SDCCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+              7,   7,   7,   7, #SDCCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+              3,   3,           #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+              7,   7,   7,   7, #SDCCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+              7,   7,   7,   7, #SDCCH 3</span><br><span style="color: hsl(120, 100%, 40%);">+              3,   3,           #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+            ], list(dst.get_sub_types()))</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        self.assertEqual([</span><br><span style="color: hsl(120, 100%, 40%);">+            3, 3, 3, 3, #SDCCH 3</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0,       #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+            2, 2, 2, 2, #SACCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+            3, 3, 3, 3, #SACCH 3</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0,    #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #SDCCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            1, 1, 1, 1, #SDCCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0,       #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+            2, 2, 2, 2, #SDCCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+            3, 3, 3, 3, #SDCCH 3</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0,       #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #SACCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            1, 1, 1, 1, #SACCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0,    #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #SDCCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            1, 1, 1, 1, #SDCCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0,       #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+            2, 2, 2, 2, #SDCCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+            3, 3, 3, 3, #SDCCH 3</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0,       #RACCH</span><br><span style="color: hsl(120, 100%, 40%);">+            ], list(dst.get_sub_slots()))</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+if __name__ == '__main__':</span><br><span style="color: hsl(120, 100%, 40%);">+    gr_unittest.run(qa_bcch_ccch_sdcch4_demapper, "qa_bcch_ccch_sdcch4_demapper.xml")</span><br><span>diff --git a/python/qa_gsm_demapper_data.py b/python/qa_gsm_demapper_data.py</span><br><span>new file mode 100644</span><br><span>index 0000000..7554af5</span><br><span>--- /dev/null</span><br><span>+++ b/python/qa_gsm_demapper_data.py</span><br><span>@@ -0,0 +1,26 @@</span><br><span style="color: hsl(120, 100%, 40%);">+#!/usr/bin/env python</span><br><span style="color: hsl(120, 100%, 40%);">+# -*- coding: utf-8 -*-</span><br><span style="color: hsl(120, 100%, 40%);">+# @file</span><br><span style="color: hsl(120, 100%, 40%);">+# @author (C) 2019 by Vasil Velichkov <vvvelichkov@gmail.com></span><br><span style="color: hsl(120, 100%, 40%);">+# @section LICENSE</span><br><span style="color: hsl(120, 100%, 40%);">+#</span><br><span style="color: hsl(120, 100%, 40%);">+# Gr-gsm is free software; you can redistribute it and/or modify</span><br><span style="color: hsl(120, 100%, 40%);">+# it under the terms of the GNU General Public License as published by</span><br><span style="color: hsl(120, 100%, 40%);">+# the Free Software Foundation; either version 3, or (at your option)</span><br><span style="color: hsl(120, 100%, 40%);">+# any later version.</span><br><span style="color: hsl(120, 100%, 40%);">+#</span><br><span style="color: hsl(120, 100%, 40%);">+# Gr-gsm is distributed in the hope that it will be useful,</span><br><span style="color: hsl(120, 100%, 40%);">+# but WITHOUT ANY WARRANTY; without even the implied warranty of</span><br><span style="color: hsl(120, 100%, 40%);">+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the</span><br><span style="color: hsl(120, 100%, 40%);">+# GNU General Public License for more details.</span><br><span style="color: hsl(120, 100%, 40%);">+#</span><br><span style="color: hsl(120, 100%, 40%);">+# You should have received a copy of the GNU General Public License</span><br><span style="color: hsl(120, 100%, 40%);">+# along with gr-gsm; see the file COPYING.  If not, write to</span><br><span style="color: hsl(120, 100%, 40%);">+# the Free Software Foundation, Inc., 51 Franklin Street,</span><br><span style="color: hsl(120, 100%, 40%);">+# Boston, MA 02110-1301, USA.</span><br><span style="color: hsl(120, 100%, 40%);">+#</span><br><span style="color: hsl(120, 100%, 40%);">+#</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+bursts = [format((2**(i+1))-1, '0<148b') for i in range(0,108)]</span><br><span style="color: hsl(120, 100%, 40%);">+frames = range(0, 108)</span><br><span style="color: hsl(120, 100%, 40%);">+timeslots = [0] * len(frames)</span><br><span>diff --git a/python/qa_gsm_sdcch8_demapper.py b/python/qa_gsm_sdcch8_demapper.py</span><br><span>new file mode 100644</span><br><span>index 0000000..83d745c</span><br><span>--- /dev/null</span><br><span>+++ b/python/qa_gsm_sdcch8_demapper.py</span><br><span>@@ -0,0 +1,239 @@</span><br><span style="color: hsl(120, 100%, 40%);">+#!/usr/bin/env python</span><br><span style="color: hsl(120, 100%, 40%);">+# -*- coding: utf-8 -*-</span><br><span style="color: hsl(120, 100%, 40%);">+# @file</span><br><span style="color: hsl(120, 100%, 40%);">+# @author (C) 2019 by Vasil Velichkov <vvvelichkov@gmail.com></span><br><span style="color: hsl(120, 100%, 40%);">+# @section LICENSE</span><br><span style="color: hsl(120, 100%, 40%);">+#</span><br><span style="color: hsl(120, 100%, 40%);">+# Gr-gsm is free software; you can redistribute it and/or modify</span><br><span style="color: hsl(120, 100%, 40%);">+# it under the terms of the GNU General Public License as published by</span><br><span style="color: hsl(120, 100%, 40%);">+# the Free Software Foundation; either version 3, or (at your option)</span><br><span style="color: hsl(120, 100%, 40%);">+# any later version.</span><br><span style="color: hsl(120, 100%, 40%);">+#</span><br><span style="color: hsl(120, 100%, 40%);">+# Gr-gsm is distributed in the hope that it will be useful,</span><br><span style="color: hsl(120, 100%, 40%);">+# but WITHOUT ANY WARRANTY; without even the implied warranty of</span><br><span style="color: hsl(120, 100%, 40%);">+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the</span><br><span style="color: hsl(120, 100%, 40%);">+# GNU General Public License for more details.</span><br><span style="color: hsl(120, 100%, 40%);">+#</span><br><span style="color: hsl(120, 100%, 40%);">+# You should have received a copy of the GNU General Public License</span><br><span style="color: hsl(120, 100%, 40%);">+# along with gr-gsm; see the file COPYING.  If not, write to</span><br><span style="color: hsl(120, 100%, 40%);">+# the Free Software Foundation, Inc., 51 Franklin Street,</span><br><span style="color: hsl(120, 100%, 40%);">+# Boston, MA 02110-1301, USA.</span><br><span style="color: hsl(120, 100%, 40%);">+#</span><br><span style="color: hsl(120, 100%, 40%);">+#</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+import unittest</span><br><span style="color: hsl(120, 100%, 40%);">+import numpy as np</span><br><span style="color: hsl(120, 100%, 40%);">+from gnuradio import gr, gr_unittest, blocks</span><br><span style="color: hsl(120, 100%, 40%);">+import grgsm</span><br><span style="color: hsl(120, 100%, 40%);">+import pmt</span><br><span style="color: hsl(120, 100%, 40%);">+import qa_gsm_demapper_data as test_data</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+class qa_gsm_sdcch8_demapper (gr_unittest.TestCase):</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+    def setUp (self):</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb = gr.top_block ()</span><br><span style="color: hsl(120, 100%, 40%);">+        self.maxDiff = None</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+    def tearDown (self):</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb = None</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+    @unittest.expectedFailure</span><br><span style="color: hsl(120, 100%, 40%);">+    def test_downlink (self):</span><br><span style="color: hsl(120, 100%, 40%);">+        """</span><br><span style="color: hsl(120, 100%, 40%);">+           SDCCH8 demapper downlink test</span><br><span style="color: hsl(120, 100%, 40%);">+        """</span><br><span style="color: hsl(120, 100%, 40%);">+        src = grgsm.burst_source(test_data.frames, test_data.timeslots, test_data.bursts)</span><br><span style="color: hsl(120, 100%, 40%);">+        src.set_arfcn(0); # downlink</span><br><span style="color: hsl(120, 100%, 40%);">+        demapper = grgsm.gsm_sdcch8_demapper(timeslot_nr=0)</span><br><span style="color: hsl(120, 100%, 40%);">+        dst = grgsm.burst_sink()</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb.msg_connect(src, "out", demapper, "bursts")</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb.msg_connect(demapper, "bursts", dst, "in")</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb.run ()</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        b = test_data.bursts</span><br><span style="color: hsl(120, 100%, 40%);">+        self.assertEqual([</span><br><span style="color: hsl(120, 100%, 40%);">+            b[  0], b[  1], b[  2], b[  3], #SDCCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            b[  4], b[  5], b[  6], b[  7], #SDCCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+            b[  8], b[  9], b[ 10], b[ 11], #SDCCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 12], b[ 13], b[ 14], b[ 15], #SDCCH 3</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 16], b[ 17], b[ 18], b[ 19], #SDCCH 4</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 20], b[ 21], b[ 22], b[ 23], #SDCCH 5</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 24], b[ 25], b[ 26], b[ 27], #SDCCH 6</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 28], b[ 29], b[ 30], b[ 31], #SDCCH 7</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 32], b[ 33], b[ 34], b[ 35], #SACCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 36], b[ 37], b[ 38], b[ 39], #SACCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 40], b[ 41], b[ 42], b[ 43], #SACCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 44], b[ 45], b[ 46], b[ 47], #SACCH 3 #skip 48-50</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 51], b[ 52], b[ 53], b[ 54], #SDCCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 55], b[ 56], b[ 57], b[ 58], #SDCCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 59], b[ 60], b[ 61], b[ 62], #SDCCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 63], b[ 64], b[ 65], b[ 66], #SDCCH 3</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 67], b[ 68], b[ 69], b[ 70], #SDCCH 4</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 71], b[ 72], b[ 73], b[ 74], #SDCCH 5</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 75], b[ 76], b[ 77], b[ 78], #SDCCH 6</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 79], b[ 80], b[ 81], b[ 82], #SDCCH 7</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 83], b[ 84], b[ 85], b[ 86], #SACCH 4</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 87], b[ 88], b[ 89], b[ 90], #SACCH 5</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 91], b[ 92], b[ 93], b[ 94], #SACCH 6</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 95], b[ 96], b[ 97], b[ 98], #SACCH 7 #skip 99-101</span><br><span style="color: hsl(120, 100%, 40%);">+            b[102], b[103], b[104], b[105], #SDCCH</span><br><span style="color: hsl(120, 100%, 40%);">+            ], list(dst.get_burst_data()))</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        self.assertEqual([</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+            136, 136, 136, 136,</span><br><span style="color: hsl(120, 100%, 40%);">+            136, 136, 136, 136,</span><br><span style="color: hsl(120, 100%, 40%);">+            136, 136, 136, 136,</span><br><span style="color: hsl(120, 100%, 40%);">+            136, 136, 136, 136,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+            136, 136, 136, 136,</span><br><span style="color: hsl(120, 100%, 40%);">+            136, 136, 136, 136,</span><br><span style="color: hsl(120, 100%, 40%);">+            136, 136, 136, 136,</span><br><span style="color: hsl(120, 100%, 40%);">+            136, 136, 136, 136,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+            ], list(dst.get_sub_types()))</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        self.assertEqual([</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0,</span><br><span style="color: hsl(120, 100%, 40%);">+            1, 1, 1, 1,</span><br><span style="color: hsl(120, 100%, 40%);">+            2, 2, 2, 2,</span><br><span style="color: hsl(120, 100%, 40%);">+            3, 3, 3, 3,</span><br><span style="color: hsl(120, 100%, 40%);">+            4, 4, 4, 4,</span><br><span style="color: hsl(120, 100%, 40%);">+            5, 5, 5, 5,</span><br><span style="color: hsl(120, 100%, 40%);">+            6, 6, 6, 6,</span><br><span style="color: hsl(120, 100%, 40%);">+            7, 7, 7, 7,</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #SACCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            1, 1, 1, 1, #SACCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+            2, 2, 2, 2, #SACCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+            3, 3, 3, 3, #SACCH 3</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0,</span><br><span style="color: hsl(120, 100%, 40%);">+            1, 1, 1, 1,</span><br><span style="color: hsl(120, 100%, 40%);">+            2, 2, 2, 2,</span><br><span style="color: hsl(120, 100%, 40%);">+            3, 3, 3, 3,</span><br><span style="color: hsl(120, 100%, 40%);">+            4, 4, 4, 4,</span><br><span style="color: hsl(120, 100%, 40%);">+            5, 5, 5, 5,</span><br><span style="color: hsl(120, 100%, 40%);">+            6, 6, 6, 6,</span><br><span style="color: hsl(120, 100%, 40%);">+            7, 7, 7, 7,</span><br><span style="color: hsl(120, 100%, 40%);">+            4, 4, 4, 4, #SACCH 4</span><br><span style="color: hsl(120, 100%, 40%);">+            5, 5, 5, 5, #SACCH 5</span><br><span style="color: hsl(120, 100%, 40%);">+            6, 6, 6, 6, #SACCH 6</span><br><span style="color: hsl(120, 100%, 40%);">+            7, 7, 7, 7, #SACCH 7</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0,</span><br><span style="color: hsl(120, 100%, 40%);">+            ], list(dst.get_sub_slots()))</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+    @unittest.expectedFailure</span><br><span style="color: hsl(120, 100%, 40%);">+    def test_uplink (self):</span><br><span style="color: hsl(120, 100%, 40%);">+        """</span><br><span style="color: hsl(120, 100%, 40%);">+           BCCH_CCCH_SDCCH4 demapper uplink test</span><br><span style="color: hsl(120, 100%, 40%);">+        """</span><br><span style="color: hsl(120, 100%, 40%);">+        src = grgsm.burst_source(test_data.frames, test_data.timeslots, test_data.bursts)</span><br><span style="color: hsl(120, 100%, 40%);">+        src.set_arfcn(0x2240); #uplink flag is 40</span><br><span style="color: hsl(120, 100%, 40%);">+        demapper = grgsm.gsm_sdcch8_demapper(timeslot_nr=0)</span><br><span style="color: hsl(120, 100%, 40%);">+        dst = grgsm.burst_sink()</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb.msg_connect(src, "out", demapper, "bursts")</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb.msg_connect(demapper, "bursts", dst, "in")</span><br><span style="color: hsl(120, 100%, 40%);">+        self.tb.run ()</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        b = test_data.bursts</span><br><span style="color: hsl(120, 100%, 40%);">+        self.assertEqual([</span><br><span style="color: hsl(120, 100%, 40%);">+            b[  0], b[  1], b[  2], b[  3], #SACCH 5</span><br><span style="color: hsl(120, 100%, 40%);">+            b[  4], b[  5], b[  6], b[  7], #SACCH 6</span><br><span style="color: hsl(120, 100%, 40%);">+            b[  8], b[  9], b[ 10], b[ 11], #SACCH 7 #skip 12-14</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 15], b[ 16], b[ 17], b[ 18], #SDCCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 19], b[ 20], b[ 21], b[ 22], #SDCCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 23], b[ 24], b[ 25], b[ 26], #SDCCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 27], b[ 28], b[ 29], b[ 30], #SDCCH 3</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 31], b[ 32], b[ 33], b[ 34], #SDCCH 4</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 35], b[ 36], b[ 37], b[ 38], #SDCCH 5</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 39], b[ 40], b[ 41], b[ 42], #SDCCH 6</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 43], b[ 44], b[ 45], b[ 46], #SDCCH 7</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 47], b[ 48], b[ 49], b[ 50], #SACCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 51], b[ 52], b[ 53], b[ 54], #SACCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 55], b[ 56], b[ 57], b[ 58], #SACCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 59], b[ 60], b[ 61], b[ 62], #SACCH 3 #skip 63-65</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 66], b[ 67], b[ 68], b[ 69], #SDCCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 70], b[ 71], b[ 72], b[ 73], #SDCCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 74], b[ 75], b[ 76], b[ 77], #SDCCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 78], b[ 79], b[ 80], b[ 81], #SDCCH 3</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 82], b[ 83], b[ 84], b[ 85], #SDCCH 4</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 86], b[ 87], b[ 88], b[ 89], #SDCCH 5</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 90], b[ 91], b[ 92], b[ 93], #SDCCH 6</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 94], b[ 95], b[ 96], b[ 97], #SDCCH 7</span><br><span style="color: hsl(120, 100%, 40%);">+            b[ 98], b[ 99], b[100], b[101], #SACCH 4</span><br><span style="color: hsl(120, 100%, 40%);">+            b[102], b[103], b[104], b[105], #SACCH 5</span><br><span style="color: hsl(120, 100%, 40%);">+            ], list(dst.get_burst_data()))</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        self.assertEqual([</span><br><span style="color: hsl(120, 100%, 40%);">+            136, 136, 136, 136,</span><br><span style="color: hsl(120, 100%, 40%);">+            136, 136, 136, 136,</span><br><span style="color: hsl(120, 100%, 40%);">+            136, 136, 136, 136,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+            136, 136, 136, 136,</span><br><span style="color: hsl(120, 100%, 40%);">+            136, 136, 136, 136,</span><br><span style="color: hsl(120, 100%, 40%);">+            136, 136, 136, 136,</span><br><span style="color: hsl(120, 100%, 40%);">+            136, 136, 136, 136,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+              8,   8,   8,   8,</span><br><span style="color: hsl(120, 100%, 40%);">+            136, 136, 136, 136,</span><br><span style="color: hsl(120, 100%, 40%);">+            136, 136, 136, 136,</span><br><span style="color: hsl(120, 100%, 40%);">+            ], list(dst.get_sub_types()))</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+        self.assertEqual([</span><br><span style="color: hsl(120, 100%, 40%);">+            5, 5, 5, 5, #SACCH 5</span><br><span style="color: hsl(120, 100%, 40%);">+            6, 6, 6, 6, #SACCH 6</span><br><span style="color: hsl(120, 100%, 40%);">+            7, 7, 7, 7, #SACCH 7</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0,</span><br><span style="color: hsl(120, 100%, 40%);">+            1, 1, 1, 1,</span><br><span style="color: hsl(120, 100%, 40%);">+            2, 2, 2, 2,</span><br><span style="color: hsl(120, 100%, 40%);">+            3, 3, 3, 3,</span><br><span style="color: hsl(120, 100%, 40%);">+            4, 4, 4, 4,</span><br><span style="color: hsl(120, 100%, 40%);">+            5, 5, 5, 5,</span><br><span style="color: hsl(120, 100%, 40%);">+            6, 6, 6, 6,</span><br><span style="color: hsl(120, 100%, 40%);">+            7, 7, 7, 7,</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0, #SACCH 0</span><br><span style="color: hsl(120, 100%, 40%);">+            1, 1, 1, 1, #SACCH 1</span><br><span style="color: hsl(120, 100%, 40%);">+            2, 2, 2, 2, #SACCH 2</span><br><span style="color: hsl(120, 100%, 40%);">+            3, 3, 3, 3, #SACCH 3</span><br><span style="color: hsl(120, 100%, 40%);">+            0, 0, 0, 0,</span><br><span style="color: hsl(120, 100%, 40%);">+            1, 1, 1, 1,</span><br><span style="color: hsl(120, 100%, 40%);">+            2, 2, 2, 2,</span><br><span style="color: hsl(120, 100%, 40%);">+            3, 3, 3, 3,</span><br><span style="color: hsl(120, 100%, 40%);">+            4, 4, 4, 4,</span><br><span style="color: hsl(120, 100%, 40%);">+            5, 5, 5, 5,</span><br><span style="color: hsl(120, 100%, 40%);">+            6, 6, 6, 6,</span><br><span style="color: hsl(120, 100%, 40%);">+            7, 7, 7, 7,</span><br><span style="color: hsl(120, 100%, 40%);">+            4, 4, 4, 4, #SACCH 4</span><br><span style="color: hsl(120, 100%, 40%);">+            5, 5, 5, 5,</span><br><span style="color: hsl(120, 100%, 40%);">+            ], list(dst.get_sub_slots()))</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+if __name__ == '__main__':</span><br><span style="color: hsl(120, 100%, 40%);">+    gr_unittest.run(qa_gsm_sdcch8_demapper, "qa_gsm_sdcch8_demapper.xml")</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.osmocom.org/c/gr-gsm/+/14945">change 14945</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.osmocom.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.osmocom.org/c/gr-gsm/+/14945"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: gr-gsm </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-Change-Id: I33b0948832a0c2506bffd389cc134c3236c74d27 </div>
<div style="display:none"> Gerrit-Change-Number: 14945 </div>
<div style="display:none"> Gerrit-PatchSet: 2 </div>
<div style="display:none"> Gerrit-Owner: vvvelichkov <vvvelichkov@gmail.com> </div>
<div style="display:none"> Gerrit-Reviewer: fixeria <axilirator@gmail.com> </div>
<div style="display:none"> Gerrit-Reviewer: laforge <laforge@gnumonks.org> </div>
<div style="display:none"> Gerrit-Reviewer: ptrkrysik <ptrkrysik@gmail.com> </div>
<div style="display:none"> Gerrit-Reviewer: vvvelichkov <vvvelichkov@gmail.com> </div>
<div style="display:none"> Gerrit-MessageType: merged </div>