as3525*: enable USB stack in bootloader (but not USE_ROCKBOX_USB yet)
[kugel-rb.git] / firmware / export / config / sansaclipv2.h
blobeb6fb6c737d0d02d20b8d9a691cf402e4990bccb
1 /*
2 * This config file is for the Sandisk Sansa Clip v2
3 */
4 #define TARGET_TREE /* this target is using the target tree system */
6 /* For Rolo and boot loader */
7 #define MODEL_NUMBER 60
8 #define MODEL_NAME "Sandisk Sansa Clipv2"
9 #define FIRMWARE_OFFSET_FILE_DATA 8
10 #define FIRMWARE_OFFSET_FILE_CRC 0
12 #define HW_SAMPR_CAPS SAMPR_CAP_ALL
14 /* define this if you have recording possibility */
15 #define HAVE_RECORDING
17 #define REC_SAMPR_CAPS SAMPR_CAP_ALL
19 /* Define bitmask of input sources - recordable bitmask can be defined
20 explicitly if different */
21 #define INPUT_SRC_CAPS (SRC_CAP_MIC | SRC_CAP_FMRADIO)
23 /* define this if you have a bitmap LCD display */
24 #define HAVE_LCD_BITMAP
26 /* define this if you have a light associated with the buttons */
27 #define HAVE_BUTTON_LIGHT
29 /* define this if you have access to the quickscreen */
30 #define HAVE_QUICKSCREEN
32 /* define this if you have access to the pitchscreen */
33 #define HAVE_PITCHSCREEN
35 /* define this if you would like tagcache to build on this target */
36 #define HAVE_TAGCACHE
38 /* LCD dimensions */
39 #define LCD_WIDTH 128
40 #define LCD_HEIGHT 64
41 #define LCD_DEPTH 1
43 #define LCD_PIXELFORMAT VERTICAL_PACKING
44 #define HAVE_NEGATIVE_LCD /* bright on dark */
45 #define HAVE_LCD_SPLIT /* split display */
47 /* Display colours, for screenshots and sim (0xRRGGBB) */
48 #define LCD_DARKCOLOR 0x000000
49 #define LCD_BRIGHTCOLOR 0x000000
50 #define LCD_BL_DARKCOLOR 0x000000
51 #define LCD_BL_BRIGHTCOLOR 0x0de2e5
53 #define LCD_DARKCOLOR_2 0x000000
54 #define LCD_BRIGHTCOLOR_2 0x000000
55 #define LCD_BL_DARKCOLOR_2 0x000000
56 #define LCD_BL_BRIGHTCOLOR_2 0xffe60f
58 #define LCD_SPLIT_POS 16
59 #define LCD_SPLIT_LINES 2
61 /* define this if you have LCD enable function */
62 #define HAVE_LCD_ENABLE
64 #ifndef BOOTLOADER
65 /* Define this if your LCD can be put to sleep.
66 * HAVE_LCD_ENABLE should be defined as well. */
67 //#define HAVE_LCD_SLEEP
68 //#define HAVE_LCD_SLEEP_SETTING
69 #endif
71 /* define this if you can flip your LCD */
72 #define HAVE_LCD_FLIP
74 /* define this if you can invert the pixels */
75 #define HAVE_LCD_INVERT
77 /* Define this if your LCD can set contrast */
78 #define HAVE_LCD_CONTRAST
80 #define MIN_CONTRAST_SETTING 0
81 #define MAX_CONTRAST_SETTING 50
82 #define DEFAULT_CONTRAST_SETTING 30
84 #define IRAM_LCDFRAMEBUFFER IDATA_ATTR /* put the lcd frame buffer in IRAM */
86 #define CONFIG_KEYPAD SANSA_CLIP_PAD
88 /* define this if the target has volume keys which can be used in the lists */
89 #define HAVE_VOLUME_IN_LIST
91 /* Define this if you do software codec */
92 #define CONFIG_CODEC SWCODEC
93 /* There is no hardware tone control */
94 #define HAVE_SW_TONE_CONTROLS
96 /* AS3514 or newer */
97 #define HAVE_AS3514
98 #define HAVE_AS3543
100 #ifndef BOOTLOADER
101 /* define this if you have a real-time clock */
102 #define CONFIG_RTC RTC_AS3514
104 /* Define if the device can wake from an RTC alarm */
105 #define HAVE_RTC_ALARM
106 #endif
108 /* Define this if you have a software controlled poweroff */
109 #define HAVE_SW_POWEROFF
111 #define HAVE_FAT16SUPPORT
113 /* The number of bytes reserved for loadable codecs */
114 #define CODEC_SIZE (0x100000-0x8000)
116 /* The number of bytes reserved for loadable plugins */
117 #define PLUGIN_BUFFER_SIZE 0x80000
119 #define AB_REPEAT_ENABLE 1
121 /* FM Tuner */
122 #define CONFIG_TUNER SI4700 /* in fact SI4702 */
123 //#define HAVE_TUNER_PWR_CTRL
125 /* Define this for LCD backlight available */
126 #define HAVE_BACKLIGHT
128 /* define this if you have a flash memory storage */
129 #define HAVE_FLASH_STORAGE
131 /* define this if the flash memory uses the SecureDigital Memory Card protocol */
132 #define CONFIG_STORAGE STORAGE_SD
134 #define BATTERY_CAPACITY_DEFAULT 380 /* default battery capacity */
135 #define BATTERY_CAPACITY_MIN 380 /* min. capacity selectable */
136 #define BATTERY_CAPACITY_MAX 380 /* max. capacity selectable */
137 #define BATTERY_CAPACITY_INC 0 /* capacity increment */
138 #define BATTERY_TYPES_COUNT 1 /* only one type */
140 /* Charging implemented in a target-specific algorithm */
141 #define CONFIG_CHARGING CHARGING_TARGET
143 /* define this if the unit can be powered or charged via USB */
144 #define HAVE_USB_POWER
146 /** Non-simulator section **/
147 #ifndef SIMULATOR
149 /* Define this if you have a AMS AS3525v2 SoC */
150 #define CONFIG_CPU AS3525v2
152 /* Define this if you want to use the AS3525 i2c interface */
153 #define CONFIG_I2C I2C_AS3525
155 /* define this if the hardware can be powered off while charging */
156 /* Sansa can't be powered off while charging */
157 /* #define HAVE_POWEROFF_WHILE_CHARGING */
159 /* define current usage levels (based on battery bench) */
160 #define CURRENT_NORMAL 24
161 #define CURRENT_BACKLIGHT 15
162 #define CURRENT_RECORD 11
164 /* Define this to the CPU frequency */
165 #define CPU_FREQ 240000000
167 /* Type of LCD */
168 #define CONFIG_LCD LCD_SSD1303
170 /* USB On-the-go */
171 #define CONFIG_USBOTG USBOTG_AS3525v2
173 /* enable these for the experimental usb stack */
174 #define HAVE_USBSTACK
175 #define USB_HANDLED_BY_OF
176 //#define USE_ROCKBOX_USB
177 #define USB_VENDOR_ID 0x0781
178 #define USB_PRODUCT_ID 0x7435
180 /* Virtual LED (icon) */
181 #define CONFIG_LED LED_VIRTUAL
183 /* Define this if you have adjustable CPU frequency */
184 //#define HAVE_ADJUSTABLE_CPU_FREQ
186 #define BOOTFILE_EXT "sansa"
187 #define BOOTFILE "rockbox." BOOTFILE_EXT
188 #define BOOTDIR "/.rockbox"
190 #define ICODE_ATTR_TREMOR_NOT_MDCT
192 #define INCLUDE_TIMEOUT_API
194 #endif /* SIMULATOR */
196 /** Port-specific settings **/
198 /* Main LCD backlight brightness range and defaults */
199 #define MIN_BRIGHTNESS_SETTING 1
200 #define MAX_BRIGHTNESS_SETTING 12
201 #define DEFAULT_BRIGHTNESS_SETTING 6
203 /* Default recording levels */
204 #define DEFAULT_REC_MIC_GAIN 23
205 #define DEFAULT_REC_LEFT_GAIN 23
206 #define DEFAULT_REC_RIGHT_GAIN 23
208 /* Define this if a programmable hotkey is mapped */
209 //#define HAVE_HOTKEY