Defines | Functions

msgq.h File Reference


Detailed Description

Defines the interfaces and data structures for the API sub-component MSGQ.

============================================================================

Path:
/gpp/inc/usr/
Version:
1.65.01.06 ============================================================================
Copyright:
Copyright (C) 2002-2009, Texas Instruments Incorporated - https://www.ti.com/

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

* Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.

* Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.

* Neither the name of Texas Instruments Incorporated nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ============================================================================

#include <dsplink.h>
#include <msgqdefs.h>
Include dependency graph for msgq.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Defines

#define MSGQ_getMsgId(msg)   (((MSGQ_Msg) (msg))->msgId)
 This macro returns the message ID of the specified message. ============================================================================.
#define MSGQ_getMsgSize(msg)   (((MSGQ_Msg) (msg))->size)
 This macro returns the size of the specified message. ============================================================================.
#define MSGQ_setMsgId(msg, id)   ((MSGQ_Msg) (msg))->msgId = id
 This macro sets the message ID in the specified message. ============================================================================.
#define MSGQ_getDstQueue(msg)   ((Uint32) ID_GPP << 16u) | ((MSGQ_Msg) (msg))->dstId
 This macro returns the MSGQ_Queue handle of the destination message queue for the specified message. ============================================================================.
#define MSGQ_setSrcQueue(msg, msgq)
 This macro sets the source message queue in the specified message. ============================================================================.
#define MSGQ_isLocalQueue(msgq)   ((msgq >> 16u) == ID_GPP)
 This macro checks whether the specified queue is a local queue. ============================================================================.
#define MSGQ_GetMsgId   MSGQ_getMsgId
#define MSGQ_GetMsgSize   MSGQ_getMsgSize
#define MSGQ_SetMsgId   MSGQ_setMsgId
#define MSGQ_GetDstQueue   MSGQ_getDstQueue
#define MSGQ_SetSrcQueue   MSGQ_setSrcQueue
#define MSGQ_IsLocalQueue   MSGQ_isLocalQueue
#define MSGQ_TransportOpen   MSGQ_transportOpen
#define MSGQ_TransportClose   MSGQ_transportClose
#define MSGQ_Open   MSGQ_open
#define MSGQ_Close   MSGQ_close
#define MSGQ_Locate   MSGQ_locate
#define MSGQ_LocateAsync   MSGQ_locateAsync
#define MSGQ_Release   MSGQ_release
#define MSGQ_Alloc   MSGQ_alloc
#define MSGQ_Free   MSGQ_free
#define MSGQ_Put   MSGQ_put
#define MSGQ_Get   MSGQ_get
#define MSGQ_GetSrcQueue   MSGQ_getSrcQueue
#define MSGQ_Count   MSGQ_count
#define MSGQ_SetErrorHandler   MSGQ_setErrorHandler

Functions

DLLEXPORT DSP_STATUS MSGQ_transportOpen (IN ProcessorId procId, IN Pvoid attrs)
 This function initializes the transport associated with the specified processor. The transport corresponding to the processor ID specified in the call should be configured in the CFG. This function should be called only once as part of system initialization after the client has called PROC_Attach the first time. Subsequent tasks / threads should not call this function again as it would result in unpredictable behavior.
DLLEXPORT DSP_STATUS MSGQ_transportClose (IN ProcessorId procId)
 This function finalizes the transport associated with the specified processor.
DLLEXPORT DSP_STATUS MSGQ_open (IN Pstr queueName, OUT MSGQ_Queue *msgqQueue, IN MSGQ_Attrs *attrs)
 This function opens the message queue to be used for receiving messages, identified through the specified message queue name.
DLLEXPORT DSP_STATUS MSGQ_close (IN MSGQ_Queue msgqQueue)
 This function closes the message queue identified by the specified MSGQ handle.
DLLEXPORT DSP_STATUS MSGQ_locate (IN Pstr queueName, OUT MSGQ_Queue *msgqQueue, IN MSGQ_LocateAttrs *attrs)
 This function synchronously locates the message queue identified by the specified MSGQ name and returns a handle to the located message queue.
DLLEXPORT DSP_STATUS MSGQ_locateAsync (IN Pstr queueName, IN MSGQ_Queue replyQueue, IN MSGQ_LocateAsyncAttrs *attrs)
 This function asynchronously locates the message queue identified by the specified MSGQ name. An attempt is made to asynchronously locate the message queue. If found, an MSGQ_AsyncLocateMsg message is sent to the specified reply message queue.
