acpy3.h

Go to the documentation of this file.
00001 /* 
00002  * Copyright (c) 2009, Texas Instruments Incorporated
00003  * All rights reserved.
00004  *
00005  * Redistribution and use in source and binary forms, with or without
00006  * modification, are permitted provided that the following conditions
00007  * are met:
00008  *
00009  * *  Redistributions of source code must retain the above copyright
00010  *    notice, this list of conditions and the following disclaimer.
00011  *
00012  * *  Redistributions in binary form must reproduce the above copyright
00013  *    notice, this list of conditions and the following disclaimer in the
00014  *    documentation and/or other materials provided with the distribution.
00015  *
00016  * *  Neither the name of Texas Instruments Incorporated nor the names of
00017  *    its contributors may be used to endorse or promote products derived
00018  *    from this software without specific prior written permission.
00019  *
00020  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
00021  * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
00022  * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
00023  * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
00024  * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
00025  * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
00026  * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
00027  * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
00028  * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
00029  * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
00030  * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
00031  * 
00032  */
00054 #ifndef _ACPY3_
00055 #define _ACPY3_
00056 
00057 
00058 #ifdef __cplusplus
00059 extern "C" {
00060 #endif
00061 
00064 
00065 #include <ti/xdais/idma3.h>
00066 
00067 #define ACPY3_GTNAME "ti.sdo.fc.acpy3"
00068 
00069 
00075 typedef enum ACPY3_ParamField16b {
00076 
00077     ACPY3_PARAMFIELD_ELEMENTSIZE =  8,
00078     ACPY3_PARAMFIELD_NUMELEMENTS = 10 ,
00079     ACPY3_PARAMFIELD_ELEMENTINDEX_SRC = 16,
00080     ACPY3_PARAMFIELD_ELEMENTINDEX_DST = 18,
00081     ACPY3_PARAMFIELD_FRAMEINDEX_SRC =  24,
00082     ACPY3_PARAMFIELD_FRAMEINDEX_DST =  26,
00083     ACPY3_PARAMFIELD_NUMFRAMES = 28
00084 
00085 } ACPY3_ParamField16b;
00086 
00092 typedef enum ACPY3_ParamField32b {
00093 
00094     ACPY3_PARAMFIELD_SRCADDR = 4,
00095     ACPY3_PARAMFIELD_DSTADDR = 12,
00096     ACPY3_PARAMFIELD_ELEMENTINDEXES = 16,
00097     ACPY3_PARAMFIELD_FRAMEINDEXES = 24
00098 
00099 } ACPY3_ParamField32b;
00100 
00111 typedef enum ACPY3_TransferType {
00112 
00118     ACPY3_1D1D,
00119 
00133     ACPY3_1D2D,
00134 
00146     ACPY3_2D1D,
00147 
00159     ACPY3_2D2D
00160 } ACPY3_TransferType;
00161 
00162 
00167 typedef struct ACPY3_Params {
00168 
00170     ACPY3_TransferType transferType;
00171 
00173     Void *         srcAddr;
00174 
00176     Void *         dstAddr;
00177 
00179     unsigned short elementSize;
00180 
00182     unsigned short numElements;
00183 
00185     unsigned short numFrames ;
00186 
00191     short srcElementIndex;
00192 
00197     short dstElementIndex;
00198 
00204     short srcFrameIndex;
00205 
00211     short dstFrameIndex;
00212 
00222     short waitId;
00223 
00224 } ACPY3_Params;
00225 
00226 
00227 extern IDMA3_ProtocolObj ACPY3_PROTOCOL;
00228 
00251 Void ACPY3_configure(IDMA3_Handle handle, ACPY3_Params *params,
00252     short transferNo);
00253 
00254 
00292 #if defined(ACPY3_FASTCONFIGURE16B_INLINE) || defined(ACPY3_INLINE_ALL)
00293 #include <ti/sdo/fc/acpy3/acpy3_fastconfigure16b.h>
00294 #else
00295 Void ACPY3_fastConfigure16b(IDMA3_Handle handle, ACPY3_ParamField16b fieldId,
00296     unsigned short value, short transferNo);
00297 #endif
00298 
00338 #if defined(ACPY3_FASTCONFIGURE32B_INLINE) || defined(ACPY3_INLINE_ALL)
00339 #include <ti/sdo/fc/acpy3/acpy3_fastconfigure32b.h>
00340 #else
00341 Void ACPY3_fastConfigure32b(IDMA3_Handle handle, ACPY3_ParamField32b fieldId,
00342     Uns value, short transferNo);
00343 #endif
00344 
00386 #if defined(ACPY3_SETFINAL_INLINE) || defined(ACPY3_INLINE_ALL)
00387 #include <ti/sdo/fc/acpy3/acpy3_setfinal.h>
00388 #else
00389 Void ACPY3_setFinal(IDMA3_Handle handle, short transferNo);
00390 #endif
00391 
00435 #if defined(ACPY3_FASTSETFINAL_INLINE) || defined(ACPY3_INLINE_ALL)
00436 #include <ti/sdo/fc/acpy3/acpy3_fastsetfinal.h>
00437 #else
00438 Void ACPY3_fastSetFinal(IDMA3_Handle handle, short transferNo);
00439 #endif
00440 
00486 #if defined(ACPY3_START_INLINE) || defined(ACPY3_INLINE_ALL)
00487 #include <ti/sdo/fc/acpy3/acpy3_start.h>
00488 #else
00489 Void ACPY3_start(IDMA3_Handle handle);
00490 #endif
00491 
00492 
00519 #if defined(ACPY3_WAIT_INLINE) || defined(ACPY3_INLINE_ALL)
00520 #include <ti/sdo/fc/acpy3/acpy3_wait.h>
00521 #else
00522 Void ACPY3_wait(IDMA3_Handle handle);
00523 #endif
00524 
00525 
00544 Void ACPY3_waitLinked(IDMA3_Handle handle, unsigned short waitId);
00545 
00546 
00577 #if defined(ACPY3_COMPLETE_INLINE) || defined(ACPY3_INLINE_ALL)
00578 #include <ti/sdo/fc/acpy3/acpy3_complete.h>
00579 #else
00580 Bool ACPY3_complete(IDMA3_Handle handle);
00581 #endif
00582 
00583 
00611 Bool ACPY3_completeLinked(IDMA3_Handle handle, unsigned short waitId);
00612 
00613 
00629 Void ACPY3_activate(IDMA3_Handle handle);
00630 
00631 
00646 Void ACPY3_deactivate(IDMA3_Handle handle);
00647 
00648 
00652 Void ACPY3_init(Void);
00653 
00657 Void ACPY3_exit(Void);
00658 
00659 
00662 #ifdef __cplusplus
00663 }
00664 #endif /* extern "C" */
00665 
00666 
00667 #endif /* _ACPY3_ */
00668 
00669 /*
00670  *  @(#) ti.sdo.fc.acpy3; 1, 0, 4,279; 11-8-2009 20:57:19; /db/atree/library/trees/fc/fc-l04x/src/
00671  */
00672 

Copyright 2009, Texas Instruments Incorporated