FreeCalypso > hg > freecalypso-sw
annotate gsm-fw/L1/dyn_dwl_cfile/l1_dyn_dwl_sync.c @ 947:76149e0628ba
target-utils/Makefile: c139explore added
author | Mychaela Falconia <falcon@ivan.Harhan.ORG> |
---|---|
date | Mon, 02 Nov 2015 18:11:53 +0000 |
parents | 48969469d961 |
children |
rev | line source |
---|---|
925
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
1 /************* Revision Controle System Header ************* |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
2 * GSM Layer 1 software |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
3 * L1_DYN_DWL_SYNC.C |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
4 * |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
5 * Filename l1_dyn_dwl_sync.c |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
6 * Copyright 2004 (C) Texas Instruments |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
7 * |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
8 ************* Revision Controle System Header *************/ |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
9 |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
10 #include <stdio.h> |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
11 #include <string.h> |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
12 |
927
48969469d961
gsm-fw: l1_dyn_dwl code compiles and links
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
925
diff
changeset
|
13 #include "config.h" |
925
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
14 #include "l1_confg.h" |
927
48969469d961
gsm-fw: l1_dyn_dwl code compiles and links
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
925
diff
changeset
|
15 #include "sys_types.h" |
48969469d961
gsm-fw: l1_dyn_dwl code compiles and links
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
925
diff
changeset
|
16 #include "../../riviera/rv/rv_general.h" |
48969469d961
gsm-fw: l1_dyn_dwl code compiles and links
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
925
diff
changeset
|
17 #include "../../nucleus/nucleus.h" |
925
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
18 #include "l1_types.h" |
927
48969469d961
gsm-fw: l1_dyn_dwl code compiles and links
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
925
diff
changeset
|
19 #include "../../gpf/inc/cust_os.h" |
925
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
20 #include "l1audio_signa.h" |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
21 #include "l1audio_const.h" |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
22 #include "l1audio_cust.h" |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
23 #include "l1audio_defty.h" |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
24 #include "l1_const.h" |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
25 #include "l1tm_defty.h" |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
26 #if (L1_GTT == 1) |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
27 #include "l1gtt_const.h" |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
28 #include "l1gtt_defty.h" |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
29 #endif |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
30 #if (L1_DYN_DSP_DWNLD==1) |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
31 #include "l1_dyn_dwl_defty.h" |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
32 #include "l1_dyn_dwl_msgty.h" |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
33 #include "l1_dyn_dwl_const.h" |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
34 #include "l1_dyn_dwl_signa.h" |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
35 #include "l1_dyn_dwl_error.h" |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
36 #include "l1_dyn_dwl_proto.h" |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
37 #include "l1_api_hisr.h" |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
38 #endif |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
39 |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
40 #if (L1_MP3 == 1) |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
41 #include "l1mp3_defty.h" |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
42 #endif //L1_MP3 |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
43 #if (L1_MIDI == 1) |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
44 #include "l1midi_defty.h" |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
45 #endif |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
46 |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
47 #include "l1_macro.h" |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
48 #include "l1_defty.h" |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
49 #include "l1_varex.h" |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
50 #include "l1_trace.h" |
927
48969469d961
gsm-fw: l1_dyn_dwl code compiles and links
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
925
diff
changeset
|
51 /* #include "sys_dma.h" */ |
925
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
52 |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
53 #if (L1_DYN_DSP_DWNLD == 1) |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
54 |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
55 extern T_DYN_DWNLD_MCU_DSP *dyn_dwl_ndb; |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
56 |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
57 |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
58 /*-------------------------------------------------------*/ |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
59 /* l1s_dyn_dsp_dwnld_manager() */ |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
60 /*-------------------------------------------------------*/ |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
61 /* */ |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
62 /* Parameters : n/a */ |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
63 /* */ |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
64 /* Return : n/a */ |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
65 /* */ |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
66 /* Description : dsp dynamic download L1S manager task. */ |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
67 /* */ |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
68 /*-------------------------------------------------------*/ |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
69 |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
70 void l1s_dyn_dwnld_manager(void) |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
71 { |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
72 enum states |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
73 { |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
74 WAIT_INIT = 0, |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
75 WAIT_RESULT, |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
76 WAIT_STOP |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
77 }; |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
78 |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
79 UWORD8 *state = &l1s.dyn_dwnld_state; |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
80 xSignalHeaderRec *conf_msg; |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
81 |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
82 switch(*state) |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
83 { |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
84 case WAIT_INIT: |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
85 { |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
86 if(l1a_l1s_com.dyn_dwnld_task.start==TRUE) |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
87 { |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
88 // make sure the DSP is able to receive API interrupt |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
89 // for this, we wait 1 TDMA frame |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
90 // change state |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
91 *state=WAIT_RESULT; |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
92 } |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
93 } |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
94 break; |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
95 |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
96 case WAIT_RESULT: |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
97 { |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
98 // reset the command |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
99 l1a_l1s_com.dyn_dwnld_task.start=FALSE; |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
100 // send start background to the DSP |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
101 dyn_dwl_ndb->d_api_dwl_download_ctrl = (API) C_DWL_DOWNLOAD_CTRL_INIT; |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
102 l1s_dsp_com.dsp_ndb_ptr->a_background_tasks[C_BGD_DSP_DYN_DWNLD] = (API)((C_BGD_DSP_DYN_DWNLD<<11) | 1); |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
103 l1s_dsp_com.dsp_ndb_ptr->d_background_enable|=(API)(1<<C_BGD_DSP_DYN_DWNLD); |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
104 l1_trigger_api_interrupt(); |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
105 |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
106 // change state |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
107 *state=WAIT_STOP; |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
108 } |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
109 break; |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
110 |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
111 case WAIT_STOP: |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
112 { |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
113 if(l1a_l1s_com.dyn_dwnld_task.stop==TRUE) |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
114 { |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
115 // reset the command |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
116 l1a_l1s_com.dyn_dwnld_task.stop=FALSE; |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
117 |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
118 // send stop background to the DSP |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
119 l1s_dsp_com.dsp_ndb_ptr->a_background_tasks[C_BGD_DSP_DYN_DWNLD] = (API)((C_BGD_DSP_DYN_DWNLD<<11) | 0); |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
120 l1s_dsp_com.dsp_ndb_ptr->d_background_enable&=(API)(~(1<<C_BGD_DSP_DYN_DWNLD)); |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
121 l1_trigger_api_interrupt(); |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
122 |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
123 // send confirmation to the L1A |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
124 conf_msg=os_alloc_sig(0); |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
125 DEBUGMSG(status,NU_ALLOC_ERR) |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
126 conf_msg->SignalCode=L1_DYN_DWNLD_STOP_CON; |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
127 os_send_sig(conf_msg,L1C1_QUEUE); |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
128 DEBUGMSG(status,NU_SEND_QUEUE_ERR) |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
129 |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
130 // change state |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
131 *state=WAIT_INIT; |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
132 } |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
133 } |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
134 break; |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
135 } |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
136 } |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
137 |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
138 #endif // L1_DYN_DSP_DWNLD==1 |
c56ba3363aa3
gsm-fw: l1_dyn_dwl code imported from tcs211-l1-reconst
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
diff
changeset
|
139 |