GNSS-SDR  0.0.19
An Open Source GNSS Software Defined Receiver
unpack_byte_2bit_cpx_samples.h
Go to the documentation of this file.
1 /*!
2  * \file unpack_byte_2bit_cpx_samples.h
3  *
4  * \brief Unpacks byte samples to 2 bits complex samples.
5  * Packing Order
6  * Most Significant Nibble - Sample n
7  * Least Significant Nibble - Sample n+1
8  * Packing order in Nibble Q1 Q0 I1 I0
9  * \author Javier Arribas jarribas (at) cttc.es
10  *
11  * -----------------------------------------------------------------------------
12  *
13  * GNSS-SDR is a Global Navigation Satellite System software-defined receiver.
14  * This file is part of GNSS-SDR.
15  *
16  * Copyright (C) 2010-2020 (see AUTHORS file for a list of contributors)
17  * SPDX-License-Identifier: GPL-3.0-or-later
18  *
19  * -----------------------------------------------------------------------------
20  */
21 
22 #ifndef GNSS_SDR_UNPACK_BYTE_2BIT_CPX_SAMPLES_H
23 #define GNSS_SDR_UNPACK_BYTE_2BIT_CPX_SAMPLES_H
24 
25 #include "gnss_block_interface.h"
26 #include <gnuradio/sync_interpolator.h>
27 
28 /** \addtogroup Signal_Source
29  * \{ */
30 /** \addtogroup Signal_Source_gnuradio_blocks
31  * \{ */
32 
33 
35 
36 using unpack_byte_2bit_cpx_samples_sptr = gnss_shared_ptr<unpack_byte_2bit_cpx_samples>;
37 
38 unpack_byte_2bit_cpx_samples_sptr make_unpack_byte_2bit_cpx_samples();
39 
40 /*!
41  * \brief This class implements conversion between byte packet samples to 2bit_cpx samples
42  * 1 byte = 2 x complex 2bit I, + 2bit Q samples
43  */
44 class unpack_byte_2bit_cpx_samples : public gr::sync_interpolator
45 {
46 public:
48  ~unpack_byte_2bit_cpx_samples() = default;
49  int work(int noutput_items,
50  gr_vector_const_void_star &input_items,
51  gr_vector_void_star &output_items);
52 
53 private:
54  friend unpack_byte_2bit_cpx_samples_sptr make_unpack_byte_2bit_cpx_samples_sptr();
55 };
56 
57 
58 /** \} */
59 /** \} */
60 #endif // GNSS_SDR_UNPACK_BYTE_2BIT_CPX_SAMPLES_H
This class implements conversion between byte packet samples to 2bit_cpx samples 1 byte = 2 x complex...
This interface represents a GNSS block.