FreeCalypso > hg > tcs211-l1-reconst
annotate chipsetsw/layer1/tm_cust0/l1tm_tpu12.c @ 332:00332897676c
l1p_sync.c: l1pddsp_meas_read() fixed
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Sun, 29 Oct 2017 08:16:17 +0000 |
parents | 1308ecea19ad |
children |
rev | line source |
---|---|
250
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
1 /************* Revision Controle System Header ************* |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
2 * GSM Layer 1 software |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
3 * L1TM_TPU2.C |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
4 * |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
5 * Filename %M% |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
6 * Version %I% |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
7 * Date %G% |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
8 * |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
9 ************* Revision Controle System Header *************/ |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
10 #include "l1_confg.h" |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
11 |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
12 #if (TESTMODE && (RF==12)) |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
13 |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
14 #include "tm_defs.h" |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
15 #include "l1_const.h" |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
16 #include "l1_types.h" |
251
1308ecea19ad
l1tm_tpu12.c: perfect match after s/ANALOG/ANLG_FAM/
Mychaela Falconia <falcon@freecalypso.org>
parents:
250
diff
changeset
|
17 |
250
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
18 #include "l1tm_defty.h" |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
19 #include "l1tm_cust.h" |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
20 #include "l1tm_tpu12.h" |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
21 |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
22 #if (AUDIO_TASK == 1) |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
23 #include "l1audio_const.h" |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
24 #include "l1audio_cust.h" |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
25 #include "l1audio_defty.h" |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
26 #endif |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
27 ////////////////////////////henry |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
28 #if (L1_GTT == 1) |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
29 #include "l1gtt_const.h" |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
30 #include "l1gtt_defty.h" |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
31 #endif |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
32 /////////////////////////// |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
33 #include "l1_defty.h" |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
34 #include "l1_msgty.h" |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
35 #include "l1_tabs.h" |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
36 |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
37 #include "l1tm_msgty.h" |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
38 #include "l1tm_varex.h" |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
39 |
251
1308ecea19ad
l1tm_tpu12.c: perfect match after s/ANALOG/ANLG_FAM/
Mychaela Falconia <falcon@freecalypso.org>
parents:
250
diff
changeset
|
40 #if ((ANLG_FAM == 1) || (ANLG_FAM == 2)) |
250
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
41 #include "spi_drv.h" |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
42 #endif |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
43 |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
44 #include "tpudrv12.h" |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
45 #include "l1_rf12.h" |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
46 |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
47 |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
48 #include <string.h> |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
49 |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
50 // Import band configuration from Flash module (need to replace by an access function) |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
51 |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
52 |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
53 // External function prototypes |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
54 |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
55 |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
56 void Cust_tm_tpu_table_write (T_TM_RETURN *tm_return, WORD8 index, UWORD8 size, UWORD8 table[]) |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
57 { |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
58 /* |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
59 INDICES BETWEEN in [0..63] RANGE ARE RESERVED FOR TI RF MODULE |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
60 */ |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
61 |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
62 // fill in the cid |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
63 tm_return->cid = TPU_TABLE_WRITE; |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
64 |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
65 switch (index) |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
66 { |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
67 default: |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
68 tm_return->size = 0; |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
69 tm_return->status = E_BADINDEX; |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
70 break; |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
71 } // end of switch |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
72 } |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
73 |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
74 void Cust_tm_tpu_table_read (T_TM_RETURN *tm_return, WORD8 index) |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
75 { |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
76 /* |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
77 INDICES BETWEEN in [0..63] RANGE ARE RESERVED FOR TI RF MODULE |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
78 */ |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
79 |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
80 // fill in the cid |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
81 tm_return->cid = TPU_TABLE_READ; |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
82 |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
83 switch (index) |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
84 { |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
85 default: |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
86 tm_return->size = 0; |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
87 tm_return->status = E_BADINDEX; |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
88 break; |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
89 } // end of switch |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
90 } |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
91 |
ba7ba6156279
l1tm_tpu12.c: initial import from MV100 source
Mychaela Falconia <falcon@freecalypso.org>
parents:
185
diff
changeset
|
92 #endif //TESTMODE |