diff options
author | Daniel Stenberg <daniel@haxx.se> | 2006-08-01 22:28:14 +0000 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2006-08-01 22:28:14 +0000 |
commit | 0fc30d117412f2cbd8e00a043e0c901345125d31 (patch) | |
tree | 1cba88b9ed482cef7ca2bba3a2fc059a40221d43 | |
parent | 97cf946e4df08852b7ce17ecb7fe8425df67dc3f (diff) | |
download | rockbox-0fc30d117412f2cbd8e00a043e0c901345125d31.tar.gz rockbox-0fc30d117412f2cbd8e00a043e0c901345125d31.zip |
added mostly dummy changes to allow building of a Sansa e200 bootloader
without functionality
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@10399 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r-- | bootloader/SOURCES | 4 | ||||
-rw-r--r-- | bootloader/e200.c | 353 | ||||
-rw-r--r-- | firmware/FILES | 1 | ||||
-rw-r--r-- | firmware/SOURCES | 11 | ||||
-rw-r--r-- | firmware/drivers/serial.c | 3 | ||||
-rw-r--r-- | firmware/export/config-e200.h | 121 | ||||
-rw-r--r-- | firmware/export/config-h10.h | 120 | ||||
-rw-r--r-- | firmware/export/config.h | 9 | ||||
-rw-r--r-- | firmware/export/cpu.h | 3 | ||||
-rw-r--r-- | firmware/export/pp5024.h | 26 | ||||
-rw-r--r-- | firmware/kernel.c | 2 | ||||
-rw-r--r-- | firmware/pcm_playback.c | 3 | ||||
-rw-r--r-- | firmware/target/arm/sandisk/sansa-e200/ata-target.h | 1 | ||||
-rw-r--r-- | firmware/target/arm/sandisk/sansa-e200/ata.c | 198 | ||||
-rw-r--r-- | firmware/target/arm/sandisk/sansa-e200/backlight-target.h | 1 | ||||
-rw-r--r-- | firmware/target/arm/sandisk/sansa-e200/button-target.h | 7 | ||||
-rw-r--r-- | firmware/target/arm/sandisk/sansa-e200/lcd.c | 15 | ||||
-rw-r--r-- | firmware/target/arm/sandisk/sansa-e200/usb-target.h | 1 |
18 files changed, 874 insertions, 5 deletions
diff --git a/bootloader/SOURCES b/bootloader/SOURCES index 0c9aa8ba2f..8c3a9b8ee4 100644 --- a/bootloader/SOURCES +++ b/bootloader/SOURCES | |||
@@ -1,5 +1,9 @@ | |||
1 | #if (CONFIG_CPU == PP5002) || (CONFIG_CPU == PP5020) | 1 | #if (CONFIG_CPU == PP5002) || (CONFIG_CPU == PP5020) |
2 | ipod.c | 2 | ipod.c |
3 | #elif defined(SANSA_E200) | ||
4 | e200.c | ||
5 | #elif defined(IRIVER_H10) | ||
6 | h10.c | ||
3 | #else | 7 | #else |
4 | main.c | 8 | main.c |
5 | #endif | 9 | #endif |
diff --git a/bootloader/e200.c b/bootloader/e200.c new file mode 100644 index 0000000000..2cf78942a2 --- /dev/null +++ b/bootloader/e200.c | |||
@@ -0,0 +1,353 @@ | |||
1 | /*************************************************************************** | ||
2 | * __________ __ ___. | ||
3 | * Open \______ \ ____ ____ | | _\_ |__ _______ ___ | ||
4 | * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / | ||
5 | * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < < | ||
6 | * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ | ||
7 | * \/ \/ \/ \/ \/ | ||
8 | * $Id$ | ||
9 | * | ||
10 | * Copyright (C) 2005 by Dave Chapman | ||
11 | * | ||
12 | * Based on ipod.c by Dave Chapman | ||
13 | * Based on Rockbox iriver bootloader by Linus Nielsen Feltzing | ||
14 | * and the ipodlinux bootloader by Daniel Palffy and Bernard Leach | ||
15 | * | ||
16 | * All files in this archive are subject to the GNU General Public License. | ||
17 | * See the file COPYING in the source tree root for full license agreement. | ||
18 | * | ||
19 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY | ||
20 | * KIND, either express or implied. | ||
21 | * | ||
22 | ****************************************************************************/ | ||
23 | #include "config.h" | ||
24 | |||
25 | #include <stdlib.h> | ||
26 | #include <stdio.h> | ||
27 | #include <string.h> | ||
28 | #include "cpu.h" | ||
29 | #include "system.h" | ||
30 | #include "lcd.h" | ||
31 | #include "kernel.h" | ||
32 | #include "thread.h" | ||
33 | #include "ata.h" | ||
34 | #include "fat.h" | ||
35 | #include "disk.h" | ||
36 | #include "font.h" | ||
37 | #include "adc.h" | ||
38 | #include "backlight.h" | ||
39 | #include "panic.h" | ||
40 | #include "power.h" | ||
41 | #include "file.h" | ||
42 | |||
43 | #define XSC(X) #X | ||
44 | #define SC(X) XSC(X) | ||
45 | |||
46 | #define DRAM_START 0x10000000 | ||
47 | |||
48 | #define BUTTON_LEFT 1 | ||
49 | #define BUTTON_MENU 2 | ||
50 | #define BUTTON_RIGHT 3 | ||
51 | #define BUTTON_PLAY 4 | ||
52 | #define BUTTON_HOLD 5 | ||
53 | |||
54 | /* Size of the buffer to store the loaded Rockbox/Linux image */ | ||
55 | #define MAX_LOADSIZE (4*1024*1024) | ||
56 | |||
57 | char version[] = APPSVERSION; | ||
58 | |||
59 | typedef struct _image { | ||
60 | unsigned type; /* '' */ | ||
61 | unsigned id; /* */ | ||
62 | unsigned pad1; /* 0000 0000 */ | ||
63 | unsigned devOffset; /* byte offset of start of image code */ | ||
64 | unsigned len; /* length in bytes of image */ | ||
65 | void *addr; /* load address */ | ||
66 | unsigned entryOffset; /* execution start within image */ | ||
67 | unsigned chksum; /* checksum for image */ | ||
68 | unsigned vers; /* image version */ | ||
69 | unsigned loadAddr; /* load address for image */ | ||
70 | } image_t; | ||
71 | |||
72 | extern image_t boot_table[]; | ||
73 | |||
74 | int line=0; | ||
75 | |||
76 | static void memmove16(void *dest, const void *src, unsigned count) | ||
77 | { | ||
78 | struct bufstr { | ||
79 | unsigned _buf[4]; | ||
80 | } *d, *s; | ||
81 | |||
82 | if (src >= dest) { | ||
83 | count = (count + 15) >> 4; | ||
84 | d = (struct bufstr *) dest; | ||
85 | s = (struct bufstr *) src; | ||
86 | while (count--) | ||
87 | *d++ = *s++; | ||
88 | } else { | ||
89 | count = (count + 15) >> 4; | ||
90 | d = (struct bufstr *)(dest + (count <<4)); | ||
91 | s = (struct bufstr *)(src + (count <<4)); | ||
92 | while (count--) | ||
93 | *--d = *--s; | ||
94 | } | ||
95 | } | ||
96 | |||
97 | #if CONFIG_KEYPAD == IPOD_4G_PAD && !defined(IPOD_MINI) | ||
98 | /* check if number of seconds has past */ | ||
99 | int timer_check(int clock_start, unsigned int usecs) | ||
100 | { | ||
101 | if ((USEC_TIMER - clock_start) >= usecs) { | ||
102 | return 1; | ||
103 | } else { | ||
104 | return 0; | ||
105 | } | ||
106 | } | ||
107 | |||
108 | static void ser_opto_keypad_cfg(int val) | ||
109 | { | ||
110 | int start_time; | ||
111 | |||
112 | outl(inl(0x6000d004) & ~0x80, 0x6000d004); | ||
113 | |||
114 | outl(inl(0x7000c104) | 0xc000000, 0x7000c104); | ||
115 | outl(val, 0x7000c120); | ||
116 | outl(inl(0x7000c100) | 0x80000000, 0x7000c100); | ||
117 | |||
118 | outl(inl(0x6000d024) & ~0x10, 0x6000d024); | ||
119 | outl(inl(0x6000d014) | 0x10, 0x6000d014); | ||
120 | |||
121 | start_time = USEC_TIMER; | ||
122 | do { | ||
123 | if ((inl(0x7000c104) & 0x80000000) == 0) { | ||
124 | break; | ||
125 | } | ||
126 | } while (timer_check(start_time, 1500) != 0); | ||
127 | |||
128 | outl(inl(0x7000c100) & ~0x80000000, 0x7000c100); | ||
129 | |||
130 | outl(inl(0x6000d004) | 0x80, 0x6000d004); | ||
131 | outl(inl(0x6000d024) | 0x10, 0x6000d024); | ||
132 | outl(inl(0x6000d014) & ~0x10, 0x6000d014); | ||
133 | |||
134 | outl(inl(0x7000c104) | 0xc000000, 0x7000c104); | ||
135 | outl(inl(0x7000c100) | 0x60000000, 0x7000c100); | ||
136 | } | ||
137 | |||
138 | int opto_keypad_read(void) | ||
139 | { | ||
140 | int loop_cnt, had_io = 0; | ||
141 | |||
142 | for (loop_cnt = 5; loop_cnt != 0;) | ||
143 | { | ||
144 | int key_pressed = 0; | ||
145 | int start_time; | ||
146 | unsigned int key_pad_val; | ||
147 | |||
148 | ser_opto_keypad_cfg(0x8000023a); | ||
149 | |||
150 | start_time = USEC_TIMER; | ||
151 | do { | ||
152 | if (inl(0x7000c104) & 0x4000000) { | ||
153 | had_io = 1; | ||
154 | break; | ||
155 | } | ||
156 | |||
157 | if (had_io != 0) { | ||
158 | break; | ||
159 | } | ||
160 | } while (timer_check(start_time, 1500) != 0); | ||
161 | |||
162 | key_pad_val = inl(0x7000c140); | ||
163 | if ((key_pad_val & ~0x7fff0000) != 0x8000023a) { | ||
164 | loop_cnt--; | ||
165 | } else { | ||
166 | key_pad_val = (key_pad_val << 11) >> 27; | ||
167 | key_pressed = 1; | ||
168 | } | ||
169 | |||
170 | outl(inl(0x7000c100) | 0x60000000, 0x7000c100); | ||
171 | outl(inl(0x7000c104) | 0xc000000, 0x7000c104); | ||
172 | |||
173 | if (key_pressed != 0) { | ||
174 | return key_pad_val ^ 0x1f; | ||
175 | } | ||
176 | } | ||
177 | |||
178 | return 0; | ||
179 | } | ||
180 | #endif | ||
181 | |||
182 | static int key_pressed(void) | ||
183 | { | ||
184 | unsigned char state; | ||
185 | |||
186 | #if CONFIG_KEYPAD == IPOD_4G_PAD | ||
187 | #ifdef IPOD_MINI /* mini 1G only */ | ||
188 | state = GPIOA_INPUT_VAL & 0x3f; | ||
189 | if ((state & 0x10) == 0) return BUTTON_LEFT; | ||
190 | if ((state & 0x2) == 0) return BUTTON_MENU; | ||
191 | if ((state & 0x4) == 0) return BUTTON_PLAY; | ||
192 | if ((state & 0x8) == 0) return BUTTON_RIGHT; | ||
193 | #else | ||
194 | state = opto_keypad_read(); | ||
195 | if ((state & 0x4) == 0) return BUTTON_LEFT; | ||
196 | if ((state & 0x10) == 0) return BUTTON_MENU; | ||
197 | if ((state & 0x8) == 0) return BUTTON_PLAY; | ||
198 | if ((state & 0x2) == 0) return BUTTON_RIGHT; | ||
199 | #endif | ||
200 | #elif CONFIG_KEYPAD == IPOD_3G_PAD | ||
201 | state = inb(0xcf000030); | ||
202 | if (((state & 0x20) == 0)) return BUTTON_HOLD; /* hold on */ | ||
203 | if ((state & 0x08) == 0) return BUTTON_LEFT; | ||
204 | if ((state & 0x10) == 0) return BUTTON_MENU; | ||
205 | if ((state & 0x04) == 0) return BUTTON_PLAY; | ||
206 | if ((state & 0x01) == 0) return BUTTON_RIGHT; | ||
207 | #endif | ||
208 | return 0; | ||
209 | } | ||
210 | |||
211 | int load_rockbox(unsigned char* buf) | ||
212 | { | ||
213 | int fd; | ||
214 | int rc; | ||
215 | int len; | ||
216 | unsigned long chksum; | ||
217 | char model[5]; | ||
218 | unsigned long sum; | ||
219 | int i; | ||
220 | char str[80]; | ||
221 | |||
222 | fd = open("/.rockbox/" BOOTFILE, O_RDONLY); | ||
223 | if(fd < 0) | ||
224 | { | ||
225 | fd = open("/" BOOTFILE, O_RDONLY); | ||
226 | if(fd < 0) | ||
227 | return -1; | ||
228 | } | ||
229 | |||
230 | len = filesize(fd) - 8; | ||
231 | |||
232 | if (len > MAX_LOADSIZE) | ||
233 | return -6; | ||
234 | |||
235 | lseek(fd, FIRMWARE_OFFSET_FILE_CRC, SEEK_SET); | ||
236 | |||
237 | rc = read(fd, &chksum, 4); | ||
238 | chksum=betoh32(chksum); /* Rockbox checksums are big-endian */ | ||
239 | if(rc < 4) | ||
240 | return -2; | ||
241 | |||
242 | rc = read(fd, model, 4); | ||
243 | if(rc < 4) | ||
244 | return -3; | ||
245 | |||
246 | model[4] = 0; | ||
247 | |||
248 | snprintf(str, 80, "Model: %s", model); | ||
249 | lcd_puts(0, line++, str); | ||
250 | snprintf(str, 80, "Checksum: %x", chksum); | ||
251 | lcd_puts(0, line++, str); | ||
252 | lcd_update(); | ||
253 | |||
254 | lseek(fd, FIRMWARE_OFFSET_FILE_DATA, SEEK_SET); | ||
255 | |||
256 | rc = read(fd, buf, len); | ||
257 | if(rc < len) | ||
258 | return -4; | ||
259 | |||
260 | close(fd); | ||
261 | |||
262 | sum = MODEL_NUMBER; | ||
263 | |||
264 | for(i = 0;i < len;i++) { | ||
265 | sum += buf[i]; | ||
266 | } | ||
267 | |||
268 | snprintf(str, 80, "Sum: %x", sum); | ||
269 | lcd_puts(0, line++, str); | ||
270 | lcd_update(); | ||
271 | |||
272 | if(sum != chksum) | ||
273 | return -5; | ||
274 | |||
275 | return len; | ||
276 | } | ||
277 | |||
278 | |||
279 | /* A buffer to load the Linux kernel or Rockbox into */ | ||
280 | unsigned char loadbuffer[MAX_LOADSIZE]; | ||
281 | |||
282 | void* main(void) | ||
283 | { | ||
284 | char buf[256]; | ||
285 | int imageno=0; | ||
286 | int i; | ||
287 | int rc; | ||
288 | int padding = 0x4400; | ||
289 | image_t *tblp = boot_table; | ||
290 | void* entry; | ||
291 | struct partinfo* pinfo; | ||
292 | unsigned short* identify_info; | ||
293 | |||
294 | /* Turn on the backlight */ | ||
295 | |||
296 | #if CONFIG_BACKLIGHT==BL_IPOD4G | ||
297 | /* brightness full */ | ||
298 | outl(0x80000000 | (0xff << 16), 0x7000a010); | ||
299 | |||
300 | /* set port B03 on */ | ||
301 | outl(((0x100 | 1) << 3), 0x6000d824); | ||
302 | |||
303 | #elif CONFIG_BACKLIGHT==BL_IPODMINI | ||
304 | /* set port B03 on */ | ||
305 | outl(((0x100 | 1) << 3), 0x6000d824); | ||
306 | |||
307 | #elif CONFIG_BACKLIGHT==BL_IPODNANO | ||
308 | |||
309 | /* set port B03 on */ | ||
310 | outl(((0x100 | 1) << 3), 0x6000d824); | ||
311 | |||
312 | /* set port L07 on */ | ||
313 | outl(((0x100 | 1) << 7), 0x6000d12c); | ||
314 | #elif CONFIG_BACKLIGHT==BL_IPOD3G | ||
315 | outl(inl(IPOD_LCD_BASE) | 0x2, IPOD_LCD_BASE); | ||
316 | #endif | ||
317 | |||
318 | /* Return the start address in loaded image */ | ||
319 | return entry; | ||
320 | } | ||
321 | |||
322 | /* These functions are present in the firmware library, but we reimplement | ||
323 | them here because the originals do a lot more than we want */ | ||
324 | |||
325 | void reset_poweroff_timer(void) | ||
326 | { | ||
327 | } | ||
328 | |||
329 | int dbg_ports(void) | ||
330 | { | ||
331 | return 0; | ||
332 | } | ||
333 | |||
334 | void mpeg_stop(void) | ||
335 | { | ||
336 | } | ||
337 | |||
338 | void usb_acknowledge(void) | ||
339 | { | ||
340 | } | ||
341 | |||
342 | void usb_wait_for_disconnect(void) | ||
343 | { | ||
344 | } | ||
345 | |||
346 | void sys_poweroff(void) | ||
347 | { | ||
348 | } | ||
349 | |||
350 | void system_reboot(void) | ||
351 | { | ||
352 | |||
353 | } | ||
diff --git a/firmware/FILES b/firmware/FILES index d12ba2dace..a99deba0b4 100644 --- a/firmware/FILES +++ b/firmware/FILES | |||
@@ -16,3 +16,4 @@ target/arm/*.[chS] | |||
16 | target/sh/*.[chS] | 16 | target/sh/*.[chS] |
17 | target/coldfire/*.[chS] | 17 | target/coldfire/*.[chS] |
18 | target/coldfire/iaudio/x5/*.[chS] | 18 | target/coldfire/iaudio/x5/*.[chS] |
19 | target/arm/sandisk/sansa-e200/*.[chS] | ||
diff --git a/firmware/SOURCES b/firmware/SOURCES index 601fcab3a2..a4f35a2d6f 100644 --- a/firmware/SOURCES +++ b/firmware/SOURCES | |||
@@ -96,12 +96,12 @@ drivers/lcd-ipodvideo.c | |||
96 | #if CONFIG_LCD==LCD_H300 | 96 | #if CONFIG_LCD==LCD_H300 |
97 | drivers/lcd-h300.c | 97 | drivers/lcd-h300.c |
98 | #endif | 98 | #endif |
99 | #ifndef IAUDIO_X5 | 99 | #ifndef TARGET_TREE |
100 | drivers/power.c | 100 | drivers/power.c |
101 | #endif | 101 | #endif |
102 | drivers/led.c | 102 | drivers/led.c |
103 | #ifndef SIMULATOR | 103 | #ifndef SIMULATOR |
104 | #ifndef IAUDIO_X5 | 104 | #ifndef TARGET_TREE |
105 | drivers/adc.c | 105 | drivers/adc.c |
106 | #endif | 106 | #endif |
107 | #ifdef HAVE_MMC | 107 | #ifdef HAVE_MMC |
@@ -110,9 +110,11 @@ drivers/ata_mmc.c | |||
110 | #ifdef HAVE_FLASH_DISK | 110 | #ifdef HAVE_FLASH_DISK |
111 | drivers/ata_flash.c | 111 | drivers/ata_flash.c |
112 | #else | 112 | #else |
113 | #ifndef SANSA_E200 | ||
113 | drivers/ata.c | 114 | drivers/ata.c |
114 | #endif | 115 | #endif |
115 | #endif | 116 | #endif |
117 | #endif | ||
116 | drivers/button.c | 118 | drivers/button.c |
117 | drivers/dac.c | 119 | drivers/dac.c |
118 | drivers/fat.c | 120 | drivers/fat.c |
@@ -217,6 +219,11 @@ drivers/isp1362.c | |||
217 | drivers/m5636.c | 219 | drivers/m5636.c |
218 | #endif | 220 | #endif |
219 | 221 | ||
222 | #ifdef SANSA_E200 | ||
223 | target/arm/sandisk/sansa-e200/ata.c | ||
224 | target/arm/sandisk/sansa-e200/lcd.c | ||
225 | #endif | ||
226 | |||
220 | #ifdef IAUDIO_X5 | 227 | #ifdef IAUDIO_X5 |
221 | target/coldfire/iaudio/x5/power-x5.c | 228 | target/coldfire/iaudio/x5/power-x5.c |
222 | #ifndef SIMULATOR | 229 | #ifndef SIMULATOR |
diff --git a/firmware/drivers/serial.c b/firmware/drivers/serial.c index 8479da52f8..f1cee96d51 100644 --- a/firmware/drivers/serial.c +++ b/firmware/drivers/serial.c | |||
@@ -30,7 +30,8 @@ | |||
30 | 30 | ||
31 | #if (CONFIG_CPU != MCF5249) && (CONFIG_CPU != TCC730) && \ | 31 | #if (CONFIG_CPU != MCF5249) && (CONFIG_CPU != TCC730) && \ |
32 | (CONFIG_CPU != PP5020) && (CONFIG_CPU != PNX0101) && \ | 32 | (CONFIG_CPU != PP5020) && (CONFIG_CPU != PNX0101) && \ |
33 | (CONFIG_CPU != PP5002) && (CONFIG_CPU != MCF5250) | 33 | (CONFIG_CPU != PP5002) && (CONFIG_CPU != MCF5250) && \ |
34 | (CONFIG_CPU != PP5024) | ||
34 | 35 | ||
35 | /* FIX: this doesn't work on iRiver or Gmini or iPod yet */ | 36 | /* FIX: this doesn't work on iRiver or Gmini or iPod yet */ |
36 | /* iFP7xx has no remote */ | 37 | /* iFP7xx has no remote */ |
diff --git a/firmware/export/config-e200.h b/firmware/export/config-e200.h new file mode 100644 index 0000000000..3793a716ec --- /dev/null +++ b/firmware/export/config-e200.h | |||
@@ -0,0 +1,121 @@ | |||
1 | /* | ||
2 | * This config file is for the Sandisk Sansa e200 | ||
3 | */ | ||
4 | #define TARGET_TREE /* this target is using the target tree system */ | ||
5 | |||
6 | /* For Rolo and boot loader */ | ||
7 | #define MODEL_NUMBER 12 | ||
8 | |||
9 | /* define this if you have recording possibility */ | ||
10 | /*#define HAVE_RECORDING 1*/ /* TODO: add support for this */ | ||
11 | |||
12 | /* define this if you have a bitmap LCD display */ | ||
13 | #define HAVE_LCD_BITMAP 1 | ||
14 | |||
15 | /* define this if you have a colour LCD */ | ||
16 | #define HAVE_LCD_COLOR 1 | ||
17 | |||
18 | /* define this if you have access to the quickscreen */ | ||
19 | #define HAVE_QUICKSCREEN | ||
20 | |||
21 | /* LCD dimensions */ | ||
22 | #define LCD_WIDTH 176 | ||
23 | #define LCD_HEIGHT 220 | ||
24 | #define LCD_DEPTH 16 /* 65536 colours */ | ||
25 | #define LCD_PIXELFORMAT RGB565SWAPPED /* rgb565 byte-swapped */ | ||
26 | |||
27 | /* #define IRAM_LCDFRAMEBUFFER IDATA_ATTR *//* put the lcd frame buffer in IRAM */ | ||
28 | |||
29 | #define CONFIG_KEYPAD SANSA_E200_PAD | ||
30 | |||
31 | /* Define this if you do software codec */ | ||
32 | #define CONFIG_CODEC SWCODEC | ||
33 | |||
34 | /* define this if you have a real-time clock */ | ||
35 | #ifndef BOOTLOADER | ||
36 | #define CONFIG_RTC RTC_E8564 /* TODO: figure this out */ | ||
37 | #endif | ||
38 | |||
39 | /* Define this if you have a software controlled poweroff */ | ||
40 | #define HAVE_SW_POWEROFF | ||
41 | |||
42 | /* The number of bytes reserved for loadable codecs */ | ||
43 | #define CODEC_SIZE 0x80000 | ||
44 | |||
45 | /* The number of bytes reserved for loadable plugins */ | ||
46 | #define PLUGIN_BUFFER_SIZE 0x80000 | ||
47 | |||
48 | /* Define this if you have the WM8975 audio codec */ | ||
49 | #define HAVE_WM8731 | ||
50 | |||
51 | #define AB_REPEAT_ENABLE 1 | ||
52 | |||
53 | /* FM Tuner */ | ||
54 | /*#define CONFIG_TUNER TEA5767 | ||
55 | #define CONFIG_TUNER_XTAL 32768 *//* TODO: what is this? */ | ||
56 | |||
57 | /* Define this for LCD backlight available */ | ||
58 | #define CONFIG_BACKLIGHT BL_H10 /* TODO: figure this out, probably not necessary | ||
59 | because of 'target' stuff */ | ||
60 | |||
61 | #define BATTERY_CAPACITY_DEFAULT 700 /* default battery capacity | ||
62 | TODO: check this, probably different | ||
63 | for different models too */ | ||
64 | |||
65 | #ifndef SIMULATOR | ||
66 | |||
67 | /* Define this if you have a PortalPlayer PP5024 */ | ||
68 | #define CONFIG_CPU PP5024 | ||
69 | |||
70 | /* Define this if you want to use the PP5020 i2c interface */ | ||
71 | #define CONFIG_I2C I2C_PP5020 | ||
72 | |||
73 | /* Type of mobile power */ | ||
74 | #define CONFIG_BATTERY BATT_LPCS355385 | ||
75 | #define BATTERY_CAPACITY_MIN 1500 /* min. capacity selectable */ | ||
76 | #define BATTERY_CAPACITY_MAX 1600 /* max. capacity selectable */ | ||
77 | #define BATTERY_CAPACITY_INC 10 /* capacity increment */ | ||
78 | #define BATTERY_TYPES_COUNT 1 /* only one type */ | ||
79 | #define BATTERY_SCALE_FACTOR 5865 | ||
80 | |||
81 | /* Hardware controlled charging? FIXME */ | ||
82 | //#define CONFIG_CHARGING CHARGING_SIMPLE | ||
83 | |||
84 | /* define this if the hardware can be powered off while charging */ | ||
85 | /* TODO: should this be set for the H10? */ | ||
86 | //#define HAVE_POWEROFF_WHILE_CHARGING | ||
87 | |||
88 | /* The start address index for ROM builds */ | ||
89 | #define ROM_START 0x00000000 | ||
90 | |||
91 | /* Define this to the CPU frequency */ | ||
92 | /* TODO: this is probably wrong */ | ||
93 | #define CPU_FREQ 11289600 | ||
94 | |||
95 | /* Type of LCD TODO: hopefully the same as the x5 but check this*/ | ||
96 | #define CONFIG_LCD LCD_X5 | ||
97 | |||
98 | /* Offset ( in the firmware file's header ) to the file length */ | ||
99 | #define FIRMWARE_OFFSET_FILE_LENGTH 0 | ||
100 | |||
101 | /* Offset ( in the firmware file's header ) to the file CRC */ | ||
102 | #define FIRMWARE_OFFSET_FILE_CRC 0 | ||
103 | |||
104 | /* Offset ( in the firmware file's header ) to the real data */ | ||
105 | #define FIRMWARE_OFFSET_FILE_DATA 8 | ||
106 | |||
107 | /* #define USB_IPODSTYLE */ | ||
108 | |||
109 | /* define this if the unit can be powered or charged via USB */ | ||
110 | #define HAVE_USB_POWER | ||
111 | |||
112 | /* Virtual LED (icon) */ | ||
113 | #define CONFIG_LED LED_VIRTUAL | ||
114 | |||
115 | /* Define this if you have adjustable CPU frequency */ | ||
116 | /*#define HAVE_ADJUSTABLE_CPU_FREQ Let's say we don't for now*/ | ||
117 | |||
118 | #define BOOTFILE_EXT "e200" | ||
119 | #define BOOTFILE "rockbox." BOOTFILE_EXT | ||
120 | |||
121 | #endif | ||
diff --git a/firmware/export/config-h10.h b/firmware/export/config-h10.h new file mode 100644 index 0000000000..470ff6b4fa --- /dev/null +++ b/firmware/export/config-h10.h | |||
@@ -0,0 +1,120 @@ | |||
1 | /* | ||
2 | * This config file is for the iriver H10 | ||
3 | */ | ||
4 | |||
5 | /* For Rolo and boot loader */ | ||
6 | #define MODEL_NUMBER 11 | ||
7 | |||
8 | /* define this if you have recording possibility */ | ||
9 | /*#define HAVE_RECORDING 1*/ /* TODO: add support for this */ | ||
10 | |||
11 | /* define this if you have a bitmap LCD display */ | ||
12 | #define HAVE_LCD_BITMAP 1 | ||
13 | |||
14 | /* define this if you have a colour LCD */ | ||
15 | #define HAVE_LCD_COLOR 1 | ||
16 | |||
17 | /* define this if you have access to the quickscreen */ | ||
18 | #define HAVE_QUICKSCREEN | ||
19 | |||
20 | /* LCD dimensions */ | ||
21 | #define LCD_WIDTH 160 | ||
22 | #define LCD_HEIGHT 128 | ||
23 | #define LCD_DEPTH 16 /* 65536 colours */ | ||
24 | #define LCD_PIXELFORMAT RGB565SWAPPED /* rgb565 byte-swapped */ | ||
25 | |||
26 | /* #define IRAM_LCDFRAMEBUFFER IDATA_ATTR *//* put the lcd frame buffer in IRAM */ | ||
27 | |||
28 | #define CONFIG_KEYPAD IRIVER_H10_PAD | ||
29 | |||
30 | /* Define this if you do software codec */ | ||
31 | #define CONFIG_CODEC SWCODEC | ||
32 | |||
33 | /* define this if you have a real-time clock */ | ||
34 | #ifndef BOOTLOADER | ||
35 | #define CONFIG_RTC RTC_E8564 /* TODO: figure this out */ | ||
36 | #endif | ||
37 | |||
38 | /* Define this if you have a software controlled poweroff */ | ||
39 | #define HAVE_SW_POWEROFF | ||
40 | |||
41 | /* The number of bytes reserved for loadable codecs */ | ||
42 | #define CODEC_SIZE 0x80000 | ||
43 | |||
44 | /* The number of bytes reserved for loadable plugins */ | ||
45 | #define PLUGIN_BUFFER_SIZE 0x80000 | ||
46 | |||
47 | /* Define this if you have the WM8975 audio codec */ | ||
48 | #define HAVE_WM8731 | ||
49 | |||
50 | #define AB_REPEAT_ENABLE 1 | ||
51 | |||
52 | /* FM Tuner */ | ||
53 | /*#define CONFIG_TUNER TEA5767 | ||
54 | #define CONFIG_TUNER_XTAL 32768 *//* TODO: what is this? */ | ||
55 | |||
56 | /* Define this for LCD backlight available */ | ||
57 | #define CONFIG_BACKLIGHT BL_H10 /* TODO: figure this out, probably not necessary | ||
58 | because of 'target' stuff */ | ||
59 | |||
60 | #define BATTERY_CAPACITY_DEFAULT 700 /* default battery capacity | ||
61 | TODO: check this, probably different | ||
62 | for different models too */ | ||
63 | |||
64 | #ifndef SIMULATOR | ||
65 | |||
66 | /* Define this if you have a PortalPlayer PP5020 */ | ||
67 | #define CONFIG_CPU PP5020 | ||
68 | |||
69 | /* Define this if you want to use the PP5020 i2c interface */ | ||
70 | #define CONFIG_I2C I2C_PP5020 | ||
71 | |||
72 | /* Type of mobile power */ | ||
73 | #define CONFIG_BATTERY BATT_LPCS355385 | ||
74 | #define BATTERY_CAPACITY_MIN 1500 /* min. capacity selectable */ | ||
75 | #define BATTERY_CAPACITY_MAX 1600 /* max. capacity selectable */ | ||
76 | #define BATTERY_CAPACITY_INC 10 /* capacity increment */ | ||
77 | #define BATTERY_TYPES_COUNT 1 /* only one type */ | ||
78 | #define BATTERY_SCALE_FACTOR 5865 | ||
79 | |||
80 | /* Hardware controlled charging? FIXME */ | ||
81 | //#define CONFIG_CHARGING CHARGING_SIMPLE | ||
82 | |||
83 | /* define this if the hardware can be powered off while charging */ | ||
84 | /* TODO: should this be set for the H10? */ | ||
85 | //#define HAVE_POWEROFF_WHILE_CHARGING | ||
86 | |||
87 | /* The start address index for ROM builds */ | ||
88 | #define ROM_START 0x00000000 | ||
89 | |||
90 | /* Define this to the CPU frequency */ | ||
91 | /* TODO: this is probably wrong */ | ||
92 | #define CPU_FREQ 11289600 | ||
93 | |||
94 | /* Type of LCD TODO: hopefully the same as the x5 but check this*/ | ||
95 | #define CONFIG_LCD LCD_X5 | ||
96 | |||
97 | /* Offset ( in the firmware file's header ) to the file length */ | ||
98 | #define FIRMWARE_OFFSET_FILE_LENGTH 0 | ||
99 | |||
100 | /* Offset ( in the firmware file's header ) to the file CRC */ | ||
101 | #define FIRMWARE_OFFSET_FILE_CRC 0 | ||
102 | |||
103 | /* Offset ( in the firmware file's header ) to the real data */ | ||
104 | #define FIRMWARE_OFFSET_FILE_DATA 8 | ||
105 | |||
106 | /* #define USB_IPODSTYLE */ | ||
107 | |||
108 | /* define this if the unit can be powered or charged via USB */ | ||
109 | #define HAVE_USB_POWER | ||
110 | |||
111 | /* Virtual LED (icon) */ | ||
112 | #define CONFIG_LED LED_VIRTUAL | ||
113 | |||
114 | /* Define this if you have adjustable CPU frequency */ | ||
115 | #define HAVE_ADJUSTABLE_CPU_FREQ | ||
116 | |||
117 | #define BOOTFILE_EXT "h10" | ||
118 | #define BOOTFILE "rockbox." BOOTFILE_EXT | ||
119 | |||
120 | #endif | ||
diff --git a/firmware/export/config.h b/firmware/export/config.h index 684353e499..9b3945640e 100644 --- a/firmware/export/config.h +++ b/firmware/export/config.h | |||
@@ -56,6 +56,8 @@ | |||
56 | #define IPOD_3G_PAD 8 | 56 | #define IPOD_3G_PAD 8 |
57 | #define IRIVER_IFP7XX_PAD 9 | 57 | #define IRIVER_IFP7XX_PAD 9 |
58 | #define GIGABEAT_PAD 10 | 58 | #define GIGABEAT_PAD 10 |
59 | #define IRIVER_H10_PAD 11 | ||
60 | #define SANSA_E200_PAD 12 | ||
59 | 61 | ||
60 | /* CONFIG_REMOTE_KEYPAD */ | 62 | /* CONFIG_REMOTE_KEYPAD */ |
61 | #define H100_REMOTE 1 | 63 | #define H100_REMOTE 1 |
@@ -67,6 +69,7 @@ | |||
67 | #define BATT_4AA_NIMH 1500 | 69 | #define BATT_4AA_NIMH 1500 |
68 | #define BATT_3AAA 1000 /* Ondio */ | 70 | #define BATT_3AAA 1000 /* Ondio */ |
69 | #define BATT_LIPOL1300 1300 /* the type used in iRiver h1x0 models */ | 71 | #define BATT_LIPOL1300 1300 /* the type used in iRiver h1x0 models */ |
72 | #define BATT_LPCS355385 1550 /* iriver h10 - SKC LPCS355385 */ | ||
70 | 73 | ||
71 | /* CONFIG_CHARGING */ | 74 | /* CONFIG_CHARGING */ |
72 | #define CHARGING_SIMPLE 1 /* Simple, hardware controlled charging */ | 75 | #define CHARGING_SIMPLE 1 /* Simple, hardware controlled charging */ |
@@ -182,6 +185,10 @@ | |||
182 | #include "config-ipodmini.h" | 185 | #include "config-ipodmini.h" |
183 | #elif defined(IPOD_MINI2G) | 186 | #elif defined(IPOD_MINI2G) |
184 | #include "config-ipodmini2g.h" | 187 | #include "config-ipodmini2g.h" |
188 | #elif defined(IRIVER_H10) | ||
189 | #include "config-h10.h" | ||
190 | #elif defined(SANSA_E200) | ||
191 | #include "config-e200.h" | ||
185 | #else | 192 | #else |
186 | /* no known platform */ | 193 | /* no known platform */ |
187 | #endif | 194 | #endif |
@@ -203,7 +210,7 @@ | |||
203 | #endif | 210 | #endif |
204 | 211 | ||
205 | /* define for all cpus from ARM family */ | 212 | /* define for all cpus from ARM family */ |
206 | #if (CONFIG_CPU == PP5002) || (CONFIG_CPU == PP5020) || (CONFIG_CPU == PNX0101) || (CONFIG_CPU == S3C2440) | 213 | #if (CONFIG_CPU == PP5002) || (CONFIG_CPU == PP5020) || (CONFIG_CPU == PNX0101) || (CONFIG_CPU == S3C2440) || (CONFIG_CPU == PP5024) |
207 | #define CPU_ARM | 214 | #define CPU_ARM |
208 | #endif | 215 | #endif |
209 | 216 | ||
diff --git a/firmware/export/cpu.h b/firmware/export/cpu.h index 4c33ac96f4..93b66aac52 100644 --- a/firmware/export/cpu.h +++ b/firmware/export/cpu.h | |||
@@ -36,6 +36,9 @@ | |||
36 | #if CONFIG_CPU == PP5002 | 36 | #if CONFIG_CPU == PP5002 |
37 | #include "pp5002.h" | 37 | #include "pp5002.h" |
38 | #endif | 38 | #endif |
39 | #if CONFIG_CPU == PP5024 | ||
40 | #include "pp5024.h" | ||
41 | #endif | ||
39 | #if CONFIG_CPU == PNX0101 | 42 | #if CONFIG_CPU == PNX0101 |
40 | #include "pnx0101.h" | 43 | #include "pnx0101.h" |
41 | #endif | 44 | #endif |
diff --git a/firmware/export/pp5024.h b/firmware/export/pp5024.h new file mode 100644 index 0000000000..3ed3d5dade --- /dev/null +++ b/firmware/export/pp5024.h | |||
@@ -0,0 +1,26 @@ | |||
1 | #ifndef __PP5024_H__ | ||
2 | #define __PP5024_H__ | ||
3 | /*************************************************************************** | ||
4 | * __________ __ ___. | ||
5 | * Open \______ \ ____ ____ | | _\_ |__ _______ ___ | ||
6 | * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / | ||
7 | * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < < | ||
8 | * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ | ||
9 | * \/ \/ \/ \/ \/ | ||
10 | * $Id$ | ||
11 | * | ||
12 | * Copyright (C) 2006 by Daniel Stenberg | ||
13 | * | ||
14 | * All files in this archive are subject to the GNU General Public License. | ||
15 | * See the file COPYING in the source tree root for full license agreement. | ||
16 | * | ||
17 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY | ||
18 | * KIND, either express or implied. | ||
19 | * | ||
20 | ****************************************************************************/ | ||
21 | |||
22 | /* We believe is this quite similar to the 5020 and for how we just use that | ||
23 | completely */ | ||
24 | #include "pp5020.h" | ||
25 | |||
26 | #endif | ||
diff --git a/firmware/kernel.c b/firmware/kernel.c index c5edacabec..c931a1db72 100644 --- a/firmware/kernel.c +++ b/firmware/kernel.c | |||
@@ -344,7 +344,7 @@ void tick_start(unsigned int interval_in_ms) | |||
344 | IMR0 |= (1<<2); | 344 | IMR0 |= (1<<2); |
345 | } | 345 | } |
346 | 346 | ||
347 | #elif (CONFIG_CPU == PP5002) || (CONFIG_CPU == PP5020) | 347 | #elif (CONFIG_CPU == PP5002) || (CONFIG_CPU == PP5020) || (CONFIG_CPU==PP5024) |
348 | 348 | ||
349 | #ifndef BOOTLOADER | 349 | #ifndef BOOTLOADER |
350 | void TIMER1(void) | 350 | void TIMER1(void) |
diff --git a/firmware/pcm_playback.c b/firmware/pcm_playback.c index 67e8b933ef..f7a2de52c2 100644 --- a/firmware/pcm_playback.c +++ b/firmware/pcm_playback.c | |||
@@ -248,6 +248,8 @@ void pcm_init(void) | |||
248 | #define FIFO_FREE_COUNT ((IISFIFO_CFG & 0x3f0000) >> 16) | 248 | #define FIFO_FREE_COUNT ((IISFIFO_CFG & 0x3f0000) >> 16) |
249 | #elif CONFIG_CPU == PP5002 | 249 | #elif CONFIG_CPU == PP5002 |
250 | #define FIFO_FREE_COUNT ((IISFIFO_CFG & 0x7800000) >> 23) | 250 | #define FIFO_FREE_COUNT ((IISFIFO_CFG & 0x7800000) >> 23) |
251 | #elif CONFIG_CPU == PP5024 | ||
252 | #define FIFO_FREE_COUNT 4 /* TODO: make this sensible */ | ||
251 | #endif | 253 | #endif |
252 | 254 | ||
253 | static int pcm_freq = 44100; /* 44.1 is default */ | 255 | static int pcm_freq = 44100; /* 44.1 is default */ |
@@ -268,6 +270,7 @@ static void dma_start(const void *addr, size_t size) | |||
268 | /* setup I2S interrupt for FIQ */ | 270 | /* setup I2S interrupt for FIQ */ |
269 | outl(inl(0x6000402c) | I2S_MASK, 0x6000402c); | 271 | outl(inl(0x6000402c) | I2S_MASK, 0x6000402c); |
270 | outl(I2S_MASK, 0x60004024); | 272 | outl(I2S_MASK, 0x60004024); |
273 | #elif CONFIG_CPU == PP5024 | ||
271 | #else | 274 | #else |
272 | /* setup I2S interrupt for FIQ */ | 275 | /* setup I2S interrupt for FIQ */ |
273 | outl(inl(0xcf00102c) | DMA_OUT_MASK, 0xcf00102c); | 276 | outl(inl(0xcf00102c) | DMA_OUT_MASK, 0xcf00102c); |
diff --git a/firmware/target/arm/sandisk/sansa-e200/ata-target.h b/firmware/target/arm/sandisk/sansa-e200/ata-target.h new file mode 100644 index 0000000000..67a01ed518 --- /dev/null +++ b/firmware/target/arm/sandisk/sansa-e200/ata-target.h | |||
@@ -0,0 +1 @@ | |||
/* nothing here yet */ | |||
diff --git a/firmware/target/arm/sandisk/sansa-e200/ata.c b/firmware/target/arm/sandisk/sansa-e200/ata.c new file mode 100644 index 0000000000..0c37753c53 --- /dev/null +++ b/firmware/target/arm/sandisk/sansa-e200/ata.c | |||
@@ -0,0 +1,198 @@ | |||
1 | /*************************************************************************** | ||
2 | * __________ __ ___. | ||
3 | * Open \______ \ ____ ____ | | _\_ |__ _______ ___ | ||
4 | * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / | ||
5 | * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < < | ||
6 | * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ | ||
7 | * \/ \/ \/ \/ \/ | ||
8 | * $Id$ | ||
9 | * | ||
10 | * Copyright (C) 2006 Daniel Stenberg | ||
11 | * | ||
12 | * All files in this archive are subject to the GNU General Public License. | ||
13 | * See the file COPYING in the source tree root for full license agreement. | ||
14 | * | ||
15 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY | ||
16 | * KIND, either express or implied. | ||
17 | * | ||
18 | ****************************************************************************/ | ||
19 | |||
20 | #include "ata.h" | ||
21 | #include <stdbool.h> | ||
22 | #include <string.h> | ||
23 | |||
24 | #define SECTOR_SIZE (512) | ||
25 | |||
26 | static unsigned short identify_info[SECTOR_SIZE]; | ||
27 | int ata_spinup_time = 0; | ||
28 | long last_disk_activity = -1; | ||
29 | |||
30 | void flash_select_chip(int no, int sel) | ||
31 | { | ||
32 | |||
33 | } | ||
34 | |||
35 | unsigned char flash_read_data(void) | ||
36 | { | ||
37 | |||
38 | } | ||
39 | |||
40 | void flash_write_data(unsigned char data) | ||
41 | { | ||
42 | |||
43 | } | ||
44 | |||
45 | void flash_write_cmd(unsigned char cmd) | ||
46 | { | ||
47 | |||
48 | } | ||
49 | |||
50 | void flash_write_addr(unsigned char addr) | ||
51 | { | ||
52 | |||
53 | } | ||
54 | |||
55 | void flash_wait_ready(void) | ||
56 | { | ||
57 | |||
58 | } | ||
59 | |||
60 | int flash_map_sector(int sector, int* chip, int* chip_sector) | ||
61 | { | ||
62 | |||
63 | } | ||
64 | |||
65 | int flash_read_id(int no) | ||
66 | { | ||
67 | |||
68 | } | ||
69 | |||
70 | int flash_read_sector(int sector, unsigned char* buf, | ||
71 | unsigned char* oob) | ||
72 | { | ||
73 | |||
74 | } | ||
75 | |||
76 | int flash_read_sector_oob(int sector, unsigned char* oob) | ||
77 | { | ||
78 | |||
79 | } | ||
80 | |||
81 | static int flash_get_n_segments(void) | ||
82 | { | ||
83 | |||
84 | } | ||
85 | |||
86 | static int flash_get_n_phblocks(void) | ||
87 | { | ||
88 | |||
89 | } | ||
90 | |||
91 | static int flash_get_n_sectors_in_block(void) | ||
92 | { | ||
93 | |||
94 | } | ||
95 | |||
96 | static int flash_phblock_to_sector(int segment, int block) | ||
97 | { | ||
98 | |||
99 | } | ||
100 | |||
101 | static int flash_is_bad_block(unsigned char* oob) | ||
102 | { | ||
103 | |||
104 | } | ||
105 | |||
106 | int flash_disk_scan(void) | ||
107 | { | ||
108 | |||
109 | } | ||
110 | |||
111 | int flash_disk_find_block(int block) | ||
112 | { | ||
113 | |||
114 | } | ||
115 | |||
116 | int flash_disk_read_sectors(unsigned long start, | ||
117 | int count, | ||
118 | void* buf) | ||
119 | { | ||
120 | |||
121 | } | ||
122 | |||
123 | int ata_read_sectors(IF_MV2(int drive,) | ||
124 | unsigned long start, | ||
125 | int incount, | ||
126 | void* inbuf) | ||
127 | { | ||
128 | |||
129 | } | ||
130 | |||
131 | int ata_write_sectors(IF_MV2(int drive,) | ||
132 | unsigned long start, | ||
133 | int count, | ||
134 | const void* buf) | ||
135 | { | ||
136 | (void)start; | ||
137 | (void)count; | ||
138 | (void)buf; | ||
139 | return -1; | ||
140 | } | ||
141 | |||
142 | /* schedule a single sector write, executed with the the next spinup | ||
143 | (volume 0 only, used for config sector) */ | ||
144 | extern void ata_delayed_write(unsigned long sector, const void* buf) | ||
145 | { | ||
146 | (void)sector; | ||
147 | (void)buf; | ||
148 | } | ||
149 | |||
150 | /* write the delayed sector to volume 0 */ | ||
151 | extern void ata_flush(void) | ||
152 | { | ||
153 | |||
154 | } | ||
155 | |||
156 | void ata_spindown(int seconds) | ||
157 | { | ||
158 | (void)seconds; | ||
159 | } | ||
160 | |||
161 | bool ata_disk_is_active(void) | ||
162 | { | ||
163 | return 0; | ||
164 | } | ||
165 | |||
166 | void ata_sleep(void) | ||
167 | { | ||
168 | } | ||
169 | |||
170 | void ata_spin(void) | ||
171 | { | ||
172 | } | ||
173 | |||
174 | /* Hardware reset protocol as specified in chapter 9.1, ATA spec draft v5 */ | ||
175 | int ata_hard_reset(void) | ||
176 | { | ||
177 | return 0; | ||
178 | } | ||
179 | |||
180 | int ata_soft_reset(void) | ||
181 | { | ||
182 | return 0; | ||
183 | } | ||
184 | |||
185 | void ata_enable(bool on) | ||
186 | { | ||
187 | (void)on; | ||
188 | } | ||
189 | |||
190 | unsigned short* ata_get_identify(void) | ||
191 | { | ||
192 | |||
193 | } | ||
194 | |||
195 | int ata_init(void) | ||
196 | { | ||
197 | return 0; | ||
198 | } | ||
diff --git a/firmware/target/arm/sandisk/sansa-e200/backlight-target.h b/firmware/target/arm/sandisk/sansa-e200/backlight-target.h new file mode 100644 index 0000000000..67a01ed518 --- /dev/null +++ b/firmware/target/arm/sandisk/sansa-e200/backlight-target.h | |||
@@ -0,0 +1 @@ | |||
/* nothing here yet */ | |||
diff --git a/firmware/target/arm/sandisk/sansa-e200/button-target.h b/firmware/target/arm/sandisk/sansa-e200/button-target.h new file mode 100644 index 0000000000..e78f91a154 --- /dev/null +++ b/firmware/target/arm/sandisk/sansa-e200/button-target.h | |||
@@ -0,0 +1,7 @@ | |||
1 | |||
2 | #define BUTTON_POWER 0x00000001 | ||
3 | #define BUTTON_LEFT 0x00000002 | ||
4 | #define BUTTON_RIGHT 0x00000004 | ||
5 | |||
6 | #define POWEROFF_BUTTON BUTTON_POWER | ||
7 | #define POWEROFF_COUNT 40 | ||
diff --git a/firmware/target/arm/sandisk/sansa-e200/lcd.c b/firmware/target/arm/sandisk/sansa-e200/lcd.c new file mode 100644 index 0000000000..dedb196c70 --- /dev/null +++ b/firmware/target/arm/sandisk/sansa-e200/lcd.c | |||
@@ -0,0 +1,15 @@ | |||
1 | |||
2 | void lcd_update(void) | ||
3 | { | ||
4 | |||
5 | } | ||
6 | |||
7 | void lcd_update_rect(int x, int y, int width, int height) | ||
8 | { | ||
9 | |||
10 | } | ||
11 | |||
12 | void lcd_init_device(void) | ||
13 | { | ||
14 | |||
15 | } | ||
diff --git a/firmware/target/arm/sandisk/sansa-e200/usb-target.h b/firmware/target/arm/sandisk/sansa-e200/usb-target.h new file mode 100644 index 0000000000..67a01ed518 --- /dev/null +++ b/firmware/target/arm/sandisk/sansa-e200/usb-target.h | |||
@@ -0,0 +1 @@ | |||
/* nothing here yet */ | |||