DLLEXPORT DSP_STATUS MSGQ_release (IN MSGQ_Queue msgqQueue)
 This function releases the message queue identified by the MSGQ handle that was located earlier.
DLLEXPORT DSP_STATUS MSGQ_alloc (IN PoolId poolId, IN Uint16 size, OUT MSGQ_Msg *msg)
 This function allocates a message, and returns the pointer to the user.
DLLEXPORT DSP_STATUS MSGQ_free (IN MSGQ_Msg msg)
 This function frees a message.
DLLEXPORT DSP_STATUS MSGQ_put (IN MSGQ_Queue msgqQueue, IN MSGQ_Msg msg)
 This function sends a message to the specified MSGQ.
DLLEXPORT DSP_STATUS MSGQ_get (IN MSGQ_Queue msgqQueue, IN Uint32 timeout, OUT MSGQ_Msg *msg)
 This function receives a message on the specified MSGQ.
DLLEXPORT DSP_STATUS MSGQ_getSrcQueue (IN MSGQ_Msg msg, OUT MSGQ_Queue *msgqQueue)
 This function returns a handle to the source message queue of a message to be used for replying to the message.
DLLEXPORT DSP_STATUS MSGQ_count (IN MSGQ_Queue msgqQueue, OUT Uint16 *count)
 This API returns the count of the number of messages in a local message queue.
DLLEXPORT DSP_STATUS MSGQ_setErrorHandler (IN MSGQ_Queue errorQueue, IN PoolId poolId)
 This API allows the user to designate a MSGQ as an error-handler MSGQ to receive asynchronous error messages from the transports.

Define Documentation

#define MSGQ_getMsgId (   msg )    (((MSGQ_Msg) (msg))->msgId)

This macro returns the message ID of the specified message. ============================================================================.

============================================================================

Macro:
MSGQ_getMsgId
#define MSGQ_getMsgSize (   msg )    (((MSGQ_Msg) (msg))->size)

This macro returns the size of the specified message. ============================================================================.

============================================================================

Macro:
MSGQ_getMsgSize
#define MSGQ_setMsgId (   msg,
  id 
)    ((MSGQ_Msg) (msg))->msgId = id

This macro sets the message ID in the specified message. ============================================================================.

============================================================================

Macro:
MSGQ_setMsgId
#define MSGQ_getDstQueue (   msg )    ((Uint32) ID_GPP << 16u) | ((MSGQ_Msg) (msg))->dstId

This macro returns the MSGQ_Queue handle of the destination message queue for the specified message. ============================================================================.

============================================================================

Macro:
MSGQ_getDstQueue
#define MSGQ_setSrcQueue (   msg,
  msgq 
)
Value:
((MSGQ_Msg) (msg))->srcId = (MSGQ_Id) msgq ; \
                                    ((MSGQ_Msg) (msg))->srcProcId = (Uint16)     \
                                     (msgq >> 16u)

This macro sets the source message queue in the specified message. ============================================================================.

============================================================================

Macro:
MSGQ_setSrcQueue
#define MSGQ_isLocalQueue (   msgq )    ((msgq >> 16u) == ID_GPP)

This macro checks whether the specified queue is a local queue. ============================================================================.

============================================================================

Macro:
MSGQ_isLocalQueue
#define MSGQ_GetMsgId   MSGQ_getMsgId

============================================================================

Deprecated:
The deprecated API MSGQ_GetMsgId has been replaced with MSGQ_getMsgId. This has been done to follow DSP/BIOS codinf guidelines and have a uniform naming convention for the API's on both GPP as well as DSP.

============================================================================

#define MSGQ_GetMsgSize   MSGQ_getMsgSize

============================================================================

Deprecated:
The deprecated API MSGQ_GetMsgSize has been replaced with MSGQ_getMsgSize. This has been done to follow DSP/BIOS codinf guidelines and have a uniform naming convention for the API's on both GPP as well as DSP.

============================================================================

#define MSGQ_SetMsgId   MSGQ_setMsgId

============================================================================

Deprecated:
The deprecated API MSGQ_SetMsgId has been replaced with MSGQ_setMsgId. This has been done to follow DSP/BIOS codinf guidelines and have a uniform naming convention for the API's on both GPP as well as DSP.

============================================================================

#define MSGQ_GetDstQueue   MSGQ_getDstQueue

