diff options
author | Thom Johansen <thomj@rockbox.org> | 2006-01-17 21:38:16 +0000 |
---|---|---|
committer | Thom Johansen <thomj@rockbox.org> | 2006-01-17 21:38:16 +0000 |
commit | 507ff53c9c429de6c3bf5bfd6eb1a129cfc12cad (patch) | |
tree | 5394ddf6658b1409a6ae245e33bc3ff59a127902 | |
parent | a40d355ee7c57b96dc3e5320f16ea6cc808483f3 (diff) | |
download | rockbox-507ff53c9c429de6c3bf5bfd6eb1a129cfc12cad.tar.gz rockbox-507ff53c9c429de6c3bf5bfd6eb1a129cfc12cad.zip |
Remove use of stdio.h. Proper handling of IRAM.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8361 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r-- | apps/plugins/mp3_encoder.c | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/apps/plugins/mp3_encoder.c b/apps/plugins/mp3_encoder.c index 1437ca2090..2fce02c705 100644 --- a/apps/plugins/mp3_encoder.c +++ b/apps/plugins/mp3_encoder.c | |||
@@ -11,8 +11,6 @@ | |||
11 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | 11 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
12 | // Library General Public License for more details. | 12 | // Library General Public License for more details. |
13 | 13 | ||
14 | #include <stdio.h> | ||
15 | |||
16 | #define samp_per_frame 1152 | 14 | #define samp_per_frame 1152 |
17 | #define samp_per_frame2 576 | 15 | #define samp_per_frame2 576 |
18 | #define HAN_SIZE 512 | 16 | #define HAN_SIZE 512 |
@@ -41,9 +39,14 @@ enum e_byte_order { order_unknown, order_bigEndian, order_littleEndian }; | |||
41 | PLUGIN_HEADER | 39 | PLUGIN_HEADER |
42 | 40 | ||
43 | static struct plugin_api* rb; | 41 | static struct plugin_api* rb; |
44 | extern char iramcopy[]; | 42 | |
45 | extern char iramstart[]; | 43 | #ifdef USE_IRAM |
46 | extern char iramend[]; | 44 | extern char iramcopy[]; |
45 | extern char iramstart[]; | ||
46 | extern char iramend[]; | ||
47 | extern char iedata[]; | ||
48 | extern char iend[]; | ||
49 | #endif | ||
47 | 50 | ||
48 | typedef struct { | 51 | typedef struct { |
49 | PFILE file; | 52 | PFILE file; |
@@ -1897,6 +1900,11 @@ enum plugin_status plugin_start(struct plugin_api* api, void* parameter) | |||
1897 | (void)parameter; | 1900 | (void)parameter; |
1898 | rb = api; | 1901 | rb = api; |
1899 | 1902 | ||
1903 | #ifdef USE_IRAM | ||
1904 | memcpy(iramstart, iramcopy, iramend - iramstart); | ||
1905 | memset(iedata, 0, iend - iedata); | ||
1906 | #endif | ||
1907 | |||
1900 | rb->lcd_setfont(FONT_SYSFIXED); | 1908 | rb->lcd_setfont(FONT_SYSFIXED); |
1901 | 1909 | ||
1902 | #ifdef HAVE_ADJUSTABLE_CPU_FREQ | 1910 | #ifdef HAVE_ADJUSTABLE_CPU_FREQ |