Developer World
Spresense SDK Library v3.2.0-ebc0364
Message Library (for class object send)
Collaboration diagram for Message Library (for class object send):

Files

file  Message.h
 Message Library API.
 
file  MsgQueBlock.h
 Message Library API.
 

Classes

struct  MsgQueDef
 
class  MsgLib
 Message Library Class. More...
 
class  MsgQueBlock
 Message Queue Class. More...
 
struct  MsgPacketInfo< T >
 
struct  MsgPacketInfo< MsgNullParam >
 
struct  MsgPacketInfo< MsgRangedParam >
 

Macros

#define MSG_LIB_NAME   "MsgLib"
 
#define MSG_LIB_VER   "2.03"
 
#define MSG_QUE_NULL   0
 

Functions

 MsgQueBlock (MsgQueId id, MsgCpuId owner, SpinLockId spinlock)
 
err_t setup (drm_t n_drm, uint16_t n_size, uint16_t n_num, drm_t h_drm, uint16_t h_size, uint16_t h_num)
 
uint16_t getNumMsg (MsgPri pri) const
 
uint16_t getRest (MsgPri pri) const
 
template<typename T >
static size_t getSendSize (const T &param, bool type_check)
 
template<>
size_t getSendSize (const MsgNullParam &, bool)
 
template<>
size_t getSendSize (const MsgRangedParam &param, bool)
 
template<typename T >
err_t send (MsgPri pri, MsgType type, MsgQueId reply, MsgFlags flags, const T &param)
 
template<typename T >
err_t sendIsr (MsgPri pri, MsgType type, MsgQueId reply, const T &param)
 
MsgPacketpushHeader (MsgPri pri, const MsgPacketHeader &header)
 
void notifyRecv ()
 
err_t recv (uint32_t ms, FAR MsgPacket **packet)
 
err_t pop ()
 
void lock ()
 
void unlock ()
 
void dump () const
 

Detailed Description

Function Documentation

◆ recv()

err_t recv ( uint32_t  ms,
FAR MsgPacket **  packet 
)
inline

Receive a Object from another task. this method can receive a object from refer(MsgQueId) with type(MsgType).

Parameters
[in]mstimeout time(millisecond)
[out]**packetthe pointer of Massage packet.
Returns
err_t error code