GNU Radio Manual and C++ API Reference
3.8.1.0
The Free & Open Software Radio Ecosystem
correlate_access_code_ff_ts.h
Go to the documentation of this file.
1
/* -*- c++ -*- */
2
/*
3
* Copyright 2014 Free Software Foundation, Inc.
4
*
5
* This file is part of GNU Radio
6
*
7
* GNU Radio is free software; you can redistribute it and/or modify
8
* it under the terms of the GNU General Public License as published by
9
* the Free Software Foundation; either version 3, or (at your option)
10
* any later version.
11
*
12
* GNU Radio is distributed in the hope that it will be useful,
13
* but WITHOUT ANY WARRANTY; without even the implied warranty of
14
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
* GNU General Public License for more details.
16
*
17
* You should have received a copy of the GNU General Public License
18
* along with GNU Radio; see the file COPYING. If not, write to
19
* the Free Software Foundation, Inc., 51 Franklin Street,
20
* Boston, MA 02110-1301, USA.
21
*/
22
23
#ifndef INCLUDED_DIGITAL_CORRELATE_ACCESS_CODE_FF_TS_H
24
#define INCLUDED_DIGITAL_CORRELATE_ACCESS_CODE_FF_TS_H
25
26
#include <
gnuradio/block.h
>
27
#include <
gnuradio/digital/api.h
>
28
#include <string>
29
30
namespace
gr
{
31
namespace
digital {
32
33
/*!
34
* \brief Examine input for specified access code, one bit at a time.
35
* \ingroup packet_operators_blk
36
*
37
* \details
38
* input: stream of floats (generally, soft decisions)
39
* output: a tagged stream set of samples from the payload following
40
* the access code and header.
41
*
42
* This block searches for the given access code by slicing the
43
* soft decision symbol inputs. Once found, it expects the
44
* following 32 samples to contain a header that includes the
45
* frame length (16 bits for the length, repeated). It decodes the
46
* header to get the frame length in order to set up the the
47
* tagged stream key information.
48
*
49
* The output of this block is appropriate for use with tagged
50
* stream blocks.
51
*/
52
class
DIGITAL_API
correlate_access_code_ff_ts
:
virtual
public
block
53
{
54
public
:
55
// gr::digital::correlate_access_code_ff_ts::sptr
56
typedef
boost::shared_ptr<correlate_access_code_ff_ts>
sptr
;
57
58
/*!
59
* \param access_code is represented with 1 byte per bit,
60
* e.g., "010101010111000100"
61
* \param threshold maximum number of bits that may be wrong
62
* \param tag_name key of the tag inserted into the tag stream
63
*/
64
static
sptr
65
make(
const
std::string& access_code,
int
threshold,
const
std::string& tag_name);
66
67
/*!
68
* \param access_code is represented with 1 byte per bit,
69
* e.g., "010101010111000100"
70
*/
71
virtual
bool
set_access_code(
const
std::string& access_code) = 0;
72
virtual
unsigned
long
long
access_code()
const
= 0;
73
};
74
75
}
/* namespace digital */
76
}
/* namespace gr */
77
78
#endif
/* INCLUDED_DIGITAL_CORRELATE_ACCESS_CODE_FF_TS_H */
block.h
gr::digital::correlate_access_code_ff_ts::sptr
boost::shared_ptr< correlate_access_code_ff_ts > sptr
Definition:
correlate_access_code_ff_ts.h:56
gr::digital::correlate_access_code_ff_ts
Examine input for specified access code, one bit at a time.
Definition:
correlate_access_code_ff_ts.h:52
DIGITAL_API
#define DIGITAL_API
Definition:
gr-digital/include/gnuradio/digital/api.h:30
gr::block
The abstract base class for all 'terminal' processing blocks.
Definition:
block.h:71
api.h
gr
GNU Radio logging wrapper for log4cpp library (C++ port of log4j)
Definition:
basic_block.h:43
gr-digital
include
gnuradio
digital
correlate_access_code_ff_ts.h
Generated by
1.8.16