Go to the documentation of this file.00001
00044 #if !defined (MSGQ_H)
00045 #define MSGQ_H
00046
00047
00048
00049 #include <dsplink.h>
00050 #include <msgqdefs.h>
00051
00052
00053 #if defined (DDSP_PROFILE)
00054 #include <profile.h>
00055 #endif
00056
00057
00058 #if defined (__cplusplus)
00059 extern "C" {
00060 #endif
00061
00062
00069 #define MSGQ_getMsgId(msg) (((MSGQ_Msg) (msg))->msgId)
00070
00077 #define MSGQ_getMsgSize(msg) (((MSGQ_Msg) (msg))->size)
00078
00085 #define MSGQ_setMsgId(msg, id) ((MSGQ_Msg) (msg))->msgId = id
00086
00094 #define MSGQ_getDstQueue(msg) ((Uint32) ID_GPP << 16u) | ((MSGQ_Msg) (msg))->dstId
00095
00102 #define MSGQ_setSrcQueue(msg, msgq) ((MSGQ_Msg) (msg))->srcId = (MSGQ_Id) msgq ; \
00103 ((MSGQ_Msg) (msg))->srcProcId = (Uint16) \
00104 (msgq >> 16u)
00105
00112 #define MSGQ_isLocalQueue(msgq) ((msgq >> 16u) == ID_GPP)
00113
00114
00158 EXPORT_API
00159 DSP_STATUS
00160 MSGQ_transportOpen (IN ProcessorId procId, IN Pvoid attrs) ;
00161
00162
00197 EXPORT_API
00198 DSP_STATUS
00199 MSGQ_transportClose (IN ProcessorId procId) ;
00200
00201
00235 EXPORT_API
00236 DSP_STATUS
00237 MSGQ_open (IN Pstr queueName,
00238 OUT MSGQ_Queue * msgqQueue,
00239 IN MSGQ_Attrs * attrs) ;
00240
00241
00268 EXPORT_API
00269 DSP_STATUS
00270 MSGQ_close (IN MSGQ_Queue msgqQueue) ;
00271
00272
00311 EXPORT_API
00312 DSP_STATUS
00313 MSGQ_locate (IN Pstr queueName,
00314 OUT MSGQ_Queue * msgqQueue,
00315 IN MSGQ_LocateAttrs * attrs) ;
00316
00317
00353 EXPORT_API
00354 DSP_STATUS
00355 MSGQ_locateAsync (IN Pstr queueName,
00356 IN MSGQ_Queue replyQueue,
00357 IN MSGQ_LocateAsyncAttrs * attrs) ;
00358
00359
00389 EXPORT_API
00390 DSP_STATUS
00391 MSGQ_release (IN MSGQ_Queue msgqQueue) ;
00392
00393
00425 EXPORT_API
00426 DSP_STATUS
00427 MSGQ_alloc (IN PoolId poolId, IN Uint16 size, OUT MSGQ_Msg * msg) ;
00428
00429
00455 EXPORT_API
00456 DSP_STATUS
00457 MSGQ_free (IN MSGQ_Msg msg) ;
00458
00459
00485 EXPORT_API
00486 DSP_STATUS
00487 MSGQ_put (IN MSGQ_Queue msgqQueue, IN MSGQ_Msg msg) ;
00488
00489
00524 EXPORT_API
00525 DSP_STATUS
00526 MSGQ_get (IN MSGQ_Queue msgqQueue, IN Uint32 timeout, OUT MSGQ_Msg * msg) ;
00527
00528
00557 EXPORT_API
00558 DSP_STATUS
00559 MSGQ_getSrcQueue (IN MSGQ_Msg msg, OUT MSGQ_Queue * msgqQueue) ;
00560
00561
00589 EXPORT_API
00590 DSP_STATUS
00591 MSGQ_count (IN MSGQ_Queue msgqQueue, OUT Uint16 * count) ;
00592
00593
00620 EXPORT_API
00621 DSP_STATUS
00622 MSGQ_setErrorHandler (IN MSGQ_Queue errorQueue, IN PoolId poolId) ;
00623
00624
00625 #if defined (DDSP_PROFILE)
00626
00653 EXPORT_API
00654 DSP_STATUS
00655 MSGQ_instrument (IN MSGQ_Queue msgqQueue, OUT MSGQ_Instrument * retVal) ;
00656 #endif
00657
00658
00659 #if defined (DDSP_DEBUG)
00660
00677 EXPORT_API
00678 Void
00679 MSGQ_debug (IN MSGQ_Queue msgqQueue) ;
00680 #endif
00681
00682
00692 #define MSGQ_GetMsgId MSGQ_getMsgId
00693
00703 #define MSGQ_GetMsgSize MSGQ_getMsgSize
00704
00714 #define MSGQ_SetMsgId MSGQ_setMsgId
00715
00725 #define MSGQ_GetDstQueue MSGQ_getDstQueue
00726
00736 #define MSGQ_SetSrcQueue MSGQ_setSrcQueue
00737
00747 #define MSGQ_IsLocalQueue MSGQ_isLocalQueue
00748
00758 #define MSGQ_TransportOpen MSGQ_transportOpen
00759
00769 #define MSGQ_TransportClose MSGQ_transportClose
00770
00780 #define MSGQ_Open MSGQ_open
00781
00791 #define MSGQ_Close MSGQ_close
00792
00802 #define MSGQ_Locate MSGQ_locate
00803
00813 #define MSGQ_LocateAsync MSGQ_locateAsync
00814
00824 #define MSGQ_Release MSGQ_release
00825
00835 #define MSGQ_Alloc MSGQ_alloc
00836
00846 #define MSGQ_Free MSGQ_free
00847
00857 #define MSGQ_Put MSGQ_put
00858
00868 #define MSGQ_Get MSGQ_get
00869
00879 #define MSGQ_GetSrcQueue MSGQ_getSrcQueue
00880
00890 #define MSGQ_Count MSGQ_count
00891
00901 #define MSGQ_SetErrorHandler MSGQ_setErrorHandler
00902
00903 #if defined (DDSP_DEBUG)
00904
00913 #define MSGQ_Debug MSGQ_debug
00914 #endif
00915
00916
00917 #if defined (__cplusplus)
00918 }
00919 #endif
00920
00921
00922 #endif