============================================================================

Deprecated:
The deprecated API MSGQ_GetDstQueue has been replaced with MSGQ_getDstQueue. This has been done to follow DSP/BIOS codinf guidelines and have a uniform naming convention for the API's on both GPP as well as DSP.

============================================================================

#define MSGQ_SetSrcQueue   MSGQ_setSrcQueue

============================================================================

Deprecated:
The deprecated API MSGQ_SetSrcQueue has been replaced with MSGQ_setSrcQueue. This has been done to follow DSP/BIOS codinf guidelines and have a uniform naming convention for the API's on both GPP as well as DSP.

============================================================================

#define MSGQ_IsLocalQueue   MSGQ_isLocalQueue

============================================================================

Deprecated:
The deprecated API MSGQ_IsLocalQueue has been replaced with MSGQ_isLocalQueue. This has been done to follow DSP/BIOS codinf guidelines and have a uniform naming convention for the API's on both GPP as well as DSP.

============================================================================

#define MSGQ_TransportOpen   MSGQ_transportOpen

============================================================================

Deprecated:
The deprecated API MSGQ_TransportOpen has been replaced with MSGQ_transportOpen. This has been done to follow DSP/BIOS codinf guidelines and have a uniform naming convention for the API's on both GPP as well as DSP.

============================================================================

#define MSGQ_TransportClose   MSGQ_transportClose

============================================================================

Deprecated:
The deprecated API MSGQ_TransportClose has been replaced with MSGQ_transportClose. This has been done to follow DSP/BIOS codinf guidelines and have a uniform naming convention for the API's on both GPP as well as DSP.

============================================================================

#define MSGQ_Open   MSGQ_open

============================================================================

Deprecated:
The deprecated API MSGQ_Open has been replaced with MSGQ_open. This has been done to follow DSP/BIOS codinf guidelines and have a uniform naming convention for the API's on both GPP as well as DSP.

============================================================================

#define MSGQ_Close   MSGQ_close

============================================================================

Deprecated:
The deprecated API MSGQ_Close has been replaced with MSGQ_close. This has been done to follow DSP/BIOS codinf guidelines and have a uniform naming convention for the API's on both GPP as well as DSP.

============================================================================

#define MSGQ_Locate   MSGQ_locate

============================================================================

Deprecated:
The deprecated API MSGQ_Locate has been replaced with MSGQ_locate. This has been done to follow DSP/BIOS codinf guidelines and have a uniform naming convention for the API's on both GPP as well as DSP.

============================================================================

#define MSGQ_LocateAsync   MSGQ_locateAsync

============================================================================

Deprecated:
The deprecated API MSGQ_LocateAsync has been replaced with MSGQ_locateAsync. This has been done to follow DSP/BIOS codinf guidelines and have a uniform naming convention for the API's on both GPP as well as DSP.

============================================================================

#define MSGQ_Release   MSGQ_release

============================================================================

Deprecated:
The deprecated API MSGQ_Release has been replaced with MSGQ_release. This has been done to follow DSP/BIOS codinf guidelines and have a uniform naming convention for the API's on both GPP as well as DSP.

============================================================================

#define MSGQ_Alloc   MSGQ_alloc

============================================================================

Deprecated:
The deprecated API MSGQ_Alloc has been replaced with MSGQ_alloc. This has been done to follow DSP/BIOS codinf guidelines and have a uniform naming convention for the API's on both GPP as well as DSP.

============================================================================

#define MSGQ_Free   MSGQ_free

============================================================================

Deprecated:
The deprecated API MSGQ_Free has been replaced with MSGQ_free. This has been done to follow DSP/BIOS codinf guidelines and have a uniform naming convention for the API's on both GPP as well as DSP.

============================================================================

#define MSGQ_Put   MSGQ_put

============================================================================

Deprecated:
The deprecated API MSGQ_Put has been replaced with MSGQ_put. This has been done to follow DSP/BIOS codinf guidelines and have a uniform naming convention for the API's on both GPP as well as DSP.

============================================================================

#define MSGQ_Get   MSGQ_get

============================================================================

Deprecated:
The deprecated API MSGQ_Get has been replaced with MSGQ_get. This has been done to follow DSP/BIOS codinf guidelines and have a uniform naming convention for the API's on both GPP as well as DSP.

============================================================================

#define MSGQ_GetSrcQueue   MSGQ_getSrcQueue

