From 10cd1f4aabd38a8bb2f44f16d3f4eef5adb267f9 Mon Sep 17 00:00:00 2001 From: piotr Date: Thu, 17 Apr 2014 23:34:39 +0200 Subject: Corrected bcch get block so it writes all bursts forming bcch channel to the output --- lib/get_ccch_bursts_impl.cc | 7 +++---- lib/get_ccch_bursts_impl.h | 4 +++- 2 files changed, 6 insertions(+), 5 deletions(-) (limited to 'lib') diff --git a/lib/get_ccch_bursts_impl.cc b/lib/get_ccch_bursts_impl.cc index d75d8b1..066382b 100644 --- a/lib/get_ccch_bursts_impl.cc +++ b/lib/get_ccch_bursts_impl.cc @@ -35,7 +35,6 @@ namespace gr { pmt::pmt_t content = pmt::cdr(msg); gsmtap_hdr * header = (gsmtap_hdr *)pmt::blob_data(header_blob); uint32_t frame_nr = header->frame_number; - pmt::pmt_t msgs[4]; uint32_t frame_numbers[4]; uint32_t fn_mod51 = header->frame_number % 51; @@ -43,7 +42,7 @@ namespace gr { if(fn_mod51>=2 && fn_mod51<=5){ uint32_t ii = fn_mod51-2; frame_numbers[ii]=header->frame_number; - msgs[ii] = msg; + d_msgs[ii] = msg; } if(fn_mod51==5){ @@ -57,8 +56,8 @@ namespace gr { } if(frames_are_consecutive){ //send bursts to the output - for(int jj=1; jj<4; jj++){ - message_port_pub(pmt::mp("bursts_out"), msgs[jj]); + for(int jj=0; jj<4; jj++){ + message_port_pub(pmt::mp("bursts_out"), d_msgs[jj]); } } } diff --git a/lib/get_ccch_bursts_impl.h b/lib/get_ccch_bursts_impl.h index 992b181..773a0a4 100644 --- a/lib/get_ccch_bursts_impl.h +++ b/lib/get_ccch_bursts_impl.h @@ -28,7 +28,9 @@ namespace gr { namespace gsm { class get_ccch_bursts_impl : public get_ccch_bursts - { + { + private: + pmt::pmt_t d_msgs[4]; public: get_ccch_bursts_impl(); ~get_ccch_bursts_impl(); -- cgit v1.2.3