FreeCalypso > hg > freecalypso-sw
annotate gsm-fw/L1/cfile/l1_small_defs.c @ 828:a8d0bbba7886
build flashable images by default when PS is included and target has small RAM
author | Space Falcon <falcon@ivan.Harhan.ORG> |
---|---|
date | Mon, 06 Apr 2015 02:32:04 +0000 |
parents | 8d6062f4e7e4 |
children |
rev | line source |
---|---|
571
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
1 /* |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
2 * TI's original code had an l1_small.c module, containing the GSM small |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
3 * sleep function implemented in assembly (TI assembler syntax embedded |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
4 * in the C module via an individual asm() for each line, very poor style) |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
5 * and C definitions for two helper variables. In FreeCalypso we are |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
6 * moving the small sleep assembly code into a proper assembly module; |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
7 * this C module contains just the helper variable definitions. |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
8 */ |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
9 |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
10 #include "config.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
11 #include "l1_confg.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
12 #include "l1_macro.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
13 |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
14 #if (CODE_VERSION == SIMULATION) |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
15 #include <string.h> |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
16 #include "l1_types.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
17 #include "sys_types.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
18 #include "l1_const.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
19 #include "l1_time.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
20 #if TESTMODE |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
21 #include "l1tm_defty.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
22 #endif |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
23 #if (AUDIO_TASK == 1) |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
24 #include "l1audio_const.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
25 #include "l1audio_cust.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
26 #include "l1audio_defty.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
27 #endif |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
28 #if (L1_GTT == 1) |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
29 #include "l1gtt_const.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
30 #include "l1gtt_defty.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
31 #endif |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
32 #if (L1_MP3 == 1) |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
33 #include "l1mp3_defty.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
34 #endif |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
35 #if (L1_MIDI == 1) |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
36 #include "l1midi_defty.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
37 #endif |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
38 #if (L1_AAC == 1) |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
39 #include "l1aac_defty.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
40 #endif |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
41 #include "l1_defty.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
42 #include "l1_varex.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
43 #include "cust_os.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
44 #include "l1_msgty.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
45 |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
46 #include <stdio.h> |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
47 #include "sim_cfg.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
48 #include "sim_cons.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
49 #include "sim_def.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
50 #include "sim_var.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
51 |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
52 #else |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
53 #include <string.h> |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
54 |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
55 #include "l1_types.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
56 #include "sys_types.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
57 #include "l1_const.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
58 #include "l1_time.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
59 |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
60 #if TESTMODE |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
61 #include "l1tm_defty.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
62 #endif |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
63 #if (AUDIO_TASK == 1) |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
64 #include "l1audio_const.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
65 #include "l1audio_cust.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
66 #include "l1audio_defty.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
67 #endif |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
68 #if (L1_GTT == 1) |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
69 #include "l1gtt_const.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
70 #include "l1gtt_defty.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
71 #endif |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
72 #if (L1_MP3 == 1) |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
73 #include "l1mp3_defty.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
74 #endif |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
75 #if (L1_MIDI == 1) |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
76 #include "l1midi_defty.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
77 #endif |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
78 #if (L1_AAC == 1) |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
79 #include "l1aac_defty.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
80 #endif |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
81 #include "l1_defty.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
82 #include "l1_varex.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
83 #include "../../gpf/inc/cust_os.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
84 #include "l1_msgty.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
85 #include "tpudrv.h" |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
86 |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
87 #endif |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
88 |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
89 UWORD8 *mode_authorized = &(l1s.pw_mgr.mode_authorized); |
8d6062f4e7e4
L1: l1_small.c reworked for FreeCalypso
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
90 UWORD8 *switch_PWR_MNGT = &(l1_config.pwr_mngt); |