============================================================================

Deprecated:
The deprecated API MSGQ_GetSrcQueue has been replaced with MSGQ_getSrcQueue. This has been done to follow DSP/BIOS codinf guidelines and have a uniform naming convention for the API's on both GPP as well as DSP.

============================================================================

#define MSGQ_Count   MSGQ_count

============================================================================

Deprecated:
The deprecated API MSGQ_Count has been replaced with MSGQ_count. This has been done to follow DSP/BIOS codinf guidelines and have a uniform naming convention for the API's on both GPP as well as DSP.

============================================================================

#define MSGQ_SetErrorHandler   MSGQ_setErrorHandler

============================================================================

Deprecated:
The deprecated API MSGQ_SetErrorHandler has been replaced with MSGQ_setErrorHandler. This has been done to follow DSP/BIOS codinf guidelines and have a uniform naming convention for the API's on both GPP as well as DSP.

============================================================================


Function Documentation

DLLEXPORT DSP_STATUS MSGQ_transportOpen ( IN ProcessorId  procId,
IN Pvoid  attrs 
)

This function initializes the transport associated with the specified processor. The transport corresponding to the processor ID specified in the call should be configured in the CFG. This function should be called only once as part of system initialization after the client has called PROC_Attach the first time. Subsequent tasks / threads should not call this function again as it would result in unpredictable behavior.

============================================================================

Function:
MSGQ_transportOpen
Parameters:
procIdID of the Processor for which the transport is to be opened.
attrsAttributes for initialization of the transport. The structure of the expected attributes is specific to a transport.
Returns:
DSP_SOK Operation successfully completed. DSP_SALREADYOPENED The MSGQ transport for the specified processor has already been opened. DSP_EATTACHED This process has not attached to the specified processor. DSP_EMEMORY Operation failed due to memory error. DSP_EINVALIDARG Invalid Parameter passed. DSP_EACCESSDENIED Access to the DSP is denied. DSP_EFAIL General failure.
Precondition:
attrs must be valid. procId must be valid. PROC_attach has been successful.
Postcondition:
None
See also:
MSGQ_transportClose ============================================================================
DLLEXPORT DSP_STATUS MSGQ_transportClose ( IN ProcessorId  procId )

This function finalizes the transport associated with the specified processor.

============================================================================

Function:
MSGQ_transportClose
Parameters:
procIdID of the Processor for which the transport is to be closed.
Returns:
DSP_SOK Operation successfully completed. DSP_SCLOSED The final process has closed the MSGQ transport. DSP_EATTACHED This process has not attached to the specified processor. DSP_EMEMORY Operation failed due to memory error. DSP_EINVALIDARG Invalid Parameter passed. DSP_EOPENED The MSGQ transport was not opened. DSP_EACCESSDENIED The MSGQ transport was not opened in this process. DSP_EFAIL General failure.
Precondition:
procId must be valid. All MSGQ operations should be complete.
Postcondition:
None
See also:
MSGQ_transportOpen ============================================================================
DLLEXPORT DSP_STATUS MSGQ_open ( IN Pstr  queueName,
OUT MSGQ_Queue msgqQueue,
IN MSGQ_Attrs attrs 
)

This function opens the message queue to be used for receiving messages, identified through the specified message queue name.

============================================================================

Function:
MSGQ_open
Parameters:
queueNameName of the message queue to be opened.
msgqQueueLocation to store the handle to the message queue.
attrsOptional attributes for creation of the MSGQ.
Returns:
DSP_SOK Operation successfully completed. DSP_EINVALIDARG Invalid argument. DSP_ENOTFOUND Attempt to open more than number of message queues configured. DSP_EMEMORY Operation failed due to memory error. DSP_EFAIL General failure.
Precondition:
queueName must be valid. msgqQueue must be a valid pointer. PROC_attach has been successful.
Postcondition:
None
See also:
MSGQ_Queue, MSGQ_Attrs, MSGQ_close (), MSGQ_locate () ============================================================================
DLLEXPORT DSP_STATUS MSGQ_close ( IN MSGQ_Queue  msgqQueue )

This function closes the message queue identified by the specified MSGQ handle.

============================================================================

