summaryrefslogtreecommitdiff
path: root/firmware/export
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/export')
-rw-r--r--firmware/export/ak4537.h193
-rw-r--r--firmware/export/akcodec.h29
-rw-r--r--firmware/export/audiohw.h2
-rw-r--r--firmware/export/config-yh820.h187
-rw-r--r--firmware/export/config-yh920.h193
-rw-r--r--firmware/export/config-yh925.h190
-rw-r--r--firmware/export/config.h10
-rw-r--r--firmware/export/usb.h3
8 files changed, 806 insertions, 1 deletions
diff --git a/firmware/export/ak4537.h b/firmware/export/ak4537.h
new file mode 100644
index 0000000000..1f272d41fc
--- /dev/null
+++ b/firmware/export/ak4537.h
@@ -0,0 +1,193 @@
1/***************************************************************************
2 * __________ __ ___.
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
7 * \/ \/ \/ \/ \/
8 * $Id$
9 *
10 * Copyright (C) 2009 by Mark Arigo
11 *
12 * This program is free software; you can redistribute it and/or
13 * modify it under the terms of the GNU General Public License
14 * as published by the Free Software Foundation; either version 2
15 * of the License, or (at your option) any later version.
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#ifndef _AK4537_H
23#define _AK4537_H
24
25/* Volume goes from -127.0 ... 0 dB in 0.5 dB increments */
26#define VOLUME_MIN -1270
27#define VOLUME_MAX 0
28
29extern int tenthdb2master(int db);
30
31extern void audiohw_set_master_vol(int vol_l, int vol_r);
32
33#define AKC_NUM_REGS 0x11
34
35/* Common register bits */
36
37/* Power Management 1 */
38#define AK4537_PM1 0x00
39#define PMADL (1 << 0)
40#define PMMICL (1 << 1)
41#define PMIPGL (1 << 2)
42#define PMMO (1 << 3)
43#define PMLO (1 << 4)
44#define PMBPM (1 << 5)
45#define PMBPS (1 << 6)
46#define PMVCM (1 << 7)
47
48/* Power Management 2 */
49#define AK4537_PM2 0x01
50#define PMDAC (1 << 0)
51#define PMHPR (1 << 1)
52#define PMHPL (1 << 2)
53#define PMSPK (1 << 3)
54#define SPKG (1 << 4)
55#define PMPLL (1 << 5)
56#define PMXTL (1 << 6)
57#define MCLKPD (1 << 7)
58
59/* Signal Select 1 */
60#define AK4537_SIGSEL1 0x02
61#define MOUT2 (1 << 0)
62#define ALCS (1 << 1)
63#define BPMSP (1 << 2)
64#define BPSSP (1 << 3)
65#define MICM (1 << 4)
66#define DAMO (1 << 5)
67#define PSMO (1 << 6)
68#define MOGN (1 << 7)
69
70/* Signal Select 2 */
71#define AK4537_SIGSEL2 0x03
72#define HPR (1 << 0)
73#define HPL (1 << 1)
74#define BPMHP (1 << 2)
75#define BPSHP (1 << 3)
76#define MICL (1 << 4)
77#define PSLO (1 << 6)
78#define DAHS (1 << 7)
79
80/* Mode Control 1 */
81#define AK4537_MODE1 0x04
82#define DIF_MASK (3 << 0)
83#define BICK_MASK (1 << 2)
84#define MCKO_EN (1 << 3)
85#define MCKO_MASK (3 << 4)
86#define MCKI_MASK (3 << 6)
87
88/* Mode Control 2 */
89#define AK4537_MODE2 0x05
90#define SPPS (1 << 0)
91#define LOOP (1 << 1)
92#define HPM (1 << 2)
93#define FS_MASK (7 << 5)
94
95/* DAC Control */
96#define AK4537_DAC 0x06
97#define DEM_MASK (3 << 0)
98#define BST_MASK (3 << 2)
99#define DATTC (1 << 4)
100#define SMUTE (1 << 5)
101#define TM_MASK (3 << 6)
102
103/* MIC Control */
104#define AK4537_MIC 0x07
105#define MGAIN (1 << 0)
106#define MSEL (1 << 1)
107#define MICAD (1 << 2)
108#define MPWRI (1 << 3)
109#define MPWRE (1 << 4)
110#define IPGAC (1 << 5)
111
112/* Timer Select */
113#define AK4537_TIMER 0x08
114#define LTM_MASK (3 << 0)
115#define WTM_MASK (3 << 2)
116#define ZTM_MASK (3 << 4)
117#define ZTM1 (1 << 5)
118#define ROTM (1 << 6)
119
120/* ALC Mode Control 1 */
121#define AK4537_ALC1 0x09
122#define LMTH (1 << 0)
123#define RATT (1 << 1)
124#define LMAT_MASK (3 << 2)
125#define ZELM (1 << 4)
126#define ALC1 (1 << 5)
127#define ALC2 (1 << 6)
128
129/* ALC Mode Control 2 */
130#define AK4537_ALC2 0x0a
131
132/* Lch Input PGA Control */
133#define AK4537_IPGAL 0x0b
134
135/* Lch Digital ATT Control */
136#define AK4537_ATTL 0x0c
137
138/* Rch Digital ATT Control */
139#define AK4537_ATTR 0x0d
140
141/* Volume Control */
142#define AK4537_VOLUME 0x0e
143#define ATTS_MASK (7 << 4)
144#define ATTRM (1 << 7)
145
146/* Rch Input PGA Control */
147#define AK4537_IPGAR 0x0f
148
149/* Power Management 3 */
150#define AK4537_PM3 0x10
151#define PMADR (1 << 0)
152#define PMMICR (1 << 1)
153#define PMIPGR (1 << 2)
154#define INR (1 << 3)
155#define INL (1 << 4)
156
157/* Sampling frequency (PLL mode) */
158#define AKC_PLL_8000HZ (7 << 5)
159#define AKC_PLL_11025HZ (2 << 5)
160#define AKC_PLL_16000HZ (6 << 5)
161#define AKC_PLL_22050HZ (1 << 5)
162#define AKC_PLL_24000HZ (5 << 5)
163#define AKC_PLL_32000HZ (4 << 5)
164#define AKC_PLL_44100HZ (0 << 5)
165#define AKC_PLL_48000HZ (3 << 5)
166
167/* MCKI input frequency (PLL mode) */
168#define MCKI_PLL_12288KHZ (0 << 6)
169#define MCKI_PLL_11289KHZ (1 << 6)
170#define MCKI_PLL_12000KHZ (2 << 6)
171
172/* MCKO frequency (PLL mode, MCKO bit = 1) */
173#define MCKO_PLL_256FS (0 << 4)
174#define MCKO_PLL_128FS (1 << 4)
175#define MCKO_PLL_64FS (2 << 4)
176#define MCKO_PLL_32FS (3 << 4)
177
178/* BICK frequency */
179#define BICK_64FS (0 << 2)
180#define BICK_32FS (1 << 2)
181
182/* Audio interface format */
183#define DIF_MSB_LSB (0 << 0)
184#define DIF_MSB_MSB (1 << 0)
185#define DIF_I2S (2 << 0)
186
187/* Low frequency boost control */
188#define BST_OFF (0 << 2)
189#define BST_MIN (1 << 2)
190#define BST_MID (2 << 2)
191#define BST_MAX (3 << 2)
192
193#endif /* _AK4537_H */
diff --git a/firmware/export/akcodec.h b/firmware/export/akcodec.h
new file mode 100644
index 0000000000..7cb2bad7e5
--- /dev/null
+++ b/firmware/export/akcodec.h
@@ -0,0 +1,29 @@
1/***************************************************************************
2 * __________ __ ___.
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
7 * \/ \/ \/ \/ \/
8 * $Id$
9 *
10 * Copyright (C) 2006 by Marcoen Hirschberg
11 *
12 * This program is free software; you can redistribute it and/or
13 * modify it under the terms of the GNU General Public License
14 * as published by the Free Software Foundation; either version 2
15 * of the License, or (at your option) any later version.
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#ifndef _AKCODEC_H
23#define _AKCODEC_H
24
25int akcodec_read(int reg);
26void akcodec_write(int reg, int data);
27void akcodec_close(void);
28
29#endif
diff --git a/firmware/export/audiohw.h b/firmware/export/audiohw.h
index e53db7e7b9..66fc19f923 100644
--- a/firmware/export/audiohw.h
+++ b/firmware/export/audiohw.h
@@ -59,6 +59,8 @@
59#include "tsc2100.h" 59#include "tsc2100.h"
60#elif defined(HAVE_JZ4740_CODEC) 60#elif defined(HAVE_JZ4740_CODEC)
61#include "jz4740-codec.h" 61#include "jz4740-codec.h"
62#elif defined(HAVE_AK4537)
63#include "ak4537.h"
62#endif 64#endif
63 65
64/* convert caps into defines */ 66/* convert caps into defines */
diff --git a/firmware/export/config-yh820.h b/firmware/export/config-yh820.h
new file mode 100644
index 0000000000..b96a7c72ea
--- /dev/null
+++ b/firmware/export/config-yh820.h
@@ -0,0 +1,187 @@
1/*
2 * This config file is for the Samsung YH-820
3 */
4
5#define TARGET_TREE /* this target is using the target tree system */
6
7/* For Rolo and boot loader */
8#define MODEL_NUMBER 57
9#define MODEL_NAME "Samsung YH-820"
10
11/* define this if you have recording possibility */
12/* todo #define HAVE_RECORDING */
13
14/* Define bitmask of input sources - recordable bitmask can be defined
15 explicitly if different */
16#define INPUT_SRC_CAPS (SRC_CAP_MIC | SRC_CAP_LINEIN )
17
18/* define the bitmask of hardware sample rates */
19#define HW_SAMPR_CAPS (SAMPR_CAP_48 | SAMPR_CAP_44 | SAMPR_CAP_32 | \
20 SAMPR_CAP_24 | SAMPR_CAP_22 | SAMPR_CAP_16 | \
21 SAMPR_CAP_11 | SAMPR_CAP_8)
22
23/* define the bitmask of recording sample rates */
24#define REC_SAMPR_CAPS (SAMPR_CAP_48 | SAMPR_CAP_44 | SAMPR_CAP_32 | \
25 SAMPR_CAP_24 | SAMPR_CAP_22 | SAMPR_CAP_16 | \
26 SAMPR_CAP_11 | SAMPR_CAP_8)
27
28/* Type of LCD */
29#define CONFIG_LCD LCD_S6B33B2
30
31/* LCD dimensions */
32#define LCD_WIDTH 128
33#define LCD_HEIGHT 96
34#define LCD_DEPTH 16 /* 65536 colours */
35#define LCD_PIXELFORMAT RGB565
36
37#ifndef BOOTLOADER
38/* Define this if your LCD can be enabled/disabled */
39#define HAVE_LCD_ENABLE
40
41/* Define this if your LCD can be put to sleep.
42 HAVE_LCD_ENABLE should be defined as well. */
43/* todo #define HAVE_LCD_SLEEP*/
44/* todo #define HAVE_LCD_SLEEP_SETTING */
45#endif /* !BOOTLOADER */
46
47/* Define this for LCD backlight available */
48#define HAVE_BACKLIGHT
49
50/* Define this if your LCD can set contrast */
51#define HAVE_LCD_CONTRAST
52
53#define MIN_CONTRAST_SETTING 0
54#define MAX_CONTRAST_SETTING 255
55#define DEFAULT_CONTRAST_SETTING 137
56
57/* define this if you can flip your LCD */
58/* #define HAVE_LCD_FLIP */
59
60/* define this if you can invert the colours on your LCD */
61/* todo #define HAVE_LCD_INVERT */
62
63/* put the lcd frame buffer in IRAM */
64/* #define IRAM_LCDFRAMEBUFFER IDATA_ATTR */
65
66/* define this if you have a bitmap LCD display */
67#define HAVE_LCD_BITMAP
68
69/* define this if you have a colour LCD */
70#define HAVE_LCD_COLOR
71
72/* define this if you want album art for this target */
73#define HAVE_ALBUMART
74
75/* define this if you have access to the quickscreen */
76#define HAVE_QUICKSCREEN
77
78/* define this if you have access to the pitchscreen */
79#define HAVE_PITCHSCREEN
80
81/* define this if you would like tagcache to build on this target */
82#define HAVE_TAGCACHE
83
84#define CONFIG_KEYPAD SAMSUNG_YH_PAD
85
86/* Define this if you do software codec */
87#define CONFIG_CODEC SWCODEC
88
89/* define this if you have a real-time clock */
90/* todo verify rtc (or none) */
91/* #ifndef BOOTLOADER */
92#if 0
93#define CONFIG_RTC RTC_E8564
94#define HAVE_RTC_ALARM
95#endif
96
97/* define this if you have a disk storage, i.e. something
98 that needs spinups and can cause skips when shaked */
99#define HAVE_DISK_STORAGE
100
101/* define this if you use an ATA controller */
102#define CONFIG_STORAGE STORAGE_ATA
103
104/* We're able to shut off power to the HDD */
105#ifndef SIMULATOR
106/* todo #define HAVE_ATA_POWER_OFF */
107#endif
108
109/* Define this if you have a software controlled poweroff */
110#define HAVE_SW_POWEROFF
111
112/* The number of bytes reserved for loadable codecs */
113#define CODEC_SIZE 0x100000
114
115/* The number of bytes reserved for loadable plugins */
116#define PLUGIN_BUFFER_SIZE 0x80000
117
118/* Define this if you have the AK4537 audio codec */
119#define HAVE_AK4537
120
121/* AK4537 has no tone controls, so we use the software ones */
122#define HAVE_SW_TONE_CONTROLS
123
124#define AB_REPEAT_ENABLE 1
125
126#define BATTERY_CAPACITY_DEFAULT 1550 /* default battery capacity */
127#define BATTERY_CAPACITY_MIN 1500 /* min. capacity selectable */
128#define BATTERY_CAPACITY_MAX 3200 /* max. capacity selectable */
129#define BATTERY_CAPACITY_INC 50 /* capacity increment */
130#define BATTERY_TYPES_COUNT 1 /* only one type */
131
132/* Hardware controlled charging */
133#define CONFIG_CHARGING CHARGING_SIMPLE
134
135/* define this if the unit can be powered or charged via USB */
136#define HAVE_USB_POWER
137
138#ifndef SIMULATOR
139
140/* Define this if you have a PortalPlayer PP5020 */
141#define CONFIG_CPU PP5020
142
143/* Define this if you want to use the PP5020 i2c interface */
144#define CONFIG_I2C I2C_PP5020
145
146/* define this if the hardware can be powered off while charging */
147#define HAVE_POWEROFF_WHILE_CHARGING
148
149/* The start address index for ROM builds */
150#define ROM_START 0x00000000
151
152/* The size of the flash ROM */
153#define FLASH_SIZE 0x100000
154
155/* Define this to the CPU frequency */
156#define CPU_FREQ 75000000
157
158/* USB On-the-go */
159#define CONFIG_USBOTG USBOTG_ARC
160
161/* enable these for the experimental usb stack */
162#define HAVE_USBSTACK
163#define USE_ROCKBOX_USB
164/* todo - check */
165#define USB_VENDOR_ID 0x04e8
166#define USB_PRODUCT_ID 0x5023
167
168/* Virtual LED (icon) */
169#define CONFIG_LED LED_VIRTUAL
170
171/* Define this if you have adjustable CPU frequency */
172#define HAVE_ADJUSTABLE_CPU_FREQ
173
174#define MI4_FORMAT
175#define BOOTFILE_EXT "mi4"
176#define BOOTFILE "rockbox." BOOTFILE_EXT
177#define BOOTDIR "/.rockbox"
178
179/* Offset ( in the firmware file's header ) to the file CRC */
180#define FIRMWARE_OFFSET_FILE_CRC 0x00
181
182/* Offset ( in the firmware file's header ) to the real data */
183#define FIRMWARE_OFFSET_FILE_DATA 0x00
184
185#define ICODE_ATTR_TREMOR_NOT_MDCT
186
187#endif /* !SIMULATOR */
diff --git a/firmware/export/config-yh920.h b/firmware/export/config-yh920.h
new file mode 100644
index 0000000000..62febaac71
--- /dev/null
+++ b/firmware/export/config-yh920.h
@@ -0,0 +1,193 @@
1/*
2 * This config file is for the Samsung YH-920
3 */
4
5#define TARGET_TREE /* this target is using the target tree system */
6
7/* For Rolo and boot loader */
8#define MODEL_NUMBER 58
9#define MODEL_NAME "Samsung YH-920"
10
11/* define this if you have recording possibility */
12/* todo #define HAVE_RECORDING */
13
14/* Define bitmask of input sources - recordable bitmask can be defined
15 explicitly if different */
16#define INPUT_SRC_CAPS (SRC_CAP_MIC | SRC_CAP_LINEIN )
17
18/* define the bitmask of hardware sample rates */
19#define HW_SAMPR_CAPS (SAMPR_CAP_48 | SAMPR_CAP_44 | SAMPR_CAP_32 | \
20 SAMPR_CAP_24 | SAMPR_CAP_22 | SAMPR_CAP_16 | \
21 SAMPR_CAP_11 | SAMPR_CAP_8)
22
23/* define the bitmask of recording sample rates */
24#define REC_SAMPR_CAPS (SAMPR_CAP_48 | SAMPR_CAP_44 | SAMPR_CAP_32 | \
25 SAMPR_CAP_24 | SAMPR_CAP_22 | SAMPR_CAP_16 | \
26 SAMPR_CAP_11 | SAMPR_CAP_8)
27
28/* Type of LCD */
29#define CONFIG_LCD LCD_S1D15E06
30
31/* LCD dimensions */
32#define LCD_WIDTH 160
33#define LCD_HEIGHT 128
34#define LCD_DEPTH 2
35#define LCD_PIXELFORMAT VERTICAL_PACKING
36
37/* Display colours, for screenshots and sim (0xRRGGBB) */
38#define LCD_DARKCOLOR 0x000000
39#define LCD_BRIGHTCOLOR 0x5a915a
40#define LCD_BL_DARKCOLOR 0x000000
41#define LCD_BL_BRIGHTCOLOR 0xadd8e6
42
43/* todo */
44/* #ifndef BOOTLOADER */
45#if 0
46/* Define this if your LCD can be enabled/disabled */
47#define HAVE_LCD_ENABLE
48
49/* Define this if your LCD can be put to sleep. HAVE_LCD_ENABLE
50 * should be defined as well.
51 * We can currently put the lcd to sleep but it won't wake up properly */
52#define HAVE_LCD_SLEEP
53#define HAVE_LCD_SLEEP_SETTING
54#endif
55
56/* Define this for LCD backlight available */
57#define HAVE_BACKLIGHT
58
59/* Define this if your LCD can set contrast */
60/* todo #define HAVE_LCD_CONTRAST */
61
62#define MIN_CONTRAST_SETTING 0
63#define MAX_CONTRAST_SETTING 30
64#define DEFAULT_CONTRAST_SETTING 14 /* Match boot contrast */
65
66/* define this if you can flip your LCD */
67/* todo #define HAVE_LCD_FLIP */
68
69/* define this if you can invert the colours on your LCD */
70/* todo #define HAVE_LCD_INVERT */
71
72/* put the lcd frame buffer in IRAM */
73/* #define IRAM_LCDFRAMEBUFFER IDATA_ATTR */
74
75/* define this if you have a bitmap LCD display */
76#define HAVE_LCD_BITMAP
77
78/* define this if you want album art for this target */
79#define HAVE_ALBUMART
80
81/* define this if you have access to the quickscreen */
82#define HAVE_QUICKSCREEN
83
84/* define this if you have access to the pitchscreen */
85#define HAVE_PITCHSCREEN
86
87/* define this if you would like tagcache to build on this target */
88#define HAVE_TAGCACHE
89
90#define CONFIG_KEYPAD SAMSUNG_YH_PAD
91
92/* Define this if you do software codec */
93#define CONFIG_CODEC SWCODEC
94
95/* define this if you have a real-time clock */
96/* todo verify rtc (or none) */
97/* #ifndef BOOTLOADER */
98#if 0
99#define CONFIG_RTC RTC_E8564
100#define HAVE_RTC_ALARM
101#endif
102
103/* define this if you have a disk storage, i.e. something
104 that needs spinups and can cause skips when shaked */
105#define HAVE_DISK_STORAGE
106
107/* define this if you use an ATA controller */
108#define CONFIG_STORAGE STORAGE_ATA
109
110/* We're able to shut off power to the HDD */
111#ifndef SIMULATOR
112/* todo #define HAVE_ATA_POWER_OFF */
113#endif
114
115/* Define this if you have a software controlled poweroff */
116#define HAVE_SW_POWEROFF
117
118/* The number of bytes reserved for loadable codecs */
119#define CODEC_SIZE 0x100000
120
121/* The number of bytes reserved for loadable plugins */
122#define PLUGIN_BUFFER_SIZE 0x80000
123
124/* Define this if you have the AK4537 audio codec */
125#define HAVE_AK4537
126
127/* AK4537 has no tone controls, so we use the software ones */
128#define HAVE_SW_TONE_CONTROLS
129
130#define AB_REPEAT_ENABLE 1
131
132#define BATTERY_CAPACITY_DEFAULT 1550 /* default battery capacity */
133#define BATTERY_CAPACITY_MIN 1500 /* min. capacity selectable */
134#define BATTERY_CAPACITY_MAX 3200 /* max. capacity selectable */
135#define BATTERY_CAPACITY_INC 50 /* capacity increment */
136#define BATTERY_TYPES_COUNT 1 /* only one type */
137
138/* Hardware controlled charging */
139#define CONFIG_CHARGING CHARGING_SIMPLE
140
141/* define this if the unit can be powered or charged via USB */
142#define HAVE_USB_POWER
143
144#ifndef SIMULATOR
145
146/* Define this if you have a PortalPlayer PP5020 */
147#define CONFIG_CPU PP5020
148
149/* Define this if you want to use the PP5020 i2c interface */
150#define CONFIG_I2C I2C_PP5020
151
152/* define this if the hardware can be powered off while charging */
153#define HAVE_POWEROFF_WHILE_CHARGING
154
155/* The start address index for ROM builds */
156#define ROM_START 0x00000000
157
158/* The size of the flash ROM */
159#define FLASH_SIZE 0x100000
160
161/* Define this to the CPU frequency */
162#define CPU_FREQ 75000000
163
164/* USB On-the-go */
165#define CONFIG_USBOTG USBOTG_ARC
166
167/* enable these for the experimental usb stack */
168#define HAVE_USBSTACK
169#define USE_ROCKBOX_USB
170/* todo - check */
171#define USB_VENDOR_ID 0x04e8
172#define USB_PRODUCT_ID 0x5022
173
174/* Virtual LED (icon) */
175#define CONFIG_LED LED_VIRTUAL
176
177/* Define this if you have adjustable CPU frequency */
178#define HAVE_ADJUSTABLE_CPU_FREQ
179
180#define MI4_FORMAT
181#define BOOTFILE_EXT "mi4"
182#define BOOTFILE "rockbox." BOOTFILE_EXT
183#define BOOTDIR "/.rockbox"
184
185/* Offset ( in the firmware file's header ) to the file CRC */
186#define FIRMWARE_OFFSET_FILE_CRC 0x00
187
188/* Offset ( in the firmware file's header ) to the real data */
189#define FIRMWARE_OFFSET_FILE_DATA 0x00
190
191#define ICODE_ATTR_TREMOR_NOT_MDCT
192
193#endif /* !SIMULATOR */
diff --git a/firmware/export/config-yh925.h b/firmware/export/config-yh925.h
new file mode 100644
index 0000000000..3a6403f93f
--- /dev/null
+++ b/firmware/export/config-yh925.h
@@ -0,0 +1,190 @@
1/*
2 * This config file is for the Samsung YH-925
3 */
4
5#define TARGET_TREE /* this target is using the target tree system */
6
7/* For Rolo and boot loader */
8#define MODEL_NUMBER 59
9#define MODEL_NAME "Samsung YH-925"
10
11/* define this if you have recording possibility */
12/* todo #define HAVE_RECORDING */
13
14/* Define bitmask of input sources - recordable bitmask can be defined
15 explicitly if different */
16#define INPUT_SRC_CAPS (SRC_CAP_MIC | SRC_CAP_LINEIN )
17
18/* define the bitmask of hardware sample rates */
19#define HW_SAMPR_CAPS (SAMPR_CAP_48 | SAMPR_CAP_44 | SAMPR_CAP_32 | \
20 SAMPR_CAP_24 | SAMPR_CAP_22 | SAMPR_CAP_16 | \
21 SAMPR_CAP_11 | SAMPR_CAP_8)
22
23/* define the bitmask of recording sample rates */
24#define REC_SAMPR_CAPS (SAMPR_CAP_48 | SAMPR_CAP_44 | SAMPR_CAP_32 | \
25 SAMPR_CAP_24 | SAMPR_CAP_22 | SAMPR_CAP_16 | \
26 SAMPR_CAP_11 | SAMPR_CAP_8)
27
28/* Type of LCD */
29#define CONFIG_LCD LCD_YH925
30
31/* LCD dimensions */
32#define LCD_WIDTH 160
33#define LCD_HEIGHT 128
34#define LCD_DEPTH 16 /* 65536 colours */
35#define LCD_PIXELFORMAT RGB565
36
37/* todo */
38/* #ifndef BOOTLOADER */
39#if 0
40/* Define this if your LCD can be enabled/disabled */
41#define HAVE_LCD_ENABLE
42
43/* Define this if your LCD can be put to sleep. HAVE_LCD_ENABLE
44 * should be defined as well.
45 * We can currently put the lcd to sleep but it won't wake up properly */
46#define HAVE_LCD_SLEEP
47#define HAVE_LCD_SLEEP_SETTING
48#endif
49
50/* Define this for LCD backlight available */
51#define HAVE_BACKLIGHT
52
53/* Define this if your LCD can set contrast */
54/* todo #define HAVE_LCD_CONTRAST */
55
56#define MIN_CONTRAST_SETTING 0
57#define MAX_CONTRAST_SETTING 30
58#define DEFAULT_CONTRAST_SETTING 14 /* Match boot contrast */
59
60/* define this if you can flip your LCD */
61/* todo #define HAVE_LCD_FLIP */
62
63/* define this if you can invert the colours on your LCD */
64/* todo #define HAVE_LCD_INVERT */
65
66/* put the lcd frame buffer in IRAM */
67/* #define IRAM_LCDFRAMEBUFFER IDATA_ATTR */
68
69/* define this if you have a bitmap LCD display */
70#define HAVE_LCD_BITMAP
71
72/* define this if you have a colour LCD */
73#define HAVE_LCD_COLOR
74
75/* define this if you want album art for this target */
76#define HAVE_ALBUMART
77
78/* define this if you have access to the quickscreen */
79#define HAVE_QUICKSCREEN
80
81/* define this if you have access to the pitchscreen */
82#define HAVE_PITCHSCREEN
83
84/* define this if you would like tagcache to build on this target */
85#define HAVE_TAGCACHE
86
87#define CONFIG_KEYPAD SAMSUNG_YH_PAD
88
89/* Define this if you do software codec */
90#define CONFIG_CODEC SWCODEC
91
92/* define this if you have a real-time clock */
93/* todo verify rtc (or none) */
94/* #ifndef BOOTLOADER */
95#if 0
96#define CONFIG_RTC RTC_E8564
97#define HAVE_RTC_ALARM
98#endif
99
100/* define this if you have a disk storage, i.e. something
101 that needs spinups and can cause skips when shaked */
102#define HAVE_DISK_STORAGE
103
104/* define this if you use an ATA controller */
105#define CONFIG_STORAGE STORAGE_ATA
106
107/* We're able to shut off power to the HDD */
108#ifndef SIMULATOR
109/* todo #define HAVE_ATA_POWER_OFF */
110#endif
111
112/* Define this if you have a software controlled poweroff */
113#define HAVE_SW_POWEROFF
114
115/* The number of bytes reserved for loadable codecs */
116#define CODEC_SIZE 0x100000
117
118/* The number of bytes reserved for loadable plugins */
119#define PLUGIN_BUFFER_SIZE 0x80000
120
121/* Define this if you have the AK4537 audio codec */
122#define HAVE_AK4537
123
124/* AK4537 has no tone controls, so we use the software ones */
125#define HAVE_SW_TONE_CONTROLS
126
127#define AB_REPEAT_ENABLE 1
128
129#define BATTERY_CAPACITY_DEFAULT 1550 /* default battery capacity */
130#define BATTERY_CAPACITY_MIN 1500 /* min. capacity selectable */
131#define BATTERY_CAPACITY_MAX 3200 /* max. capacity selectable */
132#define BATTERY_CAPACITY_INC 50 /* capacity increment */
133#define BATTERY_TYPES_COUNT 1 /* only one type */
134
135/* Hardware controlled charging */
136#define CONFIG_CHARGING CHARGING_SIMPLE
137
138/* define this if the unit can be powered or charged via USB */
139#define HAVE_USB_POWER
140
141#ifndef SIMULATOR
142
143/* Define this if you have a PortalPlayer PP5020 */
144#define CONFIG_CPU PP5020
145
146/* Define this if you want to use the PP5020 i2c interface */
147#define CONFIG_I2C I2C_PP5020
148
149/* define this if the hardware can be powered off while charging */
150#define HAVE_POWEROFF_WHILE_CHARGING
151
152/* The start address index for ROM builds */
153#define ROM_START 0x00000000
154
155/* The size of the flash ROM */
156#define FLASH_SIZE 0x100000
157
158/* Define this to the CPU frequency */
159#define CPU_FREQ 75000000
160
161/* USB On-the-go */
162#define CONFIG_USBOTG USBOTG_ARC
163
164/* enable these for the experimental usb stack */
165#define HAVE_USBSTACK
166#define USE_ROCKBOX_USB
167/* todo - check */
168#define USB_VENDOR_ID 0x04e8
169#define USB_PRODUCT_ID 0x5024
170
171/* Virtual LED (icon) */
172#define CONFIG_LED LED_VIRTUAL
173
174/* Define this if you have adjustable CPU frequency */
175#define HAVE_ADJUSTABLE_CPU_FREQ
176
177#define MI4_FORMAT
178#define BOOTFILE_EXT "mi4"
179#define BOOTFILE "rockbox." BOOTFILE_EXT
180#define BOOTDIR "/.rockbox"
181
182/* Offset ( in the firmware file's header ) to the file CRC */
183#define FIRMWARE_OFFSET_FILE_CRC 0x00
184
185/* Offset ( in the firmware file's header ) to the real data */
186#define FIRMWARE_OFFSET_FILE_DATA 0x00
187
188#define ICODE_ATTR_TREMOR_NOT_MDCT
189
190#endif /* !SIMULATOR */
diff --git a/firmware/export/config.h b/firmware/export/config.h
index ff9a8e9589..56cd2dec94 100644
--- a/firmware/export/config.h
+++ b/firmware/export/config.h
@@ -109,6 +109,7 @@
109#define SANSA_CLIP_PAD 35 109#define SANSA_CLIP_PAD 35
110#define SANSA_FUZE_PAD 36 110#define SANSA_FUZE_PAD 36
111#define LYRE_PROTO1_PAD 37 111#define LYRE_PROTO1_PAD 37
112#define SAMSUNG_YH_PAD 38
112 113
113/* CONFIG_REMOTE_KEYPAD */ 114/* CONFIG_REMOTE_KEYPAD */
114#define H100_REMOTE 1 115#define H100_REMOTE 1
@@ -185,7 +186,8 @@
185#define LCD_SSD1303 31 /* as used by the Sansa Clip */ 186#define LCD_SSD1303 31 /* as used by the Sansa Clip */
186#define LCD_FUZE 32 /* as used by the Sansa Fuze */ 187#define LCD_FUZE 32 /* as used by the Sansa Fuze */
187#define LCD_LYRE_PROTO1 33 /* as used by the Lyre */ 188#define LCD_LYRE_PROTO1 33 /* as used by the Lyre */
188 189#define LCD_YH925 34 /* as used by Samsung YH-925 (similar to the H10 20GB) */
190
189/* LCD_PIXELFORMAT */ 191/* LCD_PIXELFORMAT */
190#define HORIZONTAL_PACKING 1 192#define HORIZONTAL_PACKING 1
191#define VERTICAL_PACKING 2 193#define VERTICAL_PACKING 2
@@ -364,6 +366,12 @@ Lyre prototype 1*/
364#include "config-c200v2.h" 366#include "config-c200v2.h"
365#elif defined(LYRE_PROTO1) 367#elif defined(LYRE_PROTO1)
366#include "config-lyre_proto1.h" 368#include "config-lyre_proto1.h"
369#elif defined(SAMSUNG_YH820)
370#include "config-yh820.h"
371#elif defined(SAMSUNG_YH920)
372#include "config-yh920.h"
373#elif defined(SAMSUNG_YH925)
374#include "config-yh925.h"
367#else 375#else
368/* no known platform */ 376/* no known platform */
369#endif 377#endif
diff --git a/firmware/export/usb.h b/firmware/export/usb.h
index 42893c3468..557639c622 100644
--- a/firmware/export/usb.h
+++ b/firmware/export/usb.h
@@ -84,6 +84,9 @@ enum {
84#elif CONFIG_KEYPAD == PHILIPS_HDD1630_PAD 84#elif CONFIG_KEYPAD == PHILIPS_HDD1630_PAD
85#define USBPOWER_BUTTON BUTTON_PLAYLIST 85#define USBPOWER_BUTTON BUTTON_PLAYLIST
86#define USBPOWER_BTN_IGNORE BUTTON_POWER 86#define USBPOWER_BTN_IGNORE BUTTON_POWER
87#elif CONFIG_KEYPAD == SAMSUNG_YH_PAD
88#define USBPOWER_BUTTON BUTTON_RIGHT
89#define USBPOWER_BTN_IGNORE BUTTON_LEFT
87#endif 90#endif
88#endif /* HAVE_USB_POWER */ 91#endif /* HAVE_USB_POWER */
89 92