SysLink API Reference  2.21.03.11
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Data Structures | Macros | Typedefs | Enumerations | Functions
FrameQ.h File Reference

Detailed Description

Defines for interfaces for FrameQ module. (Deprecated)

Deprecated:
The FrameQ APIs are deprecated as of SysLink 2.20. While supported in this release, they will be removed in a future release.
#include <ti/syslink/FrameQDefs.h>
#include <ti/syslink/SysLink.h>
#include <ti/ipc/Notify.h>
Include dependency graph for FrameQ.h:

Go to the source code of this file.

Data Structures

struct  FrameQ_Config_Tag
 Structure defining config parameters for the FrameQ module. More...
struct  FrameQ_CreateParams_Tag
 Common parameters required to create FrameQ instance of any implementation. It should be the first element of the actual implementaton params structure. More...
struct  FrameQ_CommonOpenParams_Tag
 Common parameters required to open a FrameQ instance of any implementation. More...
struct  FrameQ_Params
 Common parameters required to create FrameQ instance of any implementation. It should be the first element of the actual implementaton params structure . More...
struct  FrameQ_NotifyParams_Tag
 Notification parameter structure. More...

Macros

#define FrameQ_S_ALREADYDESTROYED   2
 Indicates module has been already destroyed.
#define FrameQ_S_ALREADYSETUP   1
 Indicates module is already setup.
#define FrameQ_S_SUCCESS   0
 Operation successful.
#define FrameQ_E_FAIL   -1
 General Failure.
#define FrameQ_E_INVALIDARG   -2
 Argument passed to function is invalid.
#define FrameQ_E_NOTFOUND   -3
 FrameQ instance not found.
#define FrameQ_E_INST_EXISTS   -4
 FrameQ instance already exists.
#define FrameQ_E_WRITER_EXISTS   -5
 Writer client already exists.
#define FrameQ_E_ALLOC_FRAME   -6
 Failed to allocate frame header.
#define FrameQ_E_ALLOC_FRAMEBUF   -7
 Failed to allocate frame buffers.
#define FrameQ_E_MEMORY   -8
 Memory_alloc failed.
#define FrameQ_E_EMPTY   -9
 FrameQ is empty. Can not return frame.
#define FrameQ_E_CREATE_NAMESERVER   -10
 Name server create failed for the module.
#define FrameQ_E_CREATE_GATEMP   -11
 GateMP instance create failed.
#define FrameQ_E_OPEN_GATEMP   -12
 GateMP instance open failed.
#define FrameQ_E_FAIL_CLIENTN0TIFYMGR_CREATE   -13
 Failed to create Client NotifyMgr instance.
#define FrameQ_E_FAIL_CLIENTN0TIFYMGR_OPEN   -14
 Failed to open Client NotifyMgr instance.
#define FrameQ_E_MAX_READERS   -15
 Max limit of readers for a FrameQ is reached.
#define FrameQ_E_ACCESSDENIED   -16
 Operation can not be permitted or not implemented.
#define FrameQ_E_INVALIDSTATE   -17
 Module is not initialized.
#define FrameQ_E_OSFAILURE   -18
 Failure in OS call.
#define FrameQ_E_FAIL_NAMESERVERADD   -19
 Adding FrameQ entry to name server instance failed.
#define FrameQ_E_INVALID_INTERFACE   -20
 Unsupported interface type.
#define FrameQ_E_NOTIMPLEMENTED   -21
 Called API is not implemented.
#define FrameQ_E_OPEN_NAMESERVER   -22
 NameServer open failed.
#define FrameQ_E_INVALID_FRAMEQBUFMGRID   -23
 Invalid FrameQbufMgr id.
#define FrameQ_E_INSUFFICENT_FRAMES   -24
 Reader client get this error in getv call if it is not able to get all the requested frames. API is able to get only few frames.
#define FrameQ_E_ALLOC_MEMORY   -25
 Failed to allocate memory.
#define FrameQ_E_FRAMEQBUFMGROPEN   -26
 Failed to open FrameQBufMgr.
#define FrameQ_E_LISTMPOPEN   -27
 Failed to open ListMP instance.
#define FrameQ_E_CLIENTNOTIFYMGRREGCLIENT   -28
 Failed to register with the clientNotifyMgr.
#define FrameQ_E_FRAMEQBUFMGRREGCLIENT   -29
 Failed to register with the FrameQBufMgr.
#define FrameQ_E_CLIENTNOTIFYMGRUNREGCLIENT   -30
 Failed to unregister with the clientNotifyMgr.
#define FrameQ_E_FRAMEQBUFMGRUNREGCLIENT   -31
 Failed to unregister with the FrameQBufMgr.
#define FrameQ_E_ALREADYREGISTERED   -32
 Call back function is already registered.
#define FrameQ_E_NAMESERVERADD   -33
 NameServer_add failed.
#define FrameQ_FrameBufInfo   Frame_FrameBufInfo
 Defines the frame buffer information.
#define FrameQ_FrameHeader   Frame_FrameHeader
 Defines the frame header structure.
#define FrameQ_MAX_NAMELEN   (32u)
 Maximum length of the name string in bytes.
#define FrameQ_MAXFILLEDQUEUS_FOR_READER   (16)
 Max filled queues for a reader client of the FrameQ instance.
#define FrameQ_MAX_INST_READERS   (2u)
 Maximum number of reader clients supported by the instance.
#define FrameQ_MAX_INSTANCES   (64u)
 Maximum number of instances managed by FrameQ.
