Main Page | Alphabetical List | Data Structures | Directories | File List | Data Fields | Globals

SysLink.h

Go to the documentation of this file.
00001 /** 
00002  *  @file   SysLink.h
00003  *
00004  *  @brief      This module contains common definitions, types, structures and
00005  *              functions used by SysLink.
00006  *
00007  *
00008  *  @ver        02.00.00.68_beta1
00009  *  
00010  *  ============================================================================
00011  *  
00012  *  Copyright (c) 2008-2009, Texas Instruments Incorporated
00013  *
00014  *  Redistribution and use in source and binary forms, with or without
00015  *  modification, are permitted provided that the following conditions
00016  *  are met:
00017  *  
00018  *  *  Redistributions of source code must retain the above copyright
00019  *     notice, this list of conditions and the following disclaimer.
00020  *  
00021  *  *  Redistributions in binary form must reproduce the above copyright
00022  *     notice, this list of conditions and the following disclaimer in the
00023  *     documentation and/or other materials provided with the distribution.
00024  *  
00025  *  *  Neither the name of Texas Instruments Incorporated nor the names of
00026  *     its contributors may be used to endorse or promote products derived
00027  *     from this software without specific prior written permission.
00028  *  
00029  *  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
00030  *  AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
00031  *  THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
00032  *  PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
00033  *  CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
00034  *  EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
00035  *  PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
00036  *  OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
00037  *  WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
00038  *  OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
00039  *  EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
00040  *  Contact information for paper mail:
00041  *  Texas Instruments
00042  *  Post Office Box 655303
00043  *  Dallas, Texas 75265
00044  *  Contact information: 
00045  *  http://www-k.ext.ti.com/sc/technical-support/product-information-centers.htm?
00046  *  DCMP=TIHomeTracking&HQS=Other+OT+home_d_contact
00047  *  ============================================================================
00048  *  
00049  */
00050 
00051 
00052 #ifndef _SysLink_H_
00053 #define _SysLink_H_
00054 
00055 
00056 #if defined (__cplusplus)
00057 extern "C" {
00058 #endif
00059 
00060 /* =============================================================================
00061  * macros & defines
00062  * =============================================================================
00063  */
00064 /** ============================================================================
00065  *  @const  IPC_BUFFER_ALIGN
00066  *
00067  *  @desc   Macro to align a number.
00068  *          x: The number to be aligned
00069  *          y: The value that the number should be aligned to.
00070  *  ============================================================================
00071  */
00072 #define IPC_BUFFER_ALIGN(x, y) (UInt32)((UInt32)((x + y - 1) / y) * y)
00073 
00074 /* =============================================================================
00075  * Structures & Enums
00076  * =============================================================================
00077  */
00078 /*!
00079  *  @brief  Enumeration of Client notifyMgr notification types.
00080  */
00081 typedef enum SysLink_NotifyType_tag {
00082     SysLink_NOTIFICATION_NONE   = 0,
00083     /*!< No notification required*/
00084     SysLink_NOTIFICATION_ALWAYS = 1,
00085     /*!< Notify whenever the other client sends data/frees up space.*/
00086     SysLink_NOTIFICATION_ONCE   = 2,
00087     /*!< Notify when the other side sends data/frees up buffer. Once the
00088      *   notification is done, the notification is disabled until it is
00089      *   enabled again.
00090      */
00091     SysLink_NOTIFICATION_HDWRFIFO_ALWAYS = 3,
00092     /*!< Notify whenever the other side sends data/frees up space.
00093      *   This notification is never disabled.
00094      */
00095     SysLink_NOTIFICATION_HDWRFIFO_ONCE   = 4
00096     /*!< Notify when the other side sends data/frees up buffer. Once the
00097      *   notification is done, the notification is disabled until it is enabled
00098      *   again. The notification is enabled once the watermark is crossed and
00099      *   does not require buffer to get full/empty.
00100      */
00101 } SysLink_NotifyType;
00102 
00103 
00104 /* =============================================================================
00105  * APIs
00106  * =============================================================================
00107  */
00108 /*!
00109  *  @brief      Function to initialize SysLink.
00110  *
00111  *              This function must be called in every user process before making
00112  *              calls to any other SysLink APIs.
00113  *
00114  *  @sa         SysLink_destroy
00115  */
00116 Void SysLink_setup (Void);
00117 
00118 /*!
00119  *  @brief      Function to finalize SysLink.
00120  *
00121  *              This function must be called in every user process at the end
00122  *              after all usage of SysLink in that process is complete.
00123  *
00124  *  @sa         SysLink_setup
00125  */
00126 Void SysLink_destroy (Void);
00127 
00128 
00129 #if defined (__cplusplus)
00130 }
00131 #endif /* defined (__cplusplus) */
00132 
00133 
00134 #endif /*_SysLink_H_*/
00135 
00136 

Generated on Mon Mar 14 11:59:45 2011 for Syslink by  doxygen 1.4.4