F´ Flight Software - C/C++ Documentation
A framework for building embedded system applications to NASA flight quality standards.
Loading...
Searching...
No Matches
SmSignalBuffer.hpp
Go to the documentation of this file.
1/*
2 * SmSignalBuffer.hpp
3 *
4 */
5
6/*
7 * Description:
8 * This object contains the SmSignalBuffer type, used for attaching data to state machine signals
9 */
10#ifndef FW_SM_SIGNAL_BUFFER_HPP
11#define FW_SM_SIGNAL_BUFFER_HPP
12
13#include <FpConfig.hpp>
15
16namespace Fw {
17
19 public:
20
21 enum {
23 SERIALIZED_SIZE = FW_COM_BUFFER_MAX_SIZE + sizeof(FwSizeStoreType) // size of buffer + storage of size word
24 };
25
26 SmSignalBuffer(const U8 *args, Serializable::SizeType size);
28 SmSignalBuffer(const SmSignalBuffer& other);
29 virtual ~SmSignalBuffer();
31
32 Serializable::SizeType getBuffCapacity() const; // !< returns capacity, not current size, of buffer
33 U8* getBuffAddr();
34 const U8* getBuffAddr() const;
35
36 private:
37 U8 m_bufferData[FW_SM_SIGNAL_BUFFER_MAX_SIZE]; // packet data buffer
38 };
39
40}
41
42#endif
uint8_t U8
8-bit unsigned integer
Definition BasicTypes.h:30
#define FW_SM_SIGNAL_BUFFER_MAX_SIZE
Definition FpConfig.h:287
U16 FwSizeStoreType
Definition FpConfig.h:59
#define FW_COM_BUFFER_MAX_SIZE
Definition FpConfig.h:282
C++-compatible configuration header for fprime configuration.
NATIVE_UINT_TYPE SizeType
Serializable::SizeType getBuffCapacity() const
returns capacity, not current size, of buffer
U8 * getBuffAddr()
gets buffer address for data filling
SmSignalBuffer & operator=(const SmSignalBuffer &other)