diff options
author | Jens Arnold <amiconn@rockbox.org> | 2007-03-04 14:09:21 +0000 |
---|---|---|
committer | Jens Arnold <amiconn@rockbox.org> | 2007-03-04 14:09:21 +0000 |
commit | b4994a08ca8d8c86c1254a0b4f3de75564fdad1d (patch) | |
tree | fbc95b8302d75e581835a350d30d95db681b4cf6 | |
parent | 4de9fbeda6d38adb197399156f69d034837a9562 (diff) | |
download | rockbox-b4994a08ca8d8c86c1254a0b4f3de75564fdad1d.tar.gz rockbox-b4994a08ca8d8c86c1254a0b4f3de75564fdad1d.zip |
Added new iAudio M5 target, including some adjustments to make the bootloader compile (with a small change against the committed tools/tonfigure, and it won't actually work yet).
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12588 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r-- | bootloader/SOURCES | 2 | ||||
-rw-r--r-- | firmware/SOURCES | 27 | ||||
-rw-r--r-- | firmware/app.lds | 2 | ||||
-rw-r--r-- | firmware/boot.lds | 10 | ||||
-rw-r--r-- | firmware/export/config-iaudiom5.h | 160 | ||||
-rw-r--r-- | firmware/export/config.h | 2 | ||||
-rw-r--r-- | firmware/target/coldfire/pcf50606-coldfire.c | 2 | ||||
-rwxr-xr-x | tools/configure | 29 |
8 files changed, 224 insertions, 10 deletions
diff --git a/bootloader/SOURCES b/bootloader/SOURCES index 26356ff5ef..94196d387a 100644 --- a/bootloader/SOURCES +++ b/bootloader/SOURCES | |||
@@ -8,7 +8,7 @@ gigabeat.c | |||
8 | main-pp.c | 8 | main-pp.c |
9 | #elif defined(ELIO_TPJ1022) | 9 | #elif defined(ELIO_TPJ1022) |
10 | tpj1022.c | 10 | tpj1022.c |
11 | #elif defined(IAUDIO_X5) | 11 | #elif defined(IAUDIO_X5) || defined(IAUDIO_M5) |
12 | iaudio_x5.c | 12 | iaudio_x5.c |
13 | #elif defined(IRIVER_H300_SERIES) | 13 | #elif defined(IRIVER_H300_SERIES) |
14 | iriver_h300.c | 14 | iriver_h300.c |
diff --git a/firmware/SOURCES b/firmware/SOURCES index c1a21171d0..ec47fff3d1 100644 --- a/firmware/SOURCES +++ b/firmware/SOURCES | |||
@@ -244,9 +244,10 @@ target/coldfire/crt0.S | |||
244 | target/coldfire/memcpy-coldfire.S | 244 | target/coldfire/memcpy-coldfire.S |
245 | target/coldfire/memmove-coldfire.S | 245 | target/coldfire/memmove-coldfire.S |
246 | target/coldfire/memset-coldfire.S | 246 | target/coldfire/memset-coldfire.S |
247 | #ifdef HAVE_LCD_COLOR | 247 | #if defined(HAVE_LCD_COLOR) \ |
248 | || defined(HAVE_REMOTE_LCD) && (LCD_REMOTE_PIXELFORMAT == VERTICAL_INTERLEAVED) | ||
248 | target/coldfire/memset16-coldfire.S | 249 | target/coldfire/memset16-coldfire.S |
249 | #endif /* HAVE_LCD_COLOR */ | 250 | #endif |
250 | target/coldfire/system-coldfire.c | 251 | target/coldfire/system-coldfire.c |
251 | #ifndef BOOTLOADER | 252 | #ifndef BOOTLOADER |
252 | target/coldfire/pcm-coldfire.c | 253 | target/coldfire/pcm-coldfire.c |
@@ -370,6 +371,28 @@ target/coldfire/iaudio/x5/audio-x5.c | |||
370 | #endif /* SIMULATOR */ | 371 | #endif /* SIMULATOR */ |
371 | #endif /* IAUDIO_X5 */ | 372 | #endif /* IAUDIO_X5 */ |
372 | 373 | ||
374 | #ifdef IAUDIO_M5 | ||
375 | target/coldfire/iaudio/x5/power-x5.c | ||
376 | #ifndef SIMULATOR | ||
377 | target/coldfire/ata-as-coldfire.S | ||
378 | target/coldfire/pcf50606-coldfire.c | ||
379 | target/coldfire/iaudio/x5/adc-x5.c | ||
380 | target/coldfire/iaudio/x5/ata-x5.c | ||
381 | target/coldfire/iaudio/x5/backlight-x5.c | ||
382 | target/coldfire/iaudio/x5/button-x5.c | ||
383 | target/coldfire/iaudio/x5/lcd-as-x5.S | ||
384 | target/coldfire/iaudio/x5/lcd-remote-x5.c | ||
385 | target/coldfire/iaudio/x5/lcd-x5.c | ||
386 | target/coldfire/iaudio/x5/m5636-x5.c | ||
387 | target/coldfire/iaudio/x5/pcf50606-x5.c | ||
388 | target/coldfire/iaudio/x5/system-x5.c | ||
389 | target/coldfire/iaudio/x5/usb-x5.c | ||
390 | #ifndef BOOTLOADER | ||
391 | target/coldfire/iaudio/x5/audio-x5.c | ||
392 | #endif | ||
393 | #endif /* SIMULATOR */ | ||
394 | #endif /* IAUDIO_M5 */ | ||
395 | |||
373 | #ifdef IRIVER_IFP7XX_SERIES | 396 | #ifdef IRIVER_IFP7XX_SERIES |
374 | #ifdef STUB | 397 | #ifdef STUB |
375 | usb_serial.c | 398 | usb_serial.c |
diff --git a/firmware/app.lds b/firmware/app.lds index 02c204a2a8..eb63fd8195 100644 --- a/firmware/app.lds +++ b/firmware/app.lds | |||
@@ -33,7 +33,7 @@ INPUT(target/sh/crt0.o) | |||
33 | #define DRAMORIG 0x31000000 + STUBOFFSET | 33 | #define DRAMORIG 0x31000000 + STUBOFFSET |
34 | #define IRAMORIG 0x10000000 | 34 | #define IRAMORIG 0x10000000 |
35 | #define IRAMSIZE 0xc000 | 35 | #define IRAMSIZE 0xc000 |
36 | #elif defined(IAUDIO_X5) | 36 | #elif defined(IAUDIO_X5) || defined(IAUDIO_M5) |
37 | #define DRAMORIG 0x31000000 + STUBOFFSET | 37 | #define DRAMORIG 0x31000000 + STUBOFFSET |
38 | #define IRAMORIG 0x10000000 | 38 | #define IRAMORIG 0x10000000 |
39 | #define IRAMSIZE 0x10000 | 39 | #define IRAMSIZE 0x10000 |
diff --git a/firmware/boot.lds b/firmware/boot.lds index c9e39be554..b032f8e64a 100644 --- a/firmware/boot.lds +++ b/firmware/boot.lds | |||
@@ -31,7 +31,7 @@ INPUT(target/sh/crt0.o) | |||
31 | #define IRAMSIZE 0x18000 | 31 | #define IRAMSIZE 0x18000 |
32 | #define FLASHORIG 0x003f0000 | 32 | #define FLASHORIG 0x003f0000 |
33 | #define FLASHSIZE 4M | 33 | #define FLASHSIZE 4M |
34 | #elif defined(IAUDIO_X5) | 34 | #elif defined(IAUDIO_X5) || defined(IAUDIO_M5) |
35 | #define DRAMORIG 0x31000000 | 35 | #define DRAMORIG 0x31000000 |
36 | #define IRAMORIG 0x10000000 | 36 | #define IRAMORIG 0x10000000 |
37 | #define IRAMSIZE 0x20000 | 37 | #define IRAMSIZE 0x20000 |
@@ -151,7 +151,7 @@ SECTIONS | |||
151 | { | 151 | { |
152 | .vectors : | 152 | .vectors : |
153 | { | 153 | { |
154 | #ifdef IAUDIO_X5 | 154 | #if defined(IAUDIO_X5) || defined(IAUDIO_M5) |
155 | *(.init.text) | 155 | *(.init.text) |
156 | #endif | 156 | #endif |
157 | _datacopy = .; | 157 | _datacopy = .; |
@@ -201,7 +201,8 @@ SECTIONS | |||
201 | stackend = .; | 201 | stackend = .; |
202 | } > IRAM | 202 | } > IRAM |
203 | 203 | ||
204 | #if defined(IRIVER_H100_SERIES) || defined(IRIVER_H300_SERIES) || defined(IAUDIO_X5) | 204 | #if defined(IRIVER_H100_SERIES) || defined(IRIVER_H300_SERIES) \ |
205 | || defined(IAUDIO_X5) || defined(IAUDIO_M5) | ||
205 | .bss DRAMORIG+0x800000: | 206 | .bss DRAMORIG+0x800000: |
206 | #else | 207 | #else |
207 | .bss : | 208 | .bss : |
@@ -212,7 +213,8 @@ SECTIONS | |||
212 | *(.bss*) | 213 | *(.bss*) |
213 | *(COMMON) | 214 | *(COMMON) |
214 | _end = .; | 215 | _end = .; |
215 | #if defined(IRIVER_H100_SERIES) || defined(IRIVER_H300_SERIES) || defined(IAUDIO_X5) | 216 | #if defined(IRIVER_H100_SERIES) || defined(IRIVER_H300_SERIES) \ |
217 | || defined(IAUDIO_X5) || defined(IAUDIO_M5) | ||
216 | } > DRAM | 218 | } > DRAM |
217 | #else | 219 | #else |
218 | } > IRAM | 220 | } > IRAM |
diff --git a/firmware/export/config-iaudiom5.h b/firmware/export/config-iaudiom5.h new file mode 100644 index 0000000000..2c52bc0730 --- /dev/null +++ b/firmware/export/config-iaudiom5.h | |||
@@ -0,0 +1,160 @@ | |||
1 | /* | ||
2 | * This config file is for iAudio M5 | ||
3 | */ | ||
4 | #define TARGET_TREE /* this target is using the target tree system */ | ||
5 | |||
6 | /* For Rolo and boot loader */ | ||
7 | #define MODEL_NUMBER 17 | ||
8 | |||
9 | /* define this if you have recording possibility */ | ||
10 | #define HAVE_RECORDING | ||
11 | |||
12 | /* define the bitmask of hardware sample rates */ | ||
13 | #define HW_SAMPR_CAPS (SAMPR_CAP_88 | SAMPR_CAP_44 | SAMPR_CAP_22 | SAMPR_CAP_11) | ||
14 | |||
15 | /* define the bitmask of recording sample rates */ | ||
16 | #define REC_SAMPR_CAPS (SAMPR_CAP_88 | SAMPR_CAP_44 | SAMPR_CAP_22 | SAMPR_CAP_11) | ||
17 | |||
18 | /* define this if you have a bitmap LCD display */ | ||
19 | #define HAVE_LCD_BITMAP | ||
20 | |||
21 | /* define this if you can flip your LCD */ | ||
22 | #define HAVE_LCD_FLIP | ||
23 | |||
24 | /* define this if you can invert the colours on your LCD */ | ||
25 | #define HAVE_LCD_INVERT | ||
26 | |||
27 | /* define this if you have access to the quickscreen */ | ||
28 | #define HAVE_QUICKSCREEN | ||
29 | |||
30 | /* define this if you have access to the pitchscreen */ | ||
31 | #define HAVE_PITCHSCREEN | ||
32 | |||
33 | /* define this if you would like tagcache to build on this target */ | ||
34 | #define HAVE_TAGCACHE | ||
35 | |||
36 | /* LCD dimensions */ | ||
37 | #define LCD_WIDTH 160 | ||
38 | #define LCD_HEIGHT 128 | ||
39 | #define LCD_DEPTH 2 | ||
40 | |||
41 | #define LCD_PIXELFORMAT VERTICAL_PACKING | ||
42 | |||
43 | /* remote LCD */ | ||
44 | #define LCD_REMOTE_WIDTH 128 | ||
45 | #define LCD_REMOTE_HEIGHT 96 | ||
46 | #define LCD_REMOTE_DEPTH 2 | ||
47 | |||
48 | #define LCD_REMOTE_PIXELFORMAT VERTICAL_INTERLEAVED | ||
49 | |||
50 | #define CONFIG_KEYPAD IAUDIO_X5_PAD | ||
51 | |||
52 | #define AB_REPEAT_ENABLE 1 | ||
53 | #define ACTION_WPSAB_SINGLE ACTION_WPS_BROWSE | ||
54 | |||
55 | /* Define this if you do software codec */ | ||
56 | #define CONFIG_CODEC SWCODEC | ||
57 | |||
58 | /* define this if you have a real-time clock */ | ||
59 | #define CONFIG_RTC RTC_PCF50606 | ||
60 | |||
61 | /* Define this if you have an remote lcd */ | ||
62 | #define HAVE_REMOTE_LCD | ||
63 | |||
64 | #define CONFIG_LCD LCD_S1D15E06 | ||
65 | |||
66 | /* Define this for LCD backlight available */ | ||
67 | #define CONFIG_BACKLIGHT BL_X5 /* PCF50606 I2C */ | ||
68 | /* #define HAVE_BACKLIGHT_BRIGHTNESS TODO: not yet known */ | ||
69 | |||
70 | /* Define this if you have a software controlled poweroff */ | ||
71 | #define HAVE_SW_POWEROFF | ||
72 | |||
73 | /* The number of bytes reserved for loadable codecs */ | ||
74 | #define CODEC_SIZE 0x80000 | ||
75 | |||
76 | /* The number of bytes reserved for loadable plugins */ | ||
77 | #define PLUGIN_BUFFER_SIZE 0x80000 | ||
78 | |||
79 | #define BATTERY_CAPACITY_DEFAULT 950 /* default battery capacity */ | ||
80 | |||
81 | #define HAVE_TLV320 | ||
82 | |||
83 | /* TLV320 has no tone controls, so we use the software ones */ | ||
84 | #define HAVE_SW_TONE_CONTROLS | ||
85 | |||
86 | #ifndef SIMULATOR | ||
87 | |||
88 | /* Define this if your LCD can set contrast */ | ||
89 | #define HAVE_LCD_CONTRAST | ||
90 | |||
91 | /* Define this if you have a Motorola SCF5250 */ | ||
92 | #define CONFIG_CPU MCF5250 | ||
93 | |||
94 | /* Define this if you want to use coldfire's i2c interface */ | ||
95 | #define CONFIG_I2C I2C_COLDFIRE | ||
96 | |||
97 | /* Hardware controlled charging? FIXME */ | ||
98 | #define CONFIG_CHARGING CHARGING_SIMPLE | ||
99 | |||
100 | /* define this if the hardware can be powered off while charging */ | ||
101 | #define HAVE_POWEROFF_WHILE_CHARGING | ||
102 | |||
103 | /* The size of the flash ROM */ | ||
104 | #define FLASH_SIZE 0x400000 | ||
105 | |||
106 | /* Define this to the CPU frequency */ | ||
107 | #define CPU_FREQ 11289600 | ||
108 | |||
109 | /* Type of mobile power */ | ||
110 | #define X5_BATT_CONFIG 2 | ||
111 | #define CONFIG_BATTERY BATT_IAUDIO_X5 | ||
112 | #define BATTERY_CAPACITY_MIN 950 /* min. capacity selectable */ | ||
113 | #define BATTERY_CAPACITY_MAX 2250 /* max. capacity selectable */ | ||
114 | #define BATTERY_CAPACITY_INC 50 /* capacity increment */ | ||
115 | #define BATTERY_TYPES_COUNT 1 /* only one type */ | ||
116 | #define BATTERY_SCALE_FACTOR 5859 /* (420703125 + 35900) / 71800 */ | ||
117 | |||
118 | /* Define this if you have ATA power-off control */ | ||
119 | #define HAVE_ATA_POWER_OFF | ||
120 | |||
121 | /* Virtual LED (icon) */ | ||
122 | #define CONFIG_LED LED_VIRTUAL | ||
123 | |||
124 | /* Offset ( in the firmware file's header ) to the file CRC */ | ||
125 | #define FIRMWARE_OFFSET_FILE_CRC 0 | ||
126 | |||
127 | /* Offset ( in the firmware file's header ) to the real data */ | ||
128 | #define FIRMWARE_OFFSET_FILE_DATA 8 | ||
129 | |||
130 | #define USB_X5STYLE | ||
131 | |||
132 | /* Define this if you have adjustable CPU frequency */ | ||
133 | #define HAVE_ADJUSTABLE_CPU_FREQ | ||
134 | |||
135 | #define BOOTFILE_EXT "iaudio" | ||
136 | #define BOOTFILE "rockbox." BOOTFILE_EXT | ||
137 | |||
138 | #define BOOTLOADER_ENTRYPOINT 0x001F0000 | ||
139 | #define FLASH_ENTRYPOINT 0x00001000 | ||
140 | #define FLASH_MAGIC 0xfbfbfbf1 | ||
141 | |||
142 | #endif /* SIMULATOR */ | ||
143 | |||
144 | /** Port-specific settings **/ | ||
145 | |||
146 | /* Main LCD contrast range and defaults */ | ||
147 | #define MIN_CONTRAST_SETTING 1 | ||
148 | #define MAX_CONTRAST_SETTING 30 | ||
149 | #define DEFAULT_CONTRAST_SETTING 19 /* Match boot contrast */ | ||
150 | |||
151 | /* Main LCD backlight brightness range and defaults */ | ||
152 | /* PCF50506 can output 0%-100% duty cycle but D305A expects %15-100%. */ | ||
153 | #define MIN_BRIGHTNESS_SETTING 1 /* 15/16 (93.75%) */ | ||
154 | #define MAX_BRIGHTNESS_SETTING 13 /* 3/16 (18.75%) */ | ||
155 | #define DEFAULT_BRIGHTNESS_SETTING 8 /* 8/16 (50.00%) = x5 boot default */ | ||
156 | |||
157 | /* Remote LCD contrast range and defaults */ | ||
158 | #define MIN_REMOTE_CONTRAST_SETTING 10 | ||
159 | #define MAX_REMOTE_CONTRAST_SETTING 35 | ||
160 | #define DEFAULT_REMOTE_CONTRAST_SETTING 24 /* Match boot contrast */ | ||
diff --git a/firmware/export/config.h b/firmware/export/config.h index 085f86af53..d848d16155 100644 --- a/firmware/export/config.h +++ b/firmware/export/config.h | |||
@@ -187,6 +187,8 @@ | |||
187 | #include "config-h300.h" | 187 | #include "config-h300.h" |
188 | #elif defined(IAUDIO_X5) | 188 | #elif defined(IAUDIO_X5) |
189 | #include "config-iaudiox5.h" | 189 | #include "config-iaudiox5.h" |
190 | #elif defined(IAUDIO_M5) | ||
191 | #include "config-iaudiom5.h" | ||
190 | #elif defined(IPOD_COLOR) | 192 | #elif defined(IPOD_COLOR) |
191 | #include "config-ipodcolor.h" | 193 | #include "config-ipodcolor.h" |
192 | #elif defined(IPOD_NANO) | 194 | #elif defined(IPOD_NANO) |
diff --git a/firmware/target/coldfire/pcf50606-coldfire.c b/firmware/target/coldfire/pcf50606-coldfire.c index ecc9e0ee72..d777b41cb1 100644 --- a/firmware/target/coldfire/pcf50606-coldfire.c +++ b/firmware/target/coldfire/pcf50606-coldfire.c | |||
@@ -29,7 +29,7 @@ | |||
29 | #if defined(IRIVER_H300_SERIES) | 29 | #if defined(IRIVER_H300_SERIES) |
30 | #define SDA_BITNUM 13 /* LRCK3/GPIO45 */ | 30 | #define SDA_BITNUM 13 /* LRCK3/GPIO45 */ |
31 | #define SCL_BITNUM 12 /* SWE/GPIO12 */ | 31 | #define SCL_BITNUM 12 /* SWE/GPIO12 */ |
32 | #elif defined(IAUDIO_X5) | 32 | #elif defined(IAUDIO_X5) || defined(IAUDIO_M5) |
33 | #define SDA_BITNUM 12 /* SDA1/RXD1/GPIO44 */ | 33 | #define SDA_BITNUM 12 /* SDA1/RXD1/GPIO44 */ |
34 | #define SCL_BITNUM 10 /* SCL1/TXD1/GPIO10 */ | 34 | #define SCL_BITNUM 10 /* SCL1/TXD1/GPIO10 */ |
35 | #endif | 35 | #endif |
diff --git a/tools/configure b/tools/configure index 22261888a5..ee5dbaa62a 100755 --- a/tools/configure +++ b/tools/configure | |||
@@ -589,7 +589,8 @@ cat <<EOF | |||
589 | 589 | ||
590 | ==iAudio== ==Toshiba== ==SanDisk== | 590 | ==iAudio== ==Toshiba== ==SanDisk== |
591 | 30) X5/X5V/X5L 40) Gigabeat F 50) Sansa e200 | 591 | 30) X5/X5V/X5L 40) Gigabeat F 50) Sansa e200 |
592 | 51) Sansa e200R | 592 | 31) M5/M5L 51) Sansa e200R |
593 | |||
593 | ==Tatung== | 594 | ==Tatung== |
594 | 60) Elio TPJ-1022 | 595 | 60) Elio TPJ-1022 |
595 | EOF | 596 | EOF |
@@ -909,6 +910,32 @@ EOF | |||
909 | t_model="x5" | 910 | t_model="x5" |
910 | ;; | 911 | ;; |
911 | 912 | ||
913 | 31|m5) | ||
914 | target_id=28 | ||
915 | archos="m5" | ||
916 | target="-DIAUDIO_M5" | ||
917 | memory=16 # always | ||
918 | coldfirecc | ||
919 | tool="$rootdir/tools/scramble -add=iam5" | ||
920 | bmp2rb_mono="$rootdir/tools/bmp2rb -f 0" | ||
921 | bmp2rb_native="$rootdir/tools/bmp2rb -f 2" | ||
922 | bmp2rb_remotemono="$rootdir/tools/bmp2rb -f 0" | ||
923 | bmp2rb_remotenative="$rootdir/tools/bmp2rb -f 7" | ||
924 | output="rockbox.iaudio" | ||
925 | appextra="recorder:gui" | ||
926 | archosrom="" | ||
927 | flash="" | ||
928 | plugins="yes" | ||
929 | codecs="libmad liba52 libffmpegFLAC libTremor libwavpack libmusepack libalac libfaad libm4a libspeex" | ||
930 | # toolset is the tools within the tools directory that we build for | ||
931 | # this particular target. | ||
932 | toolset="$iaudiobitmaptools" | ||
933 | # architecture, manufacturer and model for the target-tree build | ||
934 | t_cpu="coldfire" | ||
935 | t_manufacturer="iaudio" | ||
936 | t_model="m5" | ||
937 | ;; | ||
938 | |||
912 | 20|ipodcolor) | 939 | 20|ipodcolor) |
913 | target_id=13 | 940 | target_id=13 |
914 | archos="ipodcolor" | 941 | archos="ipodcolor" |