F´ Flight Software - C/C++ Documentation
NASA-v2.0.1
A framework for building embedded system applications to NASA flight quality standards.
Main Page
Related Pages
Namespaces
Namespace List
Namespace Members
All
a
b
c
d
f
g
h
i
k
l
m
n
o
p
r
s
t
u
v
w
Functions
a
b
c
d
g
h
i
m
r
s
t
v
w
Variables
Typedefs
Enumerations
Enumerator
a
b
f
h
i
n
o
p
s
v
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
q
r
s
t
u
v
w
z
~
Functions
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
q
r
s
t
u
v
w
z
~
Variables
b
d
e
f
g
h
i
l
m
n
p
q
s
t
u
v
w
Typedefs
Enumerations
Enumerator
a
b
c
d
e
f
g
h
l
m
n
o
p
q
r
s
t
w
Related Functions
Files
File List
File Members
All
_
a
b
c
d
f
g
h
i
k
l
m
n
p
r
s
t
u
v
Functions
f
i
m
s
u
Variables
Typedefs
Enumerations
Enumerator
c
d
f
m
p
r
s
t
Macros
a
c
d
f
g
h
i
k
l
m
n
p
r
s
t
u
v
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
GroundInterface.hpp
Go to the documentation of this file.
1
// ======================================================================
2
// \title GroundInterfaceImpl.hpp
3
// \author lestarch
4
// \brief hpp file for GroundInterface component implementation class
5
// ======================================================================
6
#include <
Fw/Types/Serializable.hpp
>
7
#include "Svc/GroundInterface/GroundInterfaceComponentAc.hpp"
8
#include "
Utils/Types/CircularBuffer.hpp
"
9
#ifndef GroundInterface_HPP
10
#define GroundInterface_HPP
11
12
#define GND_BUFFER_SIZE 1024
13
#define TOKEN_TYPE U32
14
#define HEADER_SIZE (2 * sizeof(TOKEN_TYPE))
15
16
namespace
Svc
{
17
18
class
GroundInterfaceComponentImpl
:
19
public
GroundInterfaceComponentBase
20
{
21
public
:
22
static
const
U32
MAX_DATA_SIZE
;
23
static
const
TOKEN_TYPE
START_WORD
;
24
static
const
U32
END_WORD
;
25
// ----------------------------------------------------------------------
26
// Construction, initialization, and destruction
27
// ----------------------------------------------------------------------
28
31
GroundInterfaceComponentImpl
(
32
const
char
*
const
compName
33
);
34
37
void
init
(
38
const
NATIVE_INT_TYPE
instance = 0
39
);
40
43
~GroundInterfaceComponentImpl
(
void
);
44
45
PRIVATE:
46
47
// ----------------------------------------------------------------------
48
// Handler implementations for user-defined typed input ports
49
// ----------------------------------------------------------------------
50
53
void
downlinkPort_handler(
54
const
NATIVE_INT_TYPE
portNum,
55
Fw::ComBuffer
&data,
56
U32 context
57
);
58
61
void
fileDownlinkBufferSendIn_handler(
62
const
NATIVE_INT_TYPE
portNum,
63
Fw::Buffer
&fwBuffer
64
);
65
68
void
readCallback_handler(
69
const
NATIVE_INT_TYPE
portNum,
70
Fw::Buffer
&fwBuffer
71
);
72
75
void
schedIn_handler(
76
const
NATIVE_INT_TYPE
portNum,
77
NATIVE_UINT_TYPE
context
78
);
81
void
frame_send(
82
U8
* data,
83
TOKEN_TYPE
size,
84
TOKEN_TYPE
packet_type =
Fw::ComPacket::FW_PACKET_UNKNOWN
85
);
86
88
void
routeComData();
89
91
void
processRing();
92
94
void
processBuffer(
Fw::Buffer
& data );
95
96
// Basic data movement variables
97
Fw::Buffer
m_ext_buffer;
98
U8
m_buffer[
GND_BUFFER_SIZE
];
99
// Input variables
100
TOKEN_TYPE
m_data_size;
101
U8
m_in_buffer[
GND_BUFFER_SIZE
];
102
Types::CircularBuffer
m_in_ring;
103
};
104
105
}
// end namespace Svc
106
107
#endif
Svc::GroundInterfaceComponentImpl::~GroundInterfaceComponentImpl
~GroundInterfaceComponentImpl(void)
Definition:
GroundInterface.cpp:42
Svc::GroundInterfaceComponentImpl
Definition:
GroundInterface.hpp:18
Serializable.hpp
Fw::ComPacket::FW_PACKET_UNKNOWN
@ FW_PACKET_UNKNOWN
Definition:
ComPacket.hpp:28
U8
uint8_t U8
8-bit unsigned integer
Definition:
BasicTypes.hpp:76
Svc::GroundInterfaceComponentImpl::GroundInterfaceComponentImpl
GroundInterfaceComponentImpl(const char *const compName)
Definition:
GroundInterface.cpp:23
Fw::Buffer
Definition:
Buffer.hpp:43
Svc::GroundInterfaceComponentImpl::MAX_DATA_SIZE
static const U32 MAX_DATA_SIZE
Definition:
GroundInterface.hpp:22
CircularBuffer.hpp
NATIVE_UINT_TYPE
unsigned int NATIVE_UINT_TYPE
native unsigned integer type declaration
Definition:
BasicTypes.hpp:30
TOKEN_TYPE
#define TOKEN_TYPE
Definition:
GroundInterface.hpp:13
Svc::GroundInterfaceComponentImpl::START_WORD
static const TOKEN_TYPE START_WORD
Definition:
GroundInterface.hpp:23
Svc
Definition:
ActiveRateGroupImplCfg.hpp:18
Svc::GroundInterfaceComponentImpl::END_WORD
static const U32 END_WORD
Definition:
GroundInterface.hpp:24
Types::CircularBuffer
Definition:
CircularBuffer.hpp:31
Svc::GroundInterfaceComponentImpl::init
void init(const NATIVE_INT_TYPE instance=0)
Definition:
GroundInterface.cpp:34
NATIVE_INT_TYPE
int NATIVE_INT_TYPE
native integer type declaration
Definition:
BasicTypes.hpp:29
Fw::ComBuffer
Definition:
ComBuffer.hpp:21
GND_BUFFER_SIZE
#define GND_BUFFER_SIZE
Definition:
GroundInterface.hpp:12
Svc
GroundInterface
GroundInterface.hpp
Generated by
1.8.17