#define FrameQ_NOTIFY_RESERVED_EVENTNO   (1u)
 Notify Event Number to be used by FrameQ module.

Typedefs

typedef Frame_FrameHeaderFrameQ_Frame
 Defines the type for a frame pointer.
typedef UInt16 FrameQ_NotifyMsg
 This type is used for the notification message. This is a 16 bit payload which can be sent to the remote processor in a notification call.
typedef struct FrameQ_Object * FrameQ_Handle
 Handle for the FrameQ instance.
typedef void(* FrameQ_NotifyFunc )(FrameQ_Handle, Ptr arg, FrameQ_NotifyMsg)
 Prototype of the FrameQ call back function.
typedef enum FrameQ_NotifyType_Tag FrameQ_NotifyType
 Notification types for FrameQ.
typedef enum FrameQ_OpenMode_Tag FrameQ_OpenMode
 FrameQ open modes.
typedef enum
FrameQ_CpuAccessFlags_Tag 
FrameQ_CpuAccessFlags
 CPU access flags for frame buffers. For frame headers CPUACCESS is assumed to be TRUE.
typedef enum FrameQ_Interface_Tag FrameQ_Interface
 FrameQ interface types.
typedef struct FrameQ_Config_Tag FrameQ_Config
 Structure defining config parameters for the FrameQ module.
typedef struct
FrameQ_CreateParams_Tag 
FrameQ_CreateParams
 Common parameters required to create FrameQ instance of any implementation. It should be the first element of the actual implementaton params structure.
typedef struct
FrameQ_CommonOpenParams_Tag 
FrameQ_CommonOpenParams
 Common parameters required to open a FrameQ instance of any implementation.
typedef struct FrameQ_Params FrameQ_Params
 Common parameters required to create FrameQ instance of any implementation. It should be the first element of the actual implementaton params structure .
typedef struct
FrameQ_NotifyParams_Tag 
FrameQ_NotifyParams
 Notification parameter structure.

Enumerations

enum  FrameQ_NotifyType_Tag {
  FrameQ_NOTIFICATION_NONE = SysLink_NOTIFICATION_NONE,
  FrameQ_NOTIFICATION_ALWAYS = SysLink_NOTIFICATION_ALWAYS,
  FrameQ_NOTIFICATION_ONCE = SysLink_NOTIFICATION_ONCE,
  FrameQ_NOTIFICATION_HDWRFIFO_ALWAYS = SysLink_NOTIFICATION_HDWRFIFO_ALWAYS,
  FrameQ_NOTIFICATION_HDWRFIFO_ONCE = SysLink_NOTIFICATION_HDWRFIFO_ONCE
}
 Notification types for FrameQ. More...
enum  FrameQ_OpenMode_Tag {
  FrameQ_MODE_NONE,
  FrameQ_MODE_WRITER,
  FrameQ_MODE_READER
}
 FrameQ open modes. More...
enum  FrameQ_CpuAccessFlags_Tag {
  FrameQ_FRAMEBUF0_CPUACCESS = 0x10000,
  FrameQ_FRAMEBUF1_CPUACCESS = 0x20000,
  FrameQ_FRAMEBUF2_CPUACCESS = 0x40000,
  FrameQ_FRAMEBUF3_CPUACCESS = 0x80000,
  FrameQ_FRAMEBUF4_CPUACCESS = 0x100000,
  FrameQ_FRAMEBUF5_CPUACCESS = 0x200000,
  FrameQ_FRAMEBUF6_CPUACCESS = 0x400000,
  FrameQ_FRAMEBUF7_CPUACCESS = 0x800000
}
 CPU access flags for frame buffers. For frame headers CPUACCESS is assumed to be TRUE. More...
enum  FrameQ_Interface_Tag {
  FrameQ_INTERFACE_SHAREDMEM = 0x0,
  FrameQ_INTERFACE_NONE = 0x1
}
 FrameQ interface types. More...

Functions

Int32 FrameQ_isSupportedInterface (UInt32 type)
 Determine whether the given interface type is supported.
FrameQ_Handle FrameQ_create (Ptr params)
 Create a FrameQ instance.
Int32 FrameQ_delete (FrameQ_Handle *pHandle)
 Delete a FrameQ instance.
Int32 FrameQ_open (Ptr openParams, FrameQ_Handle *handlePtr)
 Open the created FrameQ instance.
Int32 FrameQ_openByAddr (FrameQ_Handle *handlePtr, Ptr openParams)
 Open the created FrameQ instance if shared address is known.
Int32 FrameQ_close (FrameQ_Handle *pHandle)
 Close the opened FrameQ instance.
Int32 FrameQ_alloc (FrameQ_Handle handle, FrameQ_Frame *framePtr)
 Allocate frame.
Int32 FrameQ_allocv (FrameQ_Handle handle, FrameQ_Frame framePtr[], UInt32 freeQId[], UInt8 *numFrames)
 Allocate multiple frames.
Int32 FrameQ_free (FrameQ_Handle handle, FrameQ_Frame frame)
 Free frame.
Int32 FrameQ_freev (FrameQ_Handle handle, FrameQ_Frame framePtr[], UInt32 numFrames)
 Free multiple frames.
Int32 FrameQ_put (FrameQ_Handle handle, FrameQ_Frame frame)
 Insert frame in to FrameQ instance.
Int32 FrameQ_putv (FrameQ_Handle handle, FrameQ_Frame framePtr[], UInt32 filledQueueId[], UInt8 numFrames)
 Insert multiple frames into queues of a FrameQ reader client.