Function:
MSGQ_close
Parameters:
msgqQueueHandle to the message queue to be closed.
Returns:
DSP_SOK Operation successfully completed. DSP_EINVALIDARG Invalid argument. DSP_EMEMORY Operation failed due to memory error. DSP_EFAIL General failure.
Precondition:
msgqQueue must be valid. All MSGQ operations are complete.
Postcondition:
None
See also:
MSGQ_Queue, MSGQ_open () ============================================================================
DLLEXPORT DSP_STATUS MSGQ_locate ( IN Pstr  queueName,
OUT MSGQ_Queue msgqQueue,
IN MSGQ_LocateAttrs attrs 
)

This function synchronously locates the message queue identified by the specified MSGQ name and returns a handle to the located message queue.

============================================================================

Function:
MSGQ_locate
Parameters:
queueNameName of the message queue to be located.
msgqQueueLocation to store the handle to the located message queue.
attrsOptional attributes for location of the MSGQ.
Returns:
DSP_SOK Operation successfully completed. DSP_EINVALIDARG Invalid argument. DSP_ENOTFOUND The specified message queue could not be located. DSP_ETIMEOUT Timeout occurred while locating the message. DSP_ENOTCOMPLETE Operation not complete when WAIT_NONE was specified as timeout. DSP_EMEMORY Operation failed due to memory error. DSP_EFAIL General failure.
Precondition:
queueName must be valid. msgqQueue must be a valid pointer. Corresponding MSGQ has been opened successfully.
Postcondition:
None
See also:
MSGQ_Queue, MSGQ_LocateAttrs, MSGQ_put (), MSGQ_release () ============================================================================
DLLEXPORT DSP_STATUS MSGQ_locateAsync ( IN Pstr  queueName,
IN MSGQ_Queue  replyQueue,
IN MSGQ_LocateAsyncAttrs attrs 
)

This function asynchronously locates the message queue identified by the specified MSGQ name. An attempt is made to asynchronously locate the message queue. If found, an MSGQ_AsyncLocateMsg message is sent to the specified reply message queue.

============================================================================

Function:
MSGQ_locateAsync
Parameters:
queueNameName of the message queue to be located.
replyQueueMessage queue to be used to receive the response message for asynchronous location.
attrsAttributes for asynchronous location of the MSGQ.
Returns:
DSP_SOK Operation successfully completed. DSP_EINVALIDARG Invalid argument. DSP_EMEMORY Operation failed due to memory error. DSP_EFAIL General failure.
Precondition:
queueName must be valid. replyQueue must be valid. attrs must be valid. Corresponding MSGQ has been opened successfully.
Postcondition:
None
See also:
MSGQ_Queue, MSGQ_LocateAsyncAttrs, MSGQ_put (), MSGQ_release () ============================================================================
DLLEXPORT DSP_STATUS MSGQ_release ( IN MSGQ_Queue  msgqQueue )

This function releases the message queue identified by the MSGQ handle that was located earlier.

============================================================================

Function:
MSGQ_release
Parameters:
msgqQueueHandle to the message queue to be released.
Returns:
DSP_SOK Operation successfully completed. DSP_EINVALIDARG Invalid argument. DSP_ENOTFOUND The message queue has not been previously located. DSP_EMEMORY Operation failed due to memory error. DSP_EFAIL General failure.
Precondition:
msgqQueue must be valid. MSGQ_locate has been successful. All MSGQ operations pertaining to that MSGQ are complete.
Postcondition:
None
See also:
MSGQ_Queue, MSGQ_locate () ============================================================================
DLLEXPORT DSP_STATUS MSGQ_alloc ( IN PoolId  poolId,
IN Uint16  size,
OUT MSGQ_Msg msg 
)

This function allocates a message, and returns the pointer to the user.

============================================================================

Function:
MSGQ_alloc
Parameters:
poolIdID of the Pool to be used for allocating this message.
sizeSize of the message to be allocated.
msgLocation to receive the allocated message.
Returns:
DSP_SOK Operation successfully completed. DSP_EINVALIDARG Invalid argument. DSP_EMEMORY Operation failed due to memory error. DSP_EFAIL General failure.
Precondition:
msg must be a valid pointer. size must be greater than size of MSGQ_MsgHeader. POOL has been configured according to application specification.
Postcondition:
None
See also:
MSGQ_MsgHeader, MSGQ_put () ============================================================================
DLLEXPORT DSP_STATUS MSGQ_free ( IN MSGQ_Msg  msg )

This function frees a message.

============================================================================

Function:
MSGQ_free
Parameters:
msgPointer to the message to be freed.
Returns:
DSP_SOK Operation successfully completed. DSP_EINVALIDARG Invalid argument. DSP_EMEMORY Operation failed due to memory error. DSP_EFAIL General failure.
Precondition:
msg must be valid. MSGQ_alloc must be successful.
Postcondition:
None
See also:
MSGQ_MsgHeader, MSGQ_get () ============================================================================
DLLEXPORT DSP_STATUS MSGQ_put ( IN MSGQ_Queue  msgqQueue,
IN MSGQ_Msg  msg 
)

This function sends a message to the specified MSGQ.

============================================================================

Function:
MSGQ_put
Parameters:
msgqQueueHandle to the destination MSGQ.
msgPointer to the message to be sent to the destination MSGQ.
Returns:
DSP_SOK Operation successfully completed. DSP_EINVALIDARG Invalid argument. DSP_EFAIL General failure.
Precondition:
msgqQueue must be valid. msg must be valid.
Postcondition:
None
See also:
MSGQ_Queue, MSGQ_MsgHeader, MSGQ_get () ============================================================================
DLLEXPORT DSP_STATUS MSGQ_get ( IN MSGQ_Queue  msgqQueue,
IN Uint32  timeout,
OUT MSGQ_Msg msg 
)

This function receives a message on the specified MSGQ.

============================================================================

Function:
MSGQ_get
Parameters:
msgqQueueHandle to the MSGQ on which the message is to be received.
timeoutTimeout value to wait for the message (in milliseconds).
msgLocation to receive the message.
Returns:
DSP_SOK Operation successfully completed. DSP_EINVALIDARG Invalid Parameter passed. DSP_ETIMEOUT Timeout occurred while receiving the message. DSP_ENOTCOMPLETE Operation not complete when WAIT_NONE was specified as timeout. DSP_EMEMORY Operation failed due to memory error. DSP_EFAIL General failure.
Precondition:
msgQueue must be valid. msgqQueue must be a local queue. msg must be a valid pointer.
Postcondition:
None
See also:
MSGQ_Queue, MSGQ_MsgHeader, MSGQ_put () ============================================================================
DLLEXPORT DSP_STATUS MSGQ_getSrcQueue ( IN MSGQ_Msg  msg,
OUT MSGQ_Queue msgqQueue 
)

This function returns a handle to the source message queue of a message to be used for replying to the message.

============================================================================

Function:
MSGQ_getSrcQueue
Parameters:
msgMessage, whose source MSGQ handle is to be returned.
msgqQueueLocation to retrieve the handle to the source MSGQ.
Returns:
DSP_SOK Operation successfully completed. DSP_EINVALIDARG Invalid Parameter passed. DSP_ENOTFOUND Source information has not been provided by the sender. DSP_EFAIL General failure.
Precondition:
msg must be valid. msgqQueue must be a valid pointer.
Postcondition:
None
See also:
MSGQ_Queue, MSGQ_MsgHeader ============================================================================
DLLEXPORT DSP_STATUS MSGQ_count ( IN MSGQ_Queue  msgqQueue,
OUT Uint16 count 
)

This API returns the count of the number of messages in a local message queue.

============================================================================

Function:
MSGQ_count
Parameters:
msgqQueueHandle to the MSGQ for which the count is to be retrieved.
countLocation to receive the message count.
Returns:
DSP_SOK Operation successfully completed. DSP_EINVALIDARG Invalid argument DSP_EFAIL General failure.
Precondition:
msgqQueue must be valid. msgqQueue must be a local queue. count must be a valid pointer.
Postcondition:
None
See also:
MSGQ_Queue ============================================================================
DLLEXPORT DSP_STATUS MSGQ_setErrorHandler ( IN MSGQ_Queue  errorQueue,
IN PoolId  poolId 
)

This API allows the user to designate a MSGQ as an error-handler MSGQ to receive asynchronous error messages from the transports.

============================================================================

Function:
MSGQ_setErrorHandler
Parameters:
errorQueueHandle to the message queue to receive the error messages.
poolIdID indicating the pool to be used for allocating the error messages.
Returns:
DSP_SOK Operation successfully completed. DSP_EINVALIDARG Invalid argument DSP_EFAIL General failure.
Precondition:
MSGQ_open has been successful.
Postcondition:
None
See also:
MSGQ_AsyncErrorMsg ============================================================================
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines

Copyright 2011, Texas Instruments Incorporated