GNU Radio's IEEE802 Package
rime_connection.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2013 Christoph Leitner <c.leitner@student.uibk.ac.at>
3 *
4 * This program is free software: you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation, either version 3 of the License, or
7 * (at your option) any later version.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 */
17#ifndef INCLUDED_RIME_CONNECTION_H
18#define INCLUDED_RIME_CONNECTION_H
19
20#include <ieee802_15_4/api.h>
22#include <gnuradio/block_detail.h>
23
24namespace gr{
25 namespace ieee802_15_4{
27 protected:
29 uint16_t d_channel;
30 pmt::pmt_t d_inport;
31 pmt::pmt_t d_outport;
32 pmt::pmt_t d_mac_outport;
33 uint8_t d_rime_add_mine[2];
34
35 public:
36 static std::string msg_to_string(pmt::pmt_t msg);
37 rime_connection(rime_stack *block, uint16_t channel, pmt::pmt_t inport,
38 pmt::pmt_t outport, const uint8_t rime_add_mine[2]);
39 virtual ~rime_connection() {};
40 virtual void pack(pmt::pmt_t msg) = 0;
41 virtual void unpack(pmt::pmt_t msg) = 0;
42 uint16_t channel() const;
43 };
44 }
45}
46
47#endif
#define IEEE802_15_4_API
Definition api.h:25
Definition rime_connection.h:26
virtual void unpack(pmt::pmt_t msg)=0
rime_stack * d_block
Definition rime_connection.h:28
pmt::pmt_t d_mac_outport
Definition rime_connection.h:32
pmt::pmt_t d_outport
Definition rime_connection.h:31
pmt::pmt_t d_inport
Definition rime_connection.h:30
uint16_t d_channel
Definition rime_connection.h:29
static std::string msg_to_string(pmt::pmt_t msg)
virtual void pack(pmt::pmt_t msg)=0
virtual ~rime_connection()
Definition rime_connection.h:39
rime_connection(rime_stack *block, uint16_t channel, pmt::pmt_t inport, pmt::pmt_t outport, const uint8_t rime_add_mine[2])
Definition rime_stack.h:28
Definition access_code_prefixer.h:23