GNU Radio's IRIDIUM Package
frame_sorter_impl.h
Go to the documentation of this file.
1/* -*- c++ -*- */
2/*
3 * Copyright 2021 gr-iridium author.
4 *
5 * SPDX-License-Identifier: GPL-3.0-or-later
6 */
7
8#ifndef INCLUDED_IRIDIUM_FRAME_SORTER_CPP_IMPL_H
9#define INCLUDED_IRIDIUM_FRAME_SORTER_CPP_IMPL_H
10
12
13namespace gr {
14namespace iridium {
15
16class frame
17{
18public:
19 // Needs to be a signed integer for std::abs to be available
20 int64_t timestamp;
22
23 friend bool operator<(const frame& l, const frame& r)
24 {
25 return std::tie(l.timestamp, l.center_frequency) <
26 std::tie(r.timestamp, r.center_frequency);
27 }
28};
29
30
32{
33private:
34 std::map<frame, pmt::pmt_t> frames;
35
36 void handler(const pmt::pmt_t& msg);
37
38
39public:
42
43 bool stop();
44
45 // Where all the action really happens
46 int work(int noutput_items,
47 gr_vector_const_void_star& input_items,
48 gr_vector_void_star& output_items);
49};
50
51} // namespace iridium
52} // namespace gr
53
54#endif /* INCLUDED_IRIDIUM_FRAME_SORTER_CPP_IMPL_H */
int work(int noutput_items, gr_vector_const_void_star &input_items, gr_vector_void_star &output_items)
<+description of block+>
Definition frame_sorter.h:23
Definition frame_sorter_impl.h:17
int64_t timestamp
Definition frame_sorter_impl.h:20
friend bool operator<(const frame &l, const frame &r)
Definition frame_sorter_impl.h:23
double center_frequency
Definition frame_sorter_impl.h:21
Definition burst_downmix.h:28
Definition burst_downmix.h:27