annotate gsm-fw/L1/dsp/leadapi.h @ 780:286567fb2ab8

starting to compile ACI; ati_ext_mech.h is missing
author Michael Spacefalcon <falcon@ivan.Harhan.ORG>
date Sun, 08 Mar 2015 01:51:24 +0000
parents a418c48046ad
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
558
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
1 /*******************************************************************************
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
2 TEXAS INSTRUMENTS INCORPORATED PROPRIETARY INFORMATION
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
3
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
4 Property of Texas Instruments -- For Unrestricted Internal Use Only
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
5 Unauthorized reproduction and/or distribution is strictly prohibited. This
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
6 product is protected under copyright law and trade secret law as an
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
7 unpublished work. Created 1987, (C) Copyright 1997 Texas Instruments. All
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
8 rights reserved.
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
9
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
10
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
11 Filename : leadapi.h
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
12
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
13 Description : Boot the LEAD - header file
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
14
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
15 Target : ARM
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
16
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
17 Project :
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
18
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
19 Author : A0917556
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
20
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
21 Version number : 1.8
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
22
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
23 Date and time : 02/22/01 11:54:48
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
24
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
25 Previous delta : 01/22/01 10:32:42
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
26
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
27 SCCS file : /db/gsm_asp/db_ht96/dsp_0/gsw/rel_0/mcu_l1/release_gprs/RELEASE_GPRS/drivers1/common/SCCS/s.leadapi.h
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
28
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
29 Sccs Id (SID) : '@(#) leadapi.h 1.8 02/22/01 11:54:48 '
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
30
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
31
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
32 *****************************************************************************/
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
33
563
a418c48046ad L1: l1_init.c compiles
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 559
diff changeset
34 #undef NULL // appease gcc
558
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
35 #define NULL 0
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
36
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
37 #define APIF_ADDR 0xFFD00000L
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
38 #define BASE_API_ARM APIF_ADDR /* API RAM for ARM */
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
39 #if (CHIPSET == 4)
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
40 #define BASE_API_LEAD 0xE800 /* API RAM for Lead */
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
41 #elif (CHIPSET == 7) || (CHIPSET == 8) || (CHIPSET == 10) || (CHIPSET == 11) || (CHIPSET == 12)
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
42 #define BASE_API_LEAD 0xE000 /* API RAM for Lead */
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
43 #else
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
44 #define BASE_API_LEAD 0xF800 /* API RAM for Lead */
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
45 #endif
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
46
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
47 #define DOWNLOAD_EXT_PAGE (APIF_ADDR + 0x0FF8) /* Address of the extended DSP page of the */
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
48 #define DOWNLOAD_SIZE (APIF_ADDR + 0x0FFA) /* Address of the download size variable */
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
49 #define DOWNLOAD_ADDR (APIF_ADDR + 0x0FFC) /* Address of the download address variable */
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
50 #define DOWNLOAD_STATUS (APIF_ADDR + 0x0FFE) /* Address of the download status variable */
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
51
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
52 /* Maximum size of a block which can be copied into the API RAM */
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
53
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
54 #define MAX_BLOCK_SIZE 0x7F0
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
55 #define MAX_UINT 65535
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
56
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
57 /* Possible values for the download status */
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
58
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
59 #define LEAD_READY 1
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
60 #define BLOCK_READY 2
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
61 #define PROGRAM_DONE 3
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
62 #define PAGE_SELECTION 4
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
63
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
64
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
65 // Constants for timeout
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
66 #define LA_TIMEOUT 10000
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
67 #define LA_SUCCESS 0
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
68 #define LA_ERR_TIMEOUT 1
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
69
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
70 // Constants for error
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
71 #define LA_BAD_EXT_VALUE 2
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
72 #define LA_BAD_VERSION 3
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
73 #define LA_BAD_TAG 4
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
74
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
75 // Prototypes
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
76 void LA_InitialLeadBoot16(const unsigned char bootCode[]);
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
77 void LA_InitialLeadBoot(const unsigned char bootCode[]);
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
78 short LA_LoadPage16(const unsigned char code[], SYS_UWORD16 page, SYS_UWORD16 start);
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
79 short LA_LoadPage(const unsigned char code[], SYS_UWORD16 page, SYS_UWORD16 start);
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
80 void LA_ResetLead(void);
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
81 void LA_StartLead(SYS_UWORD16 pll);
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
82
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
83 extern const unsigned char bootCode[];
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
84
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
85 /*
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
86 * Global variables
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
87 */
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
88 #ifdef LEADAPI_C
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
89 #define LA_GLOBAL
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
90 #else
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
91 #define LA_GLOBAL extern
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
92 #endif
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
93
565bf963c3a2 gsm-fw/L1/dsp/leadapi.[ch]: import from Leonardo semi-src
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
94 LA_GLOBAL volatile unsigned leadInt;