Int32 FrameQ_get (FrameQ_Handle handle, FrameQ_Frame *framePtr)
 Retrieve frame from FrameQ instance by reader client.
Int32 FrameQ_getv (FrameQ_Handle handle, FrameQ_Frame pframe[], UInt32 filledQueueId[], UInt8 *numFrames)
 Retrieve frames from the given queues of a reader client.
Int32 FrameQ_dup (FrameQ_Handle handle, FrameQ_Frame frame, FrameQ_Frame *dupedFrame)
 Duplicate the given frame.
Int32 FrameQ_registerNotifier (FrameQ_Handle handle, FrameQ_NotifyParams *notifyParams)
 Register a call back function.
Int32 FrameQ_unregisterNotifier (FrameQ_Handle handle)
 Unregister call back function.
Int32 FrameQ_sendNotify (FrameQ_Handle handle, UInt16 msg)
 Send forced notification to the reader clients.
Int32 FrameQ_getNumFrames (FrameQ_Handle handle, UInt32 *numFrames)
 Function to find out the number of available frames in a FrameQ .
Int32 FrameQ_getvNumFrames (FrameQ_Handle handle, UInt32 numFrames[], UInt8 filledQId[], UInt8 numFilledQids)
 Find out the number of available frames in a FrameQ.
Int32 FrameQ_getNumFreeFrames (FrameQ_Handle handle, UInt32 *numFreeFrames)
 Get the number of free frames.
Int32 FrameQ_getvNumFreeFrames (FrameQ_Handle handle, UInt32 numFreeFrames[], UInt8 freeQId[], UInt8 numFreeQids)
 Function to get the number of free frames.
Int32 FrameQ_control (FrameQ_Handle handle, Int32 cmd, Ptr arg)
 Provides a hook to perform implementation dependent operation.
Ptr FrameQ_getExtendedHeaderPtr (FrameQ_Frame frame)
 Get the pointer to the extended header.
UInt32 FrameQ_getNumFrameBuffers (FrameQ_Frame frame)
 Determine the number of frame buffers in a frame.
Ptr FrameQ_getFrameBuffer (FrameQ_Frame frame, UInt32 frameBufNum)
 Get the framebuffer.
UInt32 FrameQ_getFrameBufSize (FrameQ_Frame frame, UInt32 frameBufNum)
 Determine the size of frame buffer.
UInt32 FrameQ_getFrameBufValidSize (FrameQ_Frame frame, UInt32 frameBufNum)
 Get valid data size of a frame buffer.
UInt32 FrameQ_getFrameBufDataStartOffset (FrameQ_Frame frame, UInt32 frameBufNum)
 Get the valid data start offset in framebuffer identified by frameBufNum in a given frame.
Int32 FrameQ_setFrameBufValidSize (FrameQ_Frame frame, UInt32 frameBufNum, UInt32 validDataSize)
 Set the valid data size of a framebuffer identified by frameBufNum in given frame.
Int32 FrameQ_setFrameBufDataStartOffset (FrameQ_Frame frame, UInt32 frameBufNum, UInt32 dataStartOffset)
 Set the valid data start offset of a framebuffer identified by frameBufNum in a given frame.
Void FrameQ_getConfig (FrameQ_Config *cfg)
 Get the default configuration for the FrameQ module.
Int32 FrameQ_setup (FrameQ_Config *cfg)
 Setup the FrameQ module.
Int32 FrameQ_destroy (Void)
 Finalize the FrameQ module.

Macro Definition Documentation

#define FrameQ_S_ALREADYDESTROYED   2

Indicates module has been already destroyed.

#define FrameQ_S_ALREADYSETUP   1

Indicates module is already setup.

#define FrameQ_S_SUCCESS   0

Operation successful.

#define FrameQ_E_FAIL   -1

General Failure.

#define FrameQ_E_INVALIDARG   -2

Argument passed to function is invalid.

#define FrameQ_E_NOTFOUND   -3

FrameQ instance not found.

#define FrameQ_E_INST_EXISTS   -4

FrameQ instance already exists.

#define FrameQ_E_WRITER_EXISTS   -5

Writer client already exists.

#define FrameQ_E_ALLOC_FRAME   -6

Failed to allocate frame header.

#define FrameQ_E_ALLOC_FRAMEBUF   -7

Failed to allocate frame buffers.

#define FrameQ_E_MEMORY   -8

Memory_alloc failed.

#define FrameQ_E_EMPTY   -9

FrameQ is empty. Can not return frame.

#define FrameQ_E_CREATE_NAMESERVER   -10

Name server create failed for the module.

#define FrameQ_E_CREATE_GATEMP   -11

GateMP instance create failed.

#define FrameQ_E_OPEN_GATEMP   -12

GateMP instance open failed.

#define FrameQ_E_FAIL_CLIENTN0TIFYMGR_CREATE   -13

Failed to create Client NotifyMgr instance.

#define FrameQ_E_FAIL_CLIENTN0TIFYMGR_OPEN   -14

Failed to open Client NotifyMgr instance.

#define FrameQ_E_MAX_READERS   -15

Max limit of readers for a FrameQ is reached.

#define FrameQ_E_ACCESSDENIED   -16

Operation can not be permitted or not implemented.

#define FrameQ_E_INVALIDSTATE   -17

Module is not initialized.

#define FrameQ_E_OSFAILURE   -18

Failure in OS call.

#define FrameQ_E_FAIL_NAMESERVERADD   -19

Adding FrameQ entry to name server instance failed.

#define FrameQ_E_INVALID_INTERFACE   -20

Unsupported interface type.

#define FrameQ_E_NOTIMPLEMENTED   -21

Called API is not implemented.

#define FrameQ_E_OPEN_NAMESERVER   -22

NameServer open failed.

#define FrameQ_E_INVALID_FRAMEQBUFMGRID   -23

Invalid FrameQbufMgr id.

#define FrameQ_E_INSUFFICENT_FRAMES   -24

Reader client get this error in getv call if it is not able to get all the requested frames. API is able to get only few frames.

#define FrameQ_E_ALLOC_MEMORY   -25

Failed to allocate memory.

#define FrameQ_E_FRAMEQBUFMGROPEN   -26

Failed to open FrameQBufMgr.

#define FrameQ_E_LISTMPOPEN   -27

Failed to open ListMP instance.

#define FrameQ_E_CLIENTNOTIFYMGRREGCLIENT   -28

Failed to register with the clientNotifyMgr.

#define FrameQ_E_FRAMEQBUFMGRREGCLIENT   -29

Failed to register with the FrameQBufMgr.

#define FrameQ_E_CLIENTNOTIFYMGRUNREGCLIENT   -30

Failed to unregister with the clientNotifyMgr.

#define FrameQ_E_FRAMEQBUFMGRUNREGCLIENT   -31

Failed to unregister with the FrameQBufMgr.

#define FrameQ_E_ALREADYREGISTERED   -32

Call back function is already registered.

#define FrameQ_E_NAMESERVERADD   -33

NameServer_add failed.

#define FrameQ_FrameBufInfo   Frame_FrameBufInfo

Defines the frame buffer information.

#define FrameQ_FrameHeader   Frame_FrameHeader

Defines the frame header structure.

#define FrameQ_MAX_NAMELEN   (32u)

Maximum length of the name string in bytes.

#define FrameQ_MAXFILLEDQUEUS_FOR_READER   (16)

Max filled queues for a reader client of the FrameQ instance.

#define FrameQ_MAX_INST_READERS   (2u)

Maximum number of reader clients supported by the instance.

#define FrameQ_MAX_INSTANCES   (64u)

Maximum number of instances managed by FrameQ.

#define FrameQ_NOTIFY_RESERVED_EVENTNO   (1u)

Notify Event Number to be used by FrameQ module.


Typedef Documentation

Defines the type for a frame pointer.

This type is used for the notification message. This is a 16 bit payload which can be sent to the remote processor in a notification call.

typedef struct FrameQ_Object* FrameQ_Handle

Handle for the FrameQ instance.

typedef void(* FrameQ_NotifyFunc)(FrameQ_Handle, Ptr arg, FrameQ_NotifyMsg)

Prototype of the FrameQ call back function.

Notification types for FrameQ.

FrameQ open modes.

CPU access flags for frame buffers. For frame headers CPUACCESS is assumed to be TRUE.

FrameQ interface types.

Structure defining config parameters for the FrameQ module.

Common parameters required to create FrameQ instance of any implementation. It should be the first element of the actual implementaton params structure.

Common parameters required to open a FrameQ instance of any implementation.

typedef struct FrameQ_Params FrameQ_Params

Common parameters required to create FrameQ instance of any implementation. It should be the first element of the actual implementaton params structure .

Notification parameter structure.


Enumeration Type Documentation

Notification types for FrameQ.

Enumerator:
FrameQ_NOTIFICATION_NONE 

No notification is required.

FrameQ_NOTIFICATION_ALWAYS 

Notify whenever the other client sends data/frees up space.

FrameQ_NOTIFICATION_ONCE 

Notify when the other side sends data/frees up space. Once the notification is done, the notification is disabled until it is enabled again.

FrameQ_NOTIFICATION_HDWRFIFO_ALWAYS 

Notify whenever the other side sends data/frees up space. This notification is never disabled.

FrameQ_NOTIFICATION_HDWRFIFO_ONCE 

Notify when the other side sends data/frees up space. Once the notification is done, the notification is disabled until it is enabled again. The notification is enabled once the watermark is crossed and does not require buffer to get full/empty.

FrameQ open modes.

Enumerator:
FrameQ_MODE_NONE 

Mode is not reader/writer.Apps should not use this as open mode

FrameQ_MODE_WRITER 

FrameQ mode is writer.

FrameQ_MODE_READER 

FrameQ mode is reader.

CPU access flags for frame buffers. For frame headers CPUACCESS is assumed to be TRUE.

Enumerator:
FrameQ_FRAMEBUF0_CPUACCESS 

If specified first frame buffer is accessed through CPU (direct memory access).

FrameQ_FRAMEBUF1_CPUACCESS 

If specified second frame buffer is accessed through CPU (direct memory access).

FrameQ_FRAMEBUF2_CPUACCESS 

If specified third frame buffer is accessed through CPU (direct memory access).

FrameQ_FRAMEBUF3_CPUACCESS 

If specified fourth frame buffer is accessed through CPU (direct memory access).

FrameQ_FRAMEBUF4_CPUACCESS 

If specified fifth frame buffer is accessed through CPU (direct memory access).

FrameQ_FRAMEBUF5_CPUACCESS 

If specified sixth frame buffer is accessed through CPU (direct memory access).

FrameQ_FRAMEBUF6_CPUACCESS 

If specified seventh frame buffer is accessed through CPU (direct memory access).

FrameQ_FRAMEBUF7_CPUACCESS 

If specified eighth frame buffer is accessed through CPU (direct memory access).

FrameQ interface types.

Enumerator:
FrameQ_INTERFACE_SHAREDMEM 

Denotes FrameQ implementation (FrameQ_ShMem Implementation) on shared memory.

FrameQ_INTERFACE_NONE 

Function Documentation

Int32 FrameQ_isSupportedInterface ( UInt32  type)

Determine whether the given interface type is supported.

Returns TRUE if the interface provide is supported, otherwise returns FALSE.

Parameters:
[in]typeType of interface. See FrameQ_Interface for details.
Return values:
TRUEGiven interface is supported.
FALSEGiven interface is no supported.
See also:
FrameQ_Interface
FrameQ_Handle FrameQ_create ( Ptr  params)

Create a FrameQ instance.

Create a new instance of FrameQ. It creates a frameQ based on the params specific to implementations.

Parameters:
[in]paramspointer to implementation specific params.
Return values:
HandleInstance handle
NULLCreate failed
See also:
FrameQ_ShMem_Params
FrameQ_delete()
FrameQ_open()
FrameQ_close()
Int32 FrameQ_delete ( FrameQ_Handle pHandle)

Delete a FrameQ instance.

Deletes FrameQ instance that created.

Parameters:
pHandlePointer to the created frameQ instance handle.
Return values:
FrameQ_S_SUCCESSDelete successful.
FrameQ_E_FAILDelete failed.
FrameQ_E_INVALIDARGPointer to Handle passed is null.
FrameQ_E_INVALIDARGHandle passed is null.
See also:
FrameQ_create()
FrameQ_open()
FrameQ_close()
Int32 FrameQ_open ( Ptr  openParams,
FrameQ_Handle handlePtr 
)

Open the created FrameQ instance.

Opens the FrameQ instance in reader or writer mode depending upon the open params passed to it.

Parameters:
openParamsPointer to implementation specific open params.
handlePtrReturn parameter.Instance opened in given mode.
Return values:
FrameQ_S_SUCCESSopen successful.
FrameQ_E_INVALIDARGInvalid parameter specified.
FrameQ_E_INVALIDSTATEModule is not initialized.
FrameQ_E_MEMORYMemory_alloc failed.
FrameQ_E_ALLOC_MEMORYMemory_alloc failed.
FrameQ_E_FRAMEQBUFMGROPENFrameQBufMge instance open failed.
FrameQ_E_OPEN_GATEMPGateMP open failed.
FrameQ_E_FAIL_CLIENTN0TIFYMGR_OPENClientNotifyMgr open failed.
FrameQ_E_LISTMPOPENInternal ListMP instance open failed.
FrameQ_E_NOTFOUNDInstance not found in FrameQ Nameserver.
See also:
FrameQ_ShMem_OpenParams
FrameQ_create()
FrameQ_delete()
FrameQ_close()
Int32 FrameQ_openByAddr ( FrameQ_Handle handlePtr,
Ptr  openParams 
)

Open the created FrameQ instance if shared address is known.

This function opens the FrameQ instance in reader or writer mode depending upon the open params passed to it. Apps should pass the valid shared addr of the created instance.

Parameters:
openParamsPointer to implementation specific open params.
handlePtrReturn parameter.Instance opened in given mode.
Return values:
FrameQ_S_SUCCESSopen successful.
FrameQ_E_INVALIDARGInvalid parameter specified.
FrameQ_E_INVALIDSTATEModule is not initialized.
FrameQ_E_MEMORYMemory_alloc failed.
FrameQ_E_ALLOC_MEMORYMemory_alloc failed.
FrameQ_E_FRAMEQBUFMGROPENFrameQBufMge instance open failed.
FrameQ_E_OPEN_GATEMPGateMP open failed.
FrameQ_E_FAIL_CLIENTN0TIFYMGR_OPENClientNotifyMgr open failed.
FrameQ_E_LISTMPOPENInternal ListMP instance open failed.
FrameQ_E_NOTFOUNDInstance not found in FrameQ Nameserver.
See also:
FrameQ_ShMem_OpenParams
FrameQ_create()
FrameQ_delete()
FrameQ_close()
Int32 FrameQ_close ( FrameQ_Handle pHandle)

Close the opened FrameQ instance.

Closes FrameQ instance that is opened.

Parameters:
pHandlePointer to the opened frameQ instance handle.
Return values:
FrameQ_S_SUCCESSClose successful
FrameQ_E_FAILClose failed
FrameQ_E_INVALIDARGpHandle is invalid
See also:
FrameQ_create()
FrameQ_open()
FrameQ_delete()
Int32 FrameQ_alloc ( FrameQ_Handle  handle,
FrameQ_Frame framePtr 
)

Allocate frame.

Allocates a frame when called by FrameQ writer.

Remarks:
This API internally makes a call to configured FrameQBufMgr to allocate a free frame.
Parameters:
handleFrameQ writer handle.
framePtrLocation to receive the allocated frame.
Return values:
FrameQ_S_SUCCESSSuccessfully allocated frame.
FrameQ_E_FAILInternal FrameQBufMgr_alloc failed.
FrameQ_E_INVALIDARGframePtr paased is null.
FrameQ_E_INVALIDARGhandle passed is null.
FrameQ_E_ACCESSDENIEDProvided handle can not allocate frames. Only writer can allocate frames.
See also:
FrameQ_open()
FrameQ_free()
FrameQ_put()
FrameQ_get()
Int32 FrameQ_allocv ( FrameQ_Handle  handle,
FrameQ_Frame  framePtr[],
UInt32  freeQId[],
UInt8 numFrames 
)

Allocate multiple frames.

Allocates frames from multiple free pools of plugged in FrameQBufMgr. After API returns, numframes will denotes the number of successfully allocated frames.The max size of framePtr and freeQId array is defined by FrameQ_MAX_FRAMESINVAPI.

Parameters:
handleFrameQ writer handle.
framePtrArray to receive pointers to allocated frames.
freeQIdArray of free frame pool nos of the plugged in FrameQBufMgrfrom from which this API needs to allocate frames actual size of that is allocated.
[in,out]numFramesNumber of frames that needs to be allocated.
Return values:
FrameQ_S_SUCCESSSuccessfully allocated frames.
FrameQ_E_FAILInternal FrameQBufMgr_allocv failed.
FrameQ_E_INVALIDARGframePtr passed is null.
FrameQ_E_INVALIDARGhandle passed is null.
FrameQ_E_INVALIDARGfreeQId passed is null.
FrameQ_E_INVALIDARGnumFrames passed is null.
FrameQ_E_ACCESSDENIEDProvided handle can not allocate frames. Only writer can allocate frames. Only writer can allocate frames.
See also:
FrameQ_open()
FrameQ_freev()
FrameQ_putv()
FrameQ_getv()
Int32 FrameQ_free ( FrameQ_Handle  handle,
FrameQ_Frame  frame 
)

Free frame.

Frees a frame when called by FrameQ writer or reader. This API internally makes a call to configured FrameQBufMgr to free the frame.

Parameters:
handleOpened FrameQ instance handle
frameFrame to be freed
Return values:
FrameQ_S_SUCCESSSuccessfully freed frame
FrameQ_E_FAILInternal FrameQBufMgr_free failed
FrameQ_E_INVALIDARGhandle or frame is invalid
FrameQ_E_ACCESSDENIEDProvided handle can not free frames. Only writer or reader can free frames.
See also:
FrameQ_open()
FrameQ_alloc()
FrameQ_put()
FrameQ_get()
Int32 FrameQ_freev ( FrameQ_Handle  handle,
FrameQ_Frame  framePtr[],
UInt32  numFrames 
)

Free multiple frames.

Frees multiple frames when called by FrameQ writer or writer.

Remarks:
This API internally makes a call to configured FrameQBufMgr to free frames.
Parameters:
handleOpened FrameQ instance handle.
framePtrArray of frames to be freed.
numFramesNumber of Frames to be freed.
Return values:
FrameQ_S_SUCCESSSuccessfully freed frames.
FrameQ_E_FAILInternal FrameQBufMgr_freev failed.
FrameQ_E_INVALIDARGhandle or framePtr is invalid
FrameQ_E_ACCESSDENIEDProvided handle can not free frames. Only writer or reader can free frames.
See also:
FrameQ_open()
FrameQ_allocv()
FrameQ_putv()
FrameQ_getv()
Int32 FrameQ_put ( FrameQ_Handle  handle,
FrameQ_Frame  frame 
)

Insert frame in to FrameQ instance.

This function inserts frame in to FrameQ. It inserts frame in to filled frame queue 0 of FrameQ reader clients. If multiple readers exist, 1.FrameQ inserts the original gien frame into first reader's queue 0. 2.FrameQ duplicates the original frame and inserts duplicated frames in to rest of the reader's queue 0.

Parameters:
handleOpened FrameQ instance handle.
frameFrame to be inserted.
Return values:
FrameQ_S_SUCCESSSuccessfully freed frames.
FrameQ_E_FAILFailed to put frame.
FrameQ_E_INVALIDARGframe passed is null.
FrameQ_E_INVALIDARGhandle passed is null.
FrameQ_E_ACCESSDENIEDProvided handle can not free frames. Only writer or reader can put frames.
See also:
FrameQ_get()
Int32 FrameQ_putv ( FrameQ_Handle  handle,
FrameQ_Frame  framePtr[],
UInt32  filledQueueId[],
UInt8  numFrames 
)

Insert multiple frames into queues of a FrameQ reader client.

If multiple readers exist, It dups the given frames and inserts in to other readers' queues. The size of framePtr and filledQueueId must be at least numFrames. The max size of framePtr and filledQueueId is defined by FrameQ_MAX_FRAMESINVAPI.

Parameters:
handleInstance handle.
framePtrArray of frames to be inserted.
filledQueueIdArray of filled queues of reader.
numFramesNumber of frames.
Return values:
FrameQ_S_SUCCESSSuccessfully inserted frames.
FrameQ_E_FAILFailed to put frames.
FrameQ_E_INVALIDARGhandle passed is null.
FrameQ_E_INVALIDARGframePtr passed is null.
FrameQ_E_INVALIDARGfilledQueueId passed is null.
FrameQ_E_ACCESSDENIEDProvided handle can not put frames. Only writer or reader can put frames.
See also:
FrameQ_getv()
Int32 FrameQ_get ( FrameQ_Handle  handle,
FrameQ_Frame framePtr 
)

Retrieve frame from FrameQ instance by reader client.

Retrieves frame from the queue 0 of caller client. Only readers are allowed to call this API.

Parameters:
handleInstance handle.
framePtrLocation to receive frame.
Return values:
FrameQ_S_SUCCESSSuccessfully retrieved frame.
FrameQ_E_FAILFailed to get frame.
FrameQ_E_INVALIDARGhandle passed is null.
FrameQ_E_INVALIDARGframePtr passed is null.
FrameQ_E_ACCESSDENIEDProvided handle can not retrieve frame. Only reader client can retrieve frame.
See also:
FrameQ_put()
Int32 FrameQ_getv ( FrameQ_Handle  handle,
FrameQ_Frame  pframe[],
UInt32  filledQueueId[],
UInt8 numFrames 
)

Retrieve frames from the given queues of a reader client.

This Function retrieves frames from the queues of caller client. Only readers are allowed to call this API. It returns frames if all the required frames are available in the FrameQ.

Remarks:
The size of pframe and filledQueueId must be at least numFrames.
The max size of framePtr and filledQueueId is defined by FrameQ_MAX_FRAMESINVAPI.
Parameters:
handleInstance handle.
pframeLocation to receive frames the queues specified in filledQueueId array argument.
filledQueueIdArray of queue ids from which frames.
numFramesDenotes number of frames that needs to retrieved from the filled Queues ids specified by filledQueueId. The Size of pframe and filledQueueId should be atleast equal to number of frames specified in numFrames value can be max FrameQ_MAX_FRAMESINVAPI.
Return values:
FrameQ_S_SUCCESSSuccessfully retrieved frames.
FrameQ_E_FAILFailed to get frames.
FrameQ_E_INVALIDARGInvalid arguments
FrameQ_E_ACCESSDENIEDProvided handle can not retrieve frames. Only reader client can retrieve frames.
See also:
FrameQ_putv()
Int32 FrameQ_dup ( FrameQ_Handle  handle,
FrameQ_Frame  frame,
FrameQ_Frame dupedFrame 
)

Duplicate the given frame.

Duplicates the given frame. It allocates one frame header buffer and copies the header information given in original frame and returns it.

Parameters:
handleInstance handle.
frameframe to be duplicated.
dupedFrameLocation to receive the duplicated frame.
Return values:
FrameQ_S_SUCCESSSuccessfully retrieved frames
FrameQ_E_FAILFailed to get frames
FrameQ_E_INVALIDARGInvalid argument
FrameQ_E_ACCESSDENIEDProvided handle can not dup frames. Only writer/reader client can dup frame.
See also:
FrameQ_alloc()
Int32 FrameQ_registerNotifier ( FrameQ_Handle  handle,
FrameQ_NotifyParams notifyParams 
)

Register a call back function.

For reader : It registers notification function to notify about available frames in the FrameQ. For writer : It registers notification function to notify about available free frames in the Plugged in FrameQBufMgr.

Parameters:
handleInstance handle.
notifyParamsPointer to notifyParams.
Return values:
FrameQ_S_SUCCESSOperation successful.
FrameQ_E_INVALIDARGInvalid Argument
FrameQ_E_INVALIDSTATEModule is not initialized
FrameQ_E_FAILFailed to register notification
See also:
FrameQ_unregisterNotifier()
Int32 FrameQ_unregisterNotifier ( FrameQ_Handle  handle)

Unregister call back function.

Parameters:
handleReader/writer client Handle.
Return values:
FrameQ_S_SUCCESSSuccessfully duped frame.
FrameQ_E_INVALIDARGInvalid argument
FrameQ_E_INVALIDSTATEModule is not initialized.
FrameQ_E_FAILFailed to register notification.
See also:
FrameQ_registerNotifier()
Int32 FrameQ_sendNotify ( FrameQ_Handle  handle,
UInt16  msg 
)

Send forced notification to the reader clients.

Parameters:
handleWriter client Handle
msgPayload that needs to be send to reader
Return values:
FrameQ_S_SUCCESSSuccessfully sent notification
FrameQ_E_INVALIDARGInvalid argument
FrameQ_E_INVALIDSTATEModule is not initialized
FrameQ_E_FAILFailed to send notification
FrameQ_E_ACCESSDENIEDhandle is not a writer handle.can not send notification.
See also:
FrameQ_registerNotifier()
Int32 FrameQ_getNumFrames ( FrameQ_Handle  handle,
UInt32 numFrames 
)

Function to find out the number of available frames in a FrameQ .

For Writer: It returns the number of frames in the primary reader's filled queue 0. For Reader: It returns the number of frames in the Reader's(caller)filledqueue 0.

Parameters:
handleReader client Handle.
numFramesLocation to recieve the number of frames.
Return values:
FrameQ_S_SUCCESSOperation successful.
FrameQ_E_FAILAPI failed.
See also:
FrameQ_getvNumFrames()
Int32 FrameQ_getvNumFrames ( FrameQ_Handle  handle,
UInt32  numFrames[],
UInt8  filledQId[],
UInt8  numFilledQids 
)

Find out the number of available frames in a FrameQ.

For Reader this function is to get the available frames from the queues associated with it. For writer this function is to get the available frames from the queues associated with the primary Reader(first reader).

Parameters:
handleWriter/Reader client handle.
numFramesLocation to recieve the number of frames.
filledQIdArray of filled queues.
numFilledQidsNumber of queues specified in filledQId array.
Return values:
FrameQ_S_SUCCESSOperation successful.
FrameQ_E_FAILAPI failed.
See also:
FrameQ_getNumFrames()
Int32 FrameQ_getNumFreeFrames ( FrameQ_Handle  handle,
UInt32 numFreeFrames 
)

Get the number of free frames.

Function to get the number of free frames available in the plugged in FrameQbufMgr's FreeFramePool 0. The returned number free frames may not exist in the frameQBufMgr after this call. This is because if allocs can be done by the other FrameQ writers on the same FrameQBufMgr. If frames are freed by other frameQ writers then the free Frames would be even more than the value that this API returns.

Parameters:
handleInstance handle.
numFreeFramesout parameter that denotes the number of free frames available
Return values:
FrameQ_S_SUCCESSOperation successful.
FrameQ_E_FAILAPI failed.
See also:
FrameQ_getvNumFreeFrames()
Int32 FrameQ_getvNumFreeFrames ( FrameQ_Handle  handle,
UInt32  numFreeFrames[],
UInt8  freeQId[],
UInt8  numFreeQids 
)

Function to get the number of free frames.

Function to get the number of free frames available in the plugged in FrameQbufMgr's FreeFramePools. The returned number free frames may not exist in the frameQBufMgr after this call. This is because if allocs can be done by the other FrameQ writers on the same FrameQBufMgr.If frames are freed by other frameQ writers then the free Frames would be even more than the value that this API returns.

Parameters:
handleInstance handle.
numFreeFramesout parameter that denotes the number of free frames available
freeQIdArray of free queues.
numFreeQidsNumber of queues specified in freeQId array.
Return values:
FrameQ_S_SUCCESSOperation successful.
FrameQ_E_FAILAPI failed.
See also:
FrameQ_getNumFreeFrames()
Int32 FrameQ_control ( FrameQ_Handle  handle,
Int32  cmd,
Ptr  arg 
)

Provides a hook to perform implementation dependent operation.

Parameters:
handleInstance handle.
cmdCommand to perform.
argvoid * argument.
Return values:
FrameQ_S_SUCCESSOperation successful.
FrameQ_E_FAILAPI failed.
Ptr FrameQ_getExtendedHeaderPtr ( FrameQ_Frame  frame)

Get the pointer to the extended header.

Parameters:
framepointer to frame
Return values:
pointerPointer to extended header pointer in frame header.
UInt32 FrameQ_getNumFrameBuffers ( FrameQ_Frame  frame)

Determine the number of frame buffers in a frame.

Parameters:
framepointer to frame
Return values:
numberof frame buffers.
Ptr FrameQ_getFrameBuffer ( FrameQ_Frame  frame,
UInt32  frameBufNum 
)

Get the framebuffer.

Parameters:
framepointer to frame
frameBufNumframe buffer index in the given frame
Return values:
Pointerto frame buffer.
UInt32 FrameQ_getFrameBufSize ( FrameQ_Frame  frame,
UInt32  frameBufNum 
)

Determine the size of frame buffer.

Parameters:
framepointer to frame
frameBufNumframe buffer index in the given frame
Return values:
sizeframe buffer size.
UInt32 FrameQ_getFrameBufValidSize ( FrameQ_Frame  frame,
UInt32  frameBufNum 
)

Get valid data size of a frame buffer.

Parameters:
framepointer to frame
frameBufNumframe buffer index in the given frame
Return values:
sizevalid size of the frame buffer.
UInt32 FrameQ_getFrameBufDataStartOffset ( FrameQ_Frame  frame,
UInt32  frameBufNum 
)

Get the valid data start offset in framebuffer identified by frameBufNum in a given frame.

Parameters:
framepointer to frame
frameBufNumframe buffer index in the given frame
Return values:
offsetvalid data offset in the frame buffer.
Int32 FrameQ_setFrameBufValidSize ( FrameQ_Frame  frame,
UInt32  frameBufNum,
UInt32  validDataSize 
)

Set the valid data size of a framebuffer identified by frameBufNum in given frame.

Parameters:
framepointer to frame
frameBufNumframe buffer index in the given frame
validDataSizesize of the valid data
Return values:
FrameQ_S_SUCCESSOperation successful.
FrameQ_E_FAILAPI failed.
Int32 FrameQ_setFrameBufDataStartOffset ( FrameQ_Frame  frame,
UInt32  frameBufNum,
UInt32  dataStartOffset 
)

Set the valid data start offset of a framebuffer identified by frameBufNum in a given frame.

Parameters:
framepointer to frame
frameBufNumframe buffer index in the given frame
dataStartOffsetvalid data startoffset that needs to set for the frame buffer.
Return values:
FrameQ_S_SUCCESSOperation successful.
FrameQ_E_FAILAPI failed.
Void FrameQ_getConfig ( FrameQ_Config cfg)

Get the default configuration for the FrameQ module.

This function can be called by the application to get their configuration parameter to FrameQ_setup filled in by the FrameQ module with the default parameters. If the user does not wish to make any change in the default parameters, this API is not required to be called.

Parameters:
cfgPointer to the FrameQ module configuration structure in which the default config is to be returned.
See also:
FrameQ_setup()
Int32 FrameQ_setup ( FrameQ_Config cfg)

Setup the FrameQ module.

This function sets up the FrameQ module. This function must be called before any other instance-level APIs can be invoked. Module-level configuration needs to be provided to this function. If the user wishes to change some specific config parameters, then FrameQ_getConfig can be called to get the configuration filled with the default values. After this, only the required configuration values can be changed. If the user does not wish to make any change in the default parameters, the application can simply call FrameQ_setup with NULL parameters. The default parameters would get automatically used.

Parameters:
cfgOptional FrameQ module configuration. If provided as NULL, default configuration is used.
See also:
FrameQ_destroy()
FrameQ_getConfig()
Int32 FrameQ_destroy ( Void  )

Finalize the FrameQ module.

See also:
FrameQ_setup()
Copyright 2014, Texas Instruments Incorporated