1 /***************************************************************************
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
10 * Copyright (C) 2007 Jonathan Gordon
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.
17 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
18 * KIND, either express or implied.
20 ****************************************************************************/
31 #include "backlight.h"
33 #include "settings_list.h"
40 #include "powermgmt.h"
42 #include "lcd-remote.h"
44 #include "rbunicode.h"
45 #ifdef HAVE_LCD_BITMAP
46 #include "peakmeter.h"
48 #include "menus/eq_menu.h"
53 #define NVRAM(bytes) (bytes<<F_NVRAM_MASK_SHIFT)
54 /** NOTE: NVRAM_CONFIG_VERSION is in settings_list.h
55 and you may need to update it if you edit this file */
57 #define UNUSED {.RESERVED=NULL}
58 #define INT(a) {.int_ = a}
59 #define UINT(a) {.uint_ = a}
60 #define BOOL(a) {.bool_ = a}
61 #define CHARPTR(a) {.charptr = a}
62 #define UCHARPTR(a) {.ucharptr = a}
63 #define FUNCTYPE(a) {.func = a}
64 #define NODEFAULT INT(0)
66 /* in all the following macros the args are:
67 - flags: bitwise | or the F_ bits in settings_list.h
68 - var: pointer to the variable being changed (usually in global_settings)
69 - lang_id: LANG_* id to display in menus and setting screens for the setting
70 - default: the default value for the variable, set if settings are reset
71 - name: the name of the setting in config files
72 - cfg_vals: comma seperated list of legal values in cfg files.
73 NULL if a number is written to the file instead.
74 - cb: the callback used by the setting screen.
77 /* Use for int settings which use the set_sound() function to set them */
78 #define SOUND_SETTING(flags,var,lang_id,name,setting) \
79 {flags|F_T_INT|F_T_SOUND|F_SOUNDSETTING, &global_settings.var, \
80 lang_id, NODEFAULT,name,NULL, \
81 {.sound_setting=(struct sound_setting[]){{setting}}} }
83 /* Use for bool variables which don't use LANG_SET_BOOL_YES and LANG_SET_BOOL_NO
84 or dont save as "off" or "on" in the cfg */
85 #define BOOL_SETTING(flags,var,lang_id,default,name,cfgvals,yes,no,cb) \
86 {flags|F_BOOL_SETTING, &global_settings.var, \
87 lang_id, BOOL(default),name,cfgvals, \
88 {.bool_setting=(struct bool_setting[]){{cb,yes,no}}} }
90 /* bool setting which does use LANG_YES and _NO and save as "off,on" */
91 #define OFFON_SETTING(flags,var,lang_id,default,name,cb) \
92 {flags|F_BOOL_SETTING, &global_settings.var, \
93 lang_id, BOOL(default),name,off_on, \
94 {.bool_setting=(struct bool_setting[]) \
95 {{cb,LANG_SET_BOOL_YES,LANG_SET_BOOL_NO}}} }
97 /* int variable which is NOT saved to .cfg files,
98 (Use NVRAM() in the flags to save to the nvram (or nvram.bin file) */
99 #define SYSTEM_SETTING(flags,var,default) \
100 {flags|F_T_INT, &global_status.var,-1, INT(default), \
103 /* setting which stores as a filename (or another string) in the .cfgvals
104 The string must be a char array (which all of our string settings are),
105 not just a char pointer.
106 prefix: The absolute path to not save in the variable, ex /.rockbox/wps_file
107 suffix: The file extention (usually...) e.g .wps_file
108 If the prefix is set (not NULL), then the suffix must be set as well.
110 #define TEXT_SETTING(flags,var,name,default,prefix,suffix) \
111 {flags|F_T_UCHARPTR, &global_settings.var,-1, \
112 CHARPTR(default),name,NULL, \
113 {.filename_setting= \
114 (struct filename_setting[]){ \
115 {prefix,suffix,sizeof(global_settings.var)}}} }
117 /* Used for settings which use the set_option() setting screen.
118 The ... arg is a list of pointers to strings to display in the setting
119 screen. These can either be literal strings, or ID2P(LANG_*) */
120 #define CHOICE_SETTING(flags,var,lang_id,default,name,cfg_vals,cb,count,...) \
121 {flags|F_CHOICE_SETTING|F_T_INT, &global_settings.var, lang_id, \
122 INT(default), name, cfg_vals, \
123 {.choice_setting = (struct choice_setting[]){ \
124 {cb, count, {.desc = (const unsigned char*[]) \
127 /* Similar to above, except the strings to display are taken from cfg_vals,
128 the ... arg is a list of ID's to talk for the strings, can use TALK_ID()'s */
129 #define STRINGCHOICE_SETTING(flags,var,lang_id,default,name,cfg_vals, \
131 {flags|F_CHOICE_SETTING|F_T_INT|F_CHOICETALKS, \
132 &global_settings.var, lang_id, \
133 INT(default), name, cfg_vals, \
134 {.choice_setting = (struct choice_setting[]){ \
135 {cb, count, {.talks = (const int[]){__VA_ARGS__}}}}}}
137 /* for settings which use the set_int() setting screen.
138 unit is the UNIT_ define to display/talk.
139 the first one saves a string to the config file,
140 the second one saves the variable value to the config file */
141 #define INT_SETTING_W_CFGVALS(flags, var, lang_id, default, name, cfg_vals, \
142 unit, min, max, step, formatter, get_talk_id, cb) \
143 {flags|F_INT_SETTING|F_T_INT, &global_settings.var, \
144 lang_id, INT(default), name, cfg_vals, \
145 {.int_setting = (struct int_setting[]){ \
146 {cb, unit, min, max, step, formatter, get_talk_id}}}}
147 #define INT_SETTING(flags, var, lang_id, default, name, \
148 unit, min, max, step, formatter, get_talk_id, cb) \
149 {flags|F_INT_SETTING|F_T_INT, &global_settings.var, \
150 lang_id, INT(default), name, NULL, \
151 {.int_setting = (struct int_setting[]){ \
152 {cb, unit, min, max, step, formatter, get_talk_id}}}}
153 #define INT_SETTING_NOWRAP(flags, var, lang_id, default, name, \
154 unit, min, max, step, formatter, get_talk_id, cb) \
155 {flags|F_INT_SETTING|F_T_INT|F_NO_WRAP, &global_settings.var, \
156 lang_id, INT(default), name, NULL, \
157 {.int_setting = (struct int_setting[]){ \
158 {cb, unit, min, max, step, formatter, get_talk_id}}}}
160 #define TABLE_SETTING(flags, var, lang_id, default, name, cfg_vals, \
161 unit, formatter, get_talk_id, cb, count, ...) \
162 {flags|F_TABLE_SETTING|F_T_INT, &global_settings.var, \
163 lang_id, INT(default), name, cfg_vals, \
164 {.table_setting = (struct table_setting[]) { \
165 {cb, formatter, get_talk_id, unit, count, \
166 (const int[]){__VA_ARGS__}}}}}
168 /* some sets of values which are used more than once, to save memory */
169 static const char off_on
[] = "off,on";
170 static const char off_on_ask
[] = "off,on,ask";
171 static const char off_number_spell
[] = "off,number,spell";
172 #ifdef HAVE_LCD_BITMAP
173 static const char graphic_numeric
[] = "graphic,numeric";
176 /* Default theme settings */
177 #define DEFAULT_WPSNAME "cabbiev2"
179 #ifdef HAVE_LCD_BITMAP
182 #define DEFAULT_FONTNAME "08-Rockfont"
183 #elif LCD_HEIGHT <= 80
184 #define DEFAULT_FONTNAME "11-Sazanami-Mincho"
185 #elif LCD_HEIGHT <= 220
186 #define DEFAULT_FONTNAME "12-Adobe-Helvetica"
187 #elif LCD_HEIGHT <= 320
188 #define DEFAULT_FONTNAME "15-Adobe-Helvetica"
190 #define DEFAULT_FONTNAME "12-Adobe-Helvetica"
194 #define DEFAULT_FONTNAME ""
197 #ifdef HAVE_LCD_COLOR
198 #define DEFAULT_ICONSET "tango_small"
199 #define DEFAULT_VIEWERS_ICONSET "tango_small_viewers"
201 #define DEFAULT_ICONSET "tango_small_mono"
202 #define DEFAULT_VIEWERS_ICONSET "tango_small_viewers_mono"
203 #else /* monochrome */
204 #define DEFAULT_ICONSET ""
205 #define DEFAULT_VIEWERS_ICONSET ""
208 #define DEFAULT_THEME_FOREGROUND LCD_RGBPACK(0xce, 0xcf, 0xce)
209 #define DEFAULT_THEME_BACKGROUND LCD_RGBPACK(0x00, 0x00, 0x00)
210 #define DEFAULT_THEME_SELECTOR_START LCD_RGBPACK(0xff, 0xeb, 0x9c)
211 #define DEFAULT_THEME_SELECTOR_END LCD_RGBPACK(0xb5, 0x8e, 0x00)
212 #define DEFAULT_THEME_SELECTOR_TEXT LCD_RGBPACK(0x00, 0x00, 0x00)
214 #define DEFAULT_BACKDROP "cabbiev2"
216 #ifdef HAVE_RECORDING
217 /* these should be in the config.h files */
218 #if CONFIG_CODEC == MAS3587F
219 # define DEFAULT_REC_MIC_GAIN 8
220 # define DEFAULT_REC_LEFT_GAIN 2
221 # define DEFAULT_REC_RIGHT_GAIN 2
222 #elif CONFIG_CODEC == SWCODEC
224 # define DEFAULT_REC_MIC_GAIN 16
225 # define DEFAULT_REC_LEFT_GAIN 0
226 # define DEFAULT_REC_RIGHT_GAIN 0
227 # elif defined(HAVE_TLV320)
228 # define DEFAULT_REC_MIC_GAIN 0
229 # define DEFAULT_REC_LEFT_GAIN 0
230 # define DEFAULT_REC_RIGHT_GAIN 0
231 # elif defined(HAVE_WM8975)
232 # define DEFAULT_REC_MIC_GAIN 16
233 # define DEFAULT_REC_LEFT_GAIN 0
234 # define DEFAULT_REC_RIGHT_GAIN 0
235 # elif defined(HAVE_WM8758)
236 # define DEFAULT_REC_MIC_GAIN 16
237 # define DEFAULT_REC_LEFT_GAIN 0
238 # define DEFAULT_REC_RIGHT_GAIN 0
239 # elif defined(HAVE_WM8731)
240 # define DEFAULT_REC_MIC_GAIN 16
241 # define DEFAULT_REC_LEFT_GAIN 0
242 # define DEFAULT_REC_RIGHT_GAIN 0
246 #endif /* HAVE_RECORDING */
248 static void formatter_unit_0_is_off(char *buffer
, size_t buffer_size
,
249 int val
, const char *unit
)
252 strcpy(buffer
, str(LANG_OFF
));
254 snprintf(buffer
, buffer_size
, "%d %s", val
, unit
);
257 static int32_t getlang_unit_0_is_off(int value
, int unit
)
262 return TALK_ID(value
,unit
);
265 static void formatter_unit_0_is_skip_track(char *buffer
, size_t buffer_size
,
266 int val
, const char *unit
)
270 strcpy(buffer
, str(LANG_SKIP_TRACK
));
271 else if (val
% 60 == 0)
272 snprintf(buffer
, buffer_size
, "%d min", val
/60);
274 snprintf(buffer
, buffer_size
, "%d s", val
);
277 static int32_t getlang_unit_0_is_skip_track(int value
, int unit
)
281 return LANG_SKIP_TRACK
;
282 else if (value
% 60 == 0)
283 return TALK_ID(value
/60, UNIT_MIN
);
285 return TALK_ID(value
, UNIT_SEC
);
288 #ifdef HAVE_BACKLIGHT
289 static void backlight_formatter(char *buffer
, size_t buffer_size
,
290 int val
, const char *unit
)
293 strcpy(buffer
, str(LANG_OFF
));
295 strcpy(buffer
, str(LANG_ON
));
297 snprintf(buffer
, buffer_size
, "%d %s", val
, unit
);
299 static int32_t backlight_getlang(int value
, int unit
)
306 return TALK_ID(value
, unit
);
310 #ifndef HAVE_SCROLLWHEEL
311 static void scanaccel_formatter(char *buffer
, size_t buffer_size
,
312 int val
, const char *unit
)
316 strcpy(buffer
, str(LANG_OFF
));
318 snprintf(buffer
, buffer_size
, "2x/%ds", val
);
322 #if CONFIG_CODEC == SWCODEC
323 static void crossfeed_cross_set(int val
)
326 dsp_set_crossfeed_cross_params(global_settings
.crossfeed_cross_gain
,
327 global_settings
.crossfeed_hf_attenuation
,
328 global_settings
.crossfeed_hf_cutoff
);
331 static void db_format(char* buffer
, size_t buffer_size
, int value
,
336 snprintf(buffer
, buffer_size
, "%s%d.%d %s", value
< 0 ? "-" : "",
337 v
/ 10, v
% 10, unit
);
340 static int32_t get_dec_talkid(int value
, int unit
)
342 return TALK_ID_DECIMAL(value
, 1, unit
);
345 static int32_t get_precut_talkid(int value
, int unit
)
347 return TALK_ID_DECIMAL(-value
, 1, unit
);
351 #if (CONFIG_CODEC == MAS3587F) || (CONFIG_CODEC == MAS3539F)
352 static void set_mdb_enable(bool value
)
354 sound_set_mdb_enable((int)value
);
356 static void set_superbass(bool value
)
358 sound_set_superbass((int)value
);
362 #ifdef HAVE_LCD_CHARCELLS
363 static void jumpscroll_format(char* buffer
, size_t buffer_size
, int value
,
370 strcpy(buffer
, str(LANG_OFF
));
373 strcpy(buffer
, str(LANG_ONE_TIME
));
378 snprintf(buffer
, buffer_size
, "%d", value
);
381 strcpy(buffer
, str(LANG_ALWAYS
));
385 static int32_t jumpscroll_getlang(int value
, int unit
)
392 return LANG_ONE_TIME
;
396 return TALK_ID(value
, unit
);
402 #endif /* HAVE_LCD_CHARCELLS */
404 const struct settings_list settings
[] = {
406 SOUND_SETTING(F_NO_WRAP
,volume
, LANG_VOLUME
, "volume", SOUND_VOLUME
),
407 SOUND_SETTING(0, balance
, LANG_BALANCE
, "balance", SOUND_BALANCE
),
408 SOUND_SETTING(F_NO_WRAP
,bass
, LANG_BASS
, "bass", SOUND_BASS
),
409 SOUND_SETTING(F_NO_WRAP
,treble
, LANG_TREBLE
, "treble", SOUND_TREBLE
),
411 #if (CONFIG_CODEC == MAS3587F) || (CONFIG_CODEC == MAS3539F)
412 SOUND_SETTING(0,loudness
, LANG_LOUDNESS
, "loudness", SOUND_LOUDNESS
),
413 STRINGCHOICE_SETTING(F_SOUNDSETTING
,avc
,LANG_AUTOVOL
,0,"auto volume",
414 "off,20ms,2,4,8,", sound_set_avc
, 5,
415 LANG_OFF
,TALK_ID(20, UNIT_MS
),TALK_ID(2, UNIT_SEC
),
416 TALK_ID(4, UNIT_SEC
),TALK_ID(8, UNIT_SEC
)),
417 OFFON_SETTING(F_SOUNDSETTING
, superbass
, LANG_SUPERBASS
, false, "superbass",
421 CHOICE_SETTING(F_SOUNDSETTING
, channel_config
, LANG_CHANNEL_CONFIGURATION
,
423 "stereo,mono,custom,mono left,mono right,karaoke",
424 sound_set_channels
, 6,
425 ID2P(LANG_CHANNEL_STEREO
), ID2P(LANG_CHANNEL_MONO
),
426 ID2P(LANG_CHANNEL_CUSTOM
), ID2P(LANG_CHANNEL_LEFT
),
427 ID2P(LANG_CHANNEL_RIGHT
), ID2P(LANG_CHANNEL_KARAOKE
)),
428 SOUND_SETTING(F_SOUNDSETTING
, stereo_width
, LANG_STEREO_WIDTH
,
429 "stereo_width", SOUND_STEREO_WIDTH
),
431 OFFON_SETTING(0, playlist_shuffle
, LANG_SHUFFLE
, false, "shuffle", NULL
),
432 SYSTEM_SETTING(NVRAM(4), resume_index
, -1),
433 SYSTEM_SETTING(NVRAM(4), resume_offset
, -1),
434 CHOICE_SETTING(0, repeat_mode
, LANG_REPEAT
, REPEAT_ALL
, "repeat",
435 "off,all,one,shuffle"
436 #ifdef AB_REPEAT_ENABLE
440 #ifdef AB_REPEAT_ENABLE
445 ID2P(LANG_OFF
), ID2P(LANG_ALL
), ID2P(LANG_REPEAT_ONE
),
447 #ifdef AB_REPEAT_ENABLE
448 ,ID2P(LANG_REPEAT_AB
)
450 ), /* CHOICE_SETTING( repeat_mode ) */
452 #ifdef HAVE_LCD_CONTRAST
453 /* its easier to leave this one un-macro()ed for the time being */
454 { F_T_INT
|F_DEF_ISFUNC
|F_INT_SETTING
, &global_settings
.contrast
,
455 LANG_CONTRAST
, FUNCTYPE(lcd_default_contrast
), "contrast", NULL
, {
456 .int_setting
= (struct int_setting
[]) {
457 { lcd_set_contrast
, UNIT_INT
, MIN_CONTRAST_SETTING
,
458 MAX_CONTRAST_SETTING
, 1, NULL
, NULL
}}}},
460 #ifdef HAVE_BACKLIGHT
461 TABLE_SETTING(F_ALLOW_ARBITRARY_VALS
, backlight_timeout
, LANG_BACKLIGHT
, 5,
462 "backlight timeout", off_on
, UNIT_SEC
, backlight_formatter
,
463 backlight_getlang
, backlight_set_timeout
, 20,
464 -1,0,1,2,3,4,5,6,7,8,9,10,15,20,25,30,45,60,90,120),
466 TABLE_SETTING(F_ALLOW_ARBITRARY_VALS
, backlight_timeout_plugged
,
467 LANG_BACKLIGHT_ON_WHEN_CHARGING
, 10,
468 "backlight timeout plugged", off_on
, UNIT_SEC
,
469 backlight_formatter
, backlight_getlang
,
470 backlight_set_timeout_plugged
, 20,
471 -1,0,1,2,3,4,5,6,7,8,9,10,15,20,25,30,45,60,90,120),
473 #endif /* HAVE_BACKLIGHT */
474 #ifdef HAVE_LCD_BITMAP
475 #ifdef HAVE_LCD_INVERT
476 BOOL_SETTING(0, invert
, LANG_INVERT
, false ,"invert", off_on
,
477 LANG_INVERT_LCD_INVERSE
, LANG_NORMAL
, lcd_set_invert_display
),
480 OFFON_SETTING(0, flip_display
, LANG_FLIP_DISPLAY
, false, "flip display",
484 CHOICE_SETTING(F_TEMPVAR
|F_THEMESETTING
, cursor_style
, LANG_INVERT_CURSOR
,
485 #ifdef HAVE_LCD_COLOR
487 "pointer,bar (inverse),bar (color),bar (gradient)", NULL
, 4,
488 ID2P(LANG_INVERT_CURSOR_POINTER
),
489 ID2P(LANG_INVERT_CURSOR_BAR
),
490 ID2P(LANG_INVERT_CURSOR_COLOR
),
491 ID2P(LANG_INVERT_CURSOR_GRADIENT
)),
493 1, "selector type", "pointer,bar (inverse)", NULL
, 2,
494 ID2P(LANG_INVERT_CURSOR_POINTER
),
495 ID2P(LANG_INVERT_CURSOR_BAR
)),
497 OFFON_SETTING(F_THEMESETTING
|F_TEMPVAR
, statusbar
,
498 LANG_STATUS_BAR
, true,"statusbar", NULL
),
499 OFFON_SETTING(0,scrollbar
, LANG_SCROLL_BAR
, true,"scrollbar", NULL
),
500 #if CONFIG_KEYPAD == RECORDER_PAD
501 OFFON_SETTING(0,buttonbar
, LANG_BUTTON_BAR
,true,"buttonbar", NULL
),
503 CHOICE_SETTING(0, volume_type
, LANG_VOLUME_DISPLAY
, 0,
504 "volume display", graphic_numeric
, NULL
, 2,
505 ID2P(LANG_DISPLAY_GRAPHIC
),
506 ID2P(LANG_DISPLAY_NUMERIC
)),
507 CHOICE_SETTING(0, battery_display
, LANG_BATTERY_DISPLAY
, 0,
508 "battery display", graphic_numeric
, NULL
, 2,
509 ID2P(LANG_DISPLAY_GRAPHIC
), ID2P(LANG_DISPLAY_NUMERIC
)),
511 CHOICE_SETTING(0, timeformat
, LANG_TIMEFORMAT
, 0,
512 "time format", "24hour,12hour", NULL
, 2,
513 ID2P(LANG_24_HOUR_CLOCK
), ID2P(LANG_12_HOUR_CLOCK
)),
515 #endif /* HAVE_LCD_BITMAP */
516 OFFON_SETTING(0,show_icons
, LANG_SHOW_ICONS
,true,"show icons", NULL
),
518 TABLE_SETTING(F_ALLOW_ARBITRARY_VALS
, poweroff
, LANG_POWEROFF_IDLE
, 10,
519 "idle poweroff", "off", UNIT_MIN
, formatter_unit_0_is_off
,
520 getlang_unit_0_is_off
, set_poweroff_timeout
, 15,
521 0,1,2,3,4,5,6,7,8,9,10,15,30,45,60),
522 SYSTEM_SETTING(NVRAM(4), runtime
, 0),
523 SYSTEM_SETTING(NVRAM(4), topruntime
, 0),
524 INT_SETTING(0, max_files_in_playlist
,
525 LANG_MAX_FILES_IN_PLAYLIST
,
531 "max files in playlist", UNIT_INT
, 1000, 32000, 1000,
533 INT_SETTING(0, max_files_in_dir
, LANG_MAX_FILES_IN_DIR
,
539 "max files in dir", UNIT_INT
, 50, 10000, 50,
541 #if BATTERY_CAPACITY_INC > 0
542 INT_SETTING(0, battery_capacity
, LANG_BATTERY_CAPACITY
,
543 BATTERY_CAPACITY_DEFAULT
, "battery capacity", UNIT_MAH
,
544 BATTERY_CAPACITY_MIN
, BATTERY_CAPACITY_MAX
,
545 BATTERY_CAPACITY_INC
, NULL
, NULL
, NULL
),
548 OFFON_SETTING(NVRAM(1), car_adapter_mode
,
549 LANG_CAR_ADAPTER_MODE
, false, "car adapter mode", NULL
),
551 #ifdef HAVE_ACCESSORY_SUPPLY
552 OFFON_SETTING(0, accessory_supply
, LANG_ACCESSORY_SUPPLY
,
553 true, "accessory power supply", accessory_supply_set
),
557 OFFON_SETTING(0,fm_force_mono
, LANG_FM_MONO_MODE
,
558 false, "force fm mono", toggle_mono_mode
),
559 SYSTEM_SETTING(NVRAM(4),last_frequency
,0),
562 #if BATTERY_TYPES_COUNT > 1
563 CHOICE_SETTING(0, battery_type
, LANG_BATTERY_TYPE
, 0, "battery type",
564 "alkaline,nimh", NULL
, 2, ID2P(LANG_BATTERY_TYPE_ALKALINE
),
565 ID2P(LANG_BATTERY_TYPE_NIMH
)),
567 #ifdef HAVE_REMOTE_LCD
569 INT_SETTING(0, remote_contrast
, LANG_CONTRAST
,
570 DEFAULT_REMOTE_CONTRAST_SETTING
, "remote contrast", UNIT_INT
,
571 MIN_REMOTE_CONTRAST_SETTING
, MAX_REMOTE_CONTRAST_SETTING
, 1,
572 NULL
, NULL
, lcd_remote_set_contrast
),
573 BOOL_SETTING(0, remote_invert
, LANG_INVERT
, false ,"remote invert", off_on
,
574 LANG_INVERT_LCD_INVERSE
, LANG_NORMAL
,
575 lcd_remote_set_invert_display
),
576 OFFON_SETTING(0,remote_flip_display
, LANG_FLIP_DISPLAY
,
577 false,"remote flip display", NULL
),
578 TABLE_SETTING(F_ALLOW_ARBITRARY_VALS
, remote_backlight_timeout
,
579 LANG_BACKLIGHT
, 5, "remote backlight timeout", off_on
,
580 UNIT_SEC
, backlight_formatter
, backlight_getlang
,
581 remote_backlight_set_timeout
, 20,
582 -1,0,1,2,3,4,5,6,7,8,9,10,15,20,25,30,45,60,90,120),
584 TABLE_SETTING(F_ALLOW_ARBITRARY_VALS
, remote_backlight_timeout_plugged
,
585 LANG_BACKLIGHT_ON_WHEN_CHARGING
, 10,
586 "remote backlight timeout plugged", off_on
, UNIT_SEC
,
587 backlight_formatter
, backlight_getlang
,
588 remote_backlight_set_timeout_plugged
, 20,
589 -1,0,1,2,3,4,5,6,7,8,9,10,15,20,25,30,45,60,90,120),
591 #ifdef HAVE_REMOTE_LCD_TICKING
592 OFFON_SETTING(0, remote_reduce_ticking
, LANG_REDUCE_TICKING
,
593 false,"remote reduce ticking", NULL
),
597 #ifdef HAVE_BACKLIGHT
598 OFFON_SETTING(0, bl_filter_first_keypress
,
599 LANG_BACKLIGHT_FILTER_FIRST_KEYPRESS
, false,
600 "backlight filters first keypress", NULL
),
601 #ifdef HAVE_REMOTE_LCD
602 OFFON_SETTING(0, remote_bl_filter_first_keypress
,
603 LANG_BACKLIGHT_FILTER_FIRST_KEYPRESS
, false,
604 "backlight filters first remote keypress", NULL
),
606 #endif /* HAVE_BACKLIGHT */
608 /** End of old RTC config block **/
610 #ifdef HAVE_BACKLIGHT
611 OFFON_SETTING(0, caption_backlight
, LANG_CAPTION_BACKLIGHT
,
612 false, "caption backlight", NULL
),
613 #ifdef HAVE_REMOTE_LCD
614 OFFON_SETTING(0, remote_caption_backlight
, LANG_CAPTION_BACKLIGHT
,
615 false, "remote caption backlight", NULL
),
617 #endif /* HAVE_BACKLIGHT */
618 #ifdef HAVE_BACKLIGHT_BRIGHTNESS
619 INT_SETTING(F_NO_WRAP
, brightness
, LANG_BRIGHTNESS
,
620 DEFAULT_BRIGHTNESS_SETTING
, "brightness",UNIT_INT
,
621 MIN_BRIGHTNESS_SETTING
, MAX_BRIGHTNESS_SETTING
, 1,
622 NULL
, NULL
, backlight_set_brightness
),
624 #if defined(HAVE_BACKLIGHT_PWM_FADING) && !defined(SIMULATOR)
625 /* backlight fading */
626 TABLE_SETTING(F_ALLOW_ARBITRARY_VALS
, backlight_fade_in
,
627 LANG_BACKLIGHT_FADE_IN
, 300, "backlight fade in", "off",
628 UNIT_MS
, formatter_unit_0_is_off
, getlang_unit_0_is_off
,
629 backlight_set_fade_in
, 7, 0,100,200,300,500,1000,2000),
630 TABLE_SETTING(F_ALLOW_ARBITRARY_VALS
, backlight_fade_out
,
631 LANG_BACKLIGHT_FADE_OUT
, 2000, "backlight fade out", "off",
632 UNIT_MS
, formatter_unit_0_is_off
, getlang_unit_0_is_off
,
633 backlight_set_fade_out
, 10,
634 0,100,200,300,500,1000,2000,3000,5000,10000),
636 INT_SETTING(F_PADTITLE
, scroll_speed
, LANG_SCROLL_SPEED
, 9,"scroll speed",
637 UNIT_INT
, 0, 15, 1, NULL
, NULL
, lcd_scroll_speed
),
638 INT_SETTING(F_PADTITLE
, scroll_delay
, LANG_SCROLL_DELAY
, 1000,
639 "scroll delay", UNIT_MS
, 0, 2500, 100, NULL
,
640 NULL
, lcd_scroll_delay
),
641 INT_SETTING(0, bidir_limit
, LANG_BIDIR_SCROLL
, 50, "bidir limit",
642 UNIT_PERCENT
, 0, 200, 25, NULL
, NULL
, lcd_bidir_scroll
),
643 #ifdef HAVE_REMOTE_LCD
644 INT_SETTING(0, remote_scroll_speed
, LANG_SCROLL_SPEED
, 9,
645 "remote scroll speed", UNIT_INT
, 0,15, 1,
646 NULL
, NULL
, lcd_remote_scroll_speed
),
647 INT_SETTING(0, remote_scroll_step
, LANG_SCROLL_STEP
, 6,
648 "remote scroll step", UNIT_PIXEL
, 1, LCD_REMOTE_WIDTH
, 1, NULL
,
649 NULL
, lcd_remote_scroll_step
),
650 INT_SETTING(0, remote_scroll_delay
, LANG_SCROLL_DELAY
, 1000,
651 "remote scroll delay", UNIT_MS
, 0, 2500, 100, NULL
, NULL
,
652 lcd_remote_scroll_delay
),
653 INT_SETTING(0, remote_bidir_limit
, LANG_BIDIR_SCROLL
, 50,
654 "remote bidir limit", UNIT_PERCENT
, 0, 200, 25, NULL
, NULL
,
655 lcd_remote_bidir_scroll
),
657 #ifdef HAVE_LCD_BITMAP
658 OFFON_SETTING(0, offset_out_of_view
, LANG_SCREEN_SCROLL_VIEW
,
659 false, "Screen Scrolls Out Of View",
660 gui_list_screen_scroll_out_of_view
),
661 INT_SETTING(F_PADTITLE
, scroll_step
, LANG_SCROLL_STEP
, 6, "scroll step",
662 UNIT_PIXEL
, 1, LCD_WIDTH
, 1, NULL
, NULL
, lcd_scroll_step
),
663 INT_SETTING(F_PADTITLE
, screen_scroll_step
, LANG_SCREEN_SCROLL_STEP
, 16,
664 "screen scroll step", UNIT_PIXEL
, 1, LCD_WIDTH
, 1, NULL
, NULL
,
665 gui_list_screen_scroll_step
),
666 #endif /* HAVE_LCD_BITMAP */
667 #ifdef HAVE_LCD_CHARCELLS
668 INT_SETTING(0, jump_scroll
, LANG_JUMP_SCROLL
, 0, "jump scroll", UNIT_INT
, 0,
669 5, 1, jumpscroll_format
, jumpscroll_getlang
, lcd_jump_scroll
),
670 INT_SETTING(0, jump_scroll_delay
, LANG_JUMP_SCROLL_DELAY
, 500,
671 "jump scroll delay", UNIT_MS
, 0, 2500, 100, NULL
, NULL
,
672 lcd_jump_scroll_delay
),
674 OFFON_SETTING(0,scroll_paginated
,LANG_SCROLL_PAGINATED
,
675 false,"scroll paginated",NULL
),
676 #ifdef HAVE_LCD_COLOR
678 {F_T_INT
|F_RGB
|F_THEMESETTING
,&global_settings
.fg_color
,-1,
679 INT(DEFAULT_THEME_FOREGROUND
),"foreground color",NULL
,UNUSED
},
680 {F_T_INT
|F_RGB
|F_THEMESETTING
,&global_settings
.bg_color
,-1,
681 INT(DEFAULT_THEME_BACKGROUND
),"background color",NULL
,UNUSED
},
682 {F_T_INT
|F_RGB
|F_THEMESETTING
,&global_settings
.lss_color
,-1,
683 INT(DEFAULT_THEME_SELECTOR_START
),"line selector start color",NULL
,
685 {F_T_INT
|F_RGB
|F_THEMESETTING
,&global_settings
.lse_color
,-1,
686 INT(DEFAULT_THEME_SELECTOR_END
),"line selector end color",NULL
,UNUSED
},
687 {F_T_INT
|F_RGB
|F_THEMESETTING
,&global_settings
.lst_color
,-1,
688 INT(DEFAULT_THEME_SELECTOR_TEXT
),"line selector text color",NULL
,
693 OFFON_SETTING(0,play_selected
,LANG_PLAY_SELECTED
,true,"play selected",NULL
),
694 OFFON_SETTING(0,party_mode
,LANG_PARTY_MODE
,false,"party mode",NULL
),
695 OFFON_SETTING(0,fade_on_stop
,LANG_FADE_ON_STOP
,true,"volume fade",NULL
),
696 TABLE_SETTING(F_ALLOW_ARBITRARY_VALS
, ff_rewind_min_step
,
697 LANG_FFRW_STEP
, 1, "scan min step", NULL
, UNIT_SEC
,
698 NULL
, NULL
, NULL
, 14, 1,2,3,4,5,6,8,10,15,20,25,30,45,60),
699 CHOICE_SETTING(0, ff_rewind_accel
, LANG_FFRW_ACCEL
, 2,
700 "seek acceleration", "very fast,fast,normal,slow,very slow", NULL
, 5,
701 ID2P(LANG_VERY_FAST
), ID2P(LANG_FAST
), ID2P(LANG_NORMAL
),
702 ID2P(LANG_SLOW
) , ID2P(LANG_VERY_SLOW
)),
703 #if (CONFIG_CODEC == SWCODEC) && defined(HAVE_DISK_STORAGE)
704 STRINGCHOICE_SETTING(0, buffer_margin
, LANG_MP3BUFFER_MARGIN
, 0,"antiskip",
705 "5s,15s,30s,1min,2min,3min,5min,10min", NULL
, 8,
706 TALK_ID(5, UNIT_SEC
), TALK_ID(15, UNIT_SEC
),
707 TALK_ID(30, UNIT_SEC
), TALK_ID(1, UNIT_MIN
),
708 TALK_ID(2, UNIT_MIN
), TALK_ID(3, UNIT_MIN
),
709 TALK_ID(5, UNIT_MIN
), TALK_ID(10, UNIT_MIN
)),
710 #elif defined(HAVE_DISK_STORAGE)
711 INT_SETTING(0, buffer_margin
, LANG_MP3BUFFER_MARGIN
, 0, "antiskip",
712 UNIT_SEC
, 0, 7, 1, NULL
, NULL
, audio_set_buffer_margin
),
715 #ifdef HAVE_DISK_STORAGE
716 INT_SETTING(0, disk_spindown
, LANG_SPINDOWN
, 5, "disk spindown",
717 UNIT_SEC
, 3, 254, 1, NULL
, NULL
, ata_spindown
),
718 #endif /* HAVE_DISK_STORAGE */
720 CHOICE_SETTING(0, dirfilter
, LANG_FILTER
, SHOW_SUPPORTED
, "show files",
721 "all,supported,music,playlists", NULL
, 4, ID2P(LANG_ALL
),
722 ID2P(LANG_FILTER_SUPPORTED
), ID2P(LANG_FILTER_MUSIC
),
723 ID2P(LANG_PLAYLISTS
)),
724 OFFON_SETTING(0, sort_case
, LANG_SORT_CASE
, false, "sort case", NULL
),
725 CHOICE_SETTING(0, show_filename_ext
, LANG_SHOW_FILENAME_EXT
, 3,
726 "show filename exts", "off,on,unknown,view_all", NULL
, 4 ,
727 ID2P(LANG_OFF
), ID2P(LANG_ON
), ID2P(LANG_UNKNOWN_TYPES
),
728 ID2P(LANG_EXT_ONLY_VIEW_ALL
)),
729 OFFON_SETTING(0,browse_current
,LANG_FOLLOW
,false,"follow playlist",NULL
),
730 OFFON_SETTING(0,playlist_viewer_icons
,LANG_SHOW_ICONS
,true,
731 "playlist viewer icons",NULL
),
732 OFFON_SETTING(0,playlist_viewer_indices
,LANG_SHOW_INDICES
,true,
733 "playlist viewer indices",NULL
),
734 CHOICE_SETTING(0, playlist_viewer_track_display
, LANG_TRACK_DISPLAY
, 0,
735 "playlist viewer track display","track name,full path",
736 NULL
, 2, ID2P(LANG_DISPLAY_TRACK_NAME_ONLY
),
737 ID2P(LANG_DISPLAY_FULL_PATH
)),
738 CHOICE_SETTING(0, recursive_dir_insert
, LANG_RECURSE_DIRECTORY
, RECURSE_ON
,
739 "recursive directory insert", off_on_ask
, NULL
, 3 ,
740 ID2P(LANG_OFF
), ID2P(LANG_ON
), ID2P(LANG_ASK
)),
742 CHOICE_SETTING(0, autocreatebookmark
, LANG_BOOKMARK_SETTINGS_AUTOCREATE
,
743 BOOKMARK_NO
, "autocreate bookmarks",
744 "off,on,ask,recent only - on,recent only - ask", NULL
, 5,
745 ID2P(LANG_SET_BOOL_NO
), ID2P(LANG_SET_BOOL_YES
),
746 ID2P(LANG_ASK
), ID2P(LANG_BOOKMARK_SETTINGS_RECENT_ONLY_YES
),
747 ID2P(LANG_BOOKMARK_SETTINGS_RECENT_ONLY_ASK
)),
748 CHOICE_SETTING(0, autoloadbookmark
, LANG_BOOKMARK_SETTINGS_AUTOLOAD
,
749 BOOKMARK_NO
, "autoload bookmarks", off_on_ask
, NULL
, 3,
750 ID2P(LANG_SET_BOOL_NO
), ID2P(LANG_SET_BOOL_YES
),
752 CHOICE_SETTING(0, usemrb
, LANG_BOOKMARK_SETTINGS_MAINTAIN_RECENT_BOOKMARKS
,
753 BOOKMARK_NO
, "use most-recent-bookmarks",
754 "off,on,unique only", NULL
, 3, ID2P(LANG_SET_BOOL_NO
),
755 ID2P(LANG_SET_BOOL_YES
),
756 ID2P(LANG_BOOKMARK_SETTINGS_UNIQUE_ONLY
)),
757 #ifdef HAVE_LCD_BITMAP
759 STRINGCHOICE_SETTING(0, peak_meter_clip_hold
, LANG_PM_CLIP_HOLD
, 16,
760 "peak meter clip hold",
761 "on,1,2,3,4,5,6,7,8,9,10,15,20,25,30,45,60,90,2min"
762 ",3min,5min,10min,20min,45min,90min",
763 peak_meter_set_clip_hold
, 25, LANG_PM_ETERNAL
,
764 TALK_ID(1, UNIT_SEC
), TALK_ID(2, UNIT_SEC
),
765 TALK_ID(3, UNIT_SEC
), TALK_ID(4, UNIT_SEC
),
766 TALK_ID(5, UNIT_SEC
), TALK_ID(6, UNIT_SEC
),
767 TALK_ID(7, UNIT_SEC
), TALK_ID(8, UNIT_SEC
),
768 TALK_ID(9, UNIT_SEC
), TALK_ID(10, UNIT_SEC
),
769 TALK_ID(15, UNIT_SEC
), TALK_ID(20, UNIT_SEC
),
770 TALK_ID(25, UNIT_SEC
), TALK_ID(30, UNIT_SEC
),
771 TALK_ID(45, UNIT_SEC
), TALK_ID(60, UNIT_SEC
),
772 TALK_ID(90, UNIT_SEC
), TALK_ID(2, UNIT_MIN
),
773 TALK_ID(3, UNIT_MIN
), TALK_ID(5, UNIT_MIN
),
774 TALK_ID(10, UNIT_MIN
), TALK_ID(20, UNIT_MIN
),
775 TALK_ID(45, UNIT_MIN
), TALK_ID(90, UNIT_MIN
)),
776 STRINGCHOICE_SETTING(0, peak_meter_hold
, LANG_PM_PEAK_HOLD
, 3,
778 "off,200ms,300ms,500ms,1,2,3,4,5,6,7,8,9,10,15,20,30,1min",
779 NULL
, 18, LANG_OFF
, TALK_ID(200, UNIT_MS
),
780 TALK_ID(300, UNIT_MS
), TALK_ID(500, UNIT_MS
),
781 TALK_ID(1, UNIT_SEC
), TALK_ID(2, UNIT_SEC
),
782 TALK_ID(3, UNIT_SEC
), TALK_ID(4, UNIT_SEC
),
783 TALK_ID(5, UNIT_SEC
), TALK_ID(6, UNIT_SEC
),
784 TALK_ID(7, UNIT_SEC
), TALK_ID(8, UNIT_SEC
),
785 TALK_ID(9, UNIT_SEC
), TALK_ID(10, UNIT_SEC
),
786 TALK_ID(15, UNIT_SEC
), TALK_ID(20, UNIT_SEC
),
787 TALK_ID(30, UNIT_SEC
), TALK_ID(60, UNIT_SEC
)),
788 INT_SETTING(0, peak_meter_release
, LANG_PM_RELEASE
, 8, "peak meter release",
789 UNIT_PM_TICK
, 1, 0x7e, 1, NULL
, NULL
,NULL
),
790 OFFON_SETTING(0,peak_meter_dbfs
,LANG_PM_DBFS
,true,"peak meter dbfs",NULL
),
791 {F_T_INT
, &global_settings
.peak_meter_min
, LANG_PM_MIN
,INT(60),
792 "peak meter min", NULL
, UNUSED
},
793 {F_T_INT
, &global_settings
.peak_meter_max
, LANG_PM_MAX
,INT(0),
794 "peak meter max", NULL
, UNUSED
},
795 #ifdef HAVE_RECORDING
796 OFFON_SETTING(0, peak_meter_clipcounter
, LANG_PM_CLIPCOUNTER
, false,
797 "peak meter clipcounter", NULL
),
798 #endif /* HAVE_RECORDING */
799 #endif /* HAVE_LCD_BITMAP */
800 #if (CONFIG_CODEC == MAS3587F) || (CONFIG_CODEC == MAS3539F)
801 SOUND_SETTING(F_SOUNDSETTING
, mdb_strength
, LANG_MDB_STRENGTH
,
802 "mdb strength", SOUND_MDB_STRENGTH
),
803 SOUND_SETTING(F_SOUNDSETTING
, mdb_harmonics
, LANG_MDB_HARMONICS
,
804 "mdb harmonics", SOUND_MDB_HARMONICS
),
805 SOUND_SETTING(F_SOUNDSETTING
, mdb_center
, LANG_MDB_CENTER
,
806 "mdb center", SOUND_MDB_CENTER
),
807 SOUND_SETTING(F_SOUNDSETTING
, mdb_shape
, LANG_MDB_SHAPE
,
808 "mdb shape", SOUND_MDB_SHAPE
),
809 OFFON_SETTING(F_SOUNDSETTING
, mdb_enable
, LANG_MDB_ENABLE
,
810 false, "mdb enable", set_mdb_enable
),
812 #if CONFIG_CODEC == MAS3507D
813 OFFON_SETTING(F_SOUNDSETTING
, line_in
,LANG_LINE_IN
,false,"line in",NULL
),
816 OFFON_SETTING(F_TEMPVAR
, talk_menu
, LANG_VOICE_MENU
, true, "talk menu", NULL
),
817 CHOICE_SETTING(0, talk_dir
, LANG_VOICE_DIR
, 0,
818 "talk dir", off_number_spell
, NULL
, 3,
819 ID2P(LANG_OFF
), ID2P(LANG_VOICE_NUMBER
),
820 ID2P(LANG_VOICE_SPELL
)),
821 OFFON_SETTING(F_TEMPVAR
, talk_dir_clip
, LANG_VOICE_DIR_TALK
, false,
822 "talk dir clip", NULL
),
823 CHOICE_SETTING(0, talk_file
, LANG_VOICE_FILE
, 0,
824 "talk file", off_number_spell
, NULL
, 3,
825 ID2P(LANG_OFF
), ID2P(LANG_VOICE_NUMBER
),
826 ID2P(LANG_VOICE_SPELL
)),
827 OFFON_SETTING(F_TEMPVAR
, talk_file_clip
, LANG_VOICE_FILE_TALK
, false,
828 "talk file clip", NULL
),
829 OFFON_SETTING(F_TEMPVAR
, talk_filetype
, LANG_VOICE_FILETYPE
, false,
830 "talk filetype", NULL
),
831 OFFON_SETTING(F_TEMPVAR
, talk_battery_level
, LANG_TALK_BATTERY_LEVEL
, false,
832 "Announce Battery Level", NULL
),
835 CHOICE_SETTING(0, sort_file
, LANG_SORT_FILE
, 0 ,
836 "sort files", "alpha,oldest,newest,type", NULL
, 4,
837 ID2P(LANG_SORT_ALPHA
), ID2P(LANG_SORT_DATE
),
838 ID2P(LANG_SORT_DATE_REVERSE
) , ID2P(LANG_SORT_TYPE
)),
839 CHOICE_SETTING(0, sort_dir
, LANG_SORT_DIR
, 0 ,
840 "sort dirs", "alpha,oldest,newest", NULL
, 3,
841 ID2P(LANG_SORT_ALPHA
), ID2P(LANG_SORT_DATE
),
842 ID2P(LANG_SORT_DATE_REVERSE
)),
844 #ifdef HAVE_RECORDING
846 STRINGCHOICE_SETTING(F_RECSETTING
, rec_timesplit
, LANG_SPLIT_TIME
, 0,
848 "off,00:05,00:10,00:15,00:30,01:00,01:14,01:20,02:00,"
849 "04:00,06:00,08:00,10:00,12:00,18:00,24:00",
851 TALK_ID(5, UNIT_MIN
), TALK_ID(10, UNIT_MIN
),
852 TALK_ID(15, UNIT_MIN
), TALK_ID(30, UNIT_MIN
),
853 TALK_ID(60, UNIT_MIN
), TALK_ID(74, UNIT_MIN
),
854 TALK_ID(80, UNIT_MIN
), TALK_ID(2, UNIT_HOUR
),
855 TALK_ID(4, UNIT_HOUR
), TALK_ID(6, UNIT_HOUR
),
856 TALK_ID(8, UNIT_HOUR
), TALK_ID(10, UNIT_HOUR
),
857 TALK_ID(12, UNIT_HOUR
), TALK_ID(18, UNIT_HOUR
),
858 TALK_ID(20, UNIT_HOUR
), TALK_ID(24, UNIT_HOUR
)),
859 STRINGCHOICE_SETTING(F_RECSETTING
, rec_sizesplit
, LANG_SPLIT_SIZE
, 0,
861 "off,5MB,10MB,15MB,32MB,64MB,75MB,100MB,128MB,"
862 "256MB,512MB,650MB,700MB,1GB,1.5GB,1.75GB",
864 TALK_ID(5, UNIT_MB
), TALK_ID(10, UNIT_MB
),
865 TALK_ID(15, UNIT_MB
), TALK_ID(32, UNIT_MB
),
866 TALK_ID(64, UNIT_MB
), TALK_ID(75, UNIT_MB
),
867 TALK_ID(100, UNIT_MB
), TALK_ID(128, UNIT_MB
),
868 TALK_ID(256, UNIT_MB
), TALK_ID(512, UNIT_MB
),
869 TALK_ID(650, UNIT_MB
), TALK_ID(700, UNIT_MB
),
870 TALK_ID(1024, UNIT_MB
), TALK_ID(1536, UNIT_MB
),
871 TALK_ID(1792, UNIT_MB
)),
872 {F_T_INT
|F_RECSETTING
, &global_settings
.rec_channels
, LANG_CHANNELS
, INT(0),
873 "rec channels","stereo,mono",UNUSED
},
874 #if CONFIG_CODEC == SWCODEC
875 {F_T_INT
|F_RECSETTING
, &global_settings
.rec_mono_mode
,
876 LANG_RECORDING_MONO_MODE
, INT(0), "rec mono mode","L+R,L,R",UNUSED
},
878 CHOICE_SETTING(F_RECSETTING
, rec_split_type
, LANG_SPLIT_TYPE
, 0,
879 "rec split type", "Split,Stop,Shutdown", NULL
, 3,
880 ID2P(LANG_START_NEW_FILE
), ID2P(LANG_STOP_RECORDING
),ID2P(LANG_STOP_RECORDING_AND_SHUTDOWN
)),
881 CHOICE_SETTING(F_RECSETTING
, rec_split_method
, LANG_SPLIT_MEASURE
, 0,
882 "rec split method", "Time,Filesize", NULL
, 2,
883 ID2P(LANG_TIME
), ID2P(LANG_REC_SIZE
)),
884 {F_T_INT
|F_RECSETTING
, &global_settings
.rec_source
, LANG_RECORDING_SOURCE
,
885 INT(0), "rec source",
886 &HAVE_MIC_REC_(",mic")
887 HAVE_LINE_REC_(",line")
888 HAVE_SPDIF_REC_(",spdif")
889 HAVE_FMRADIO_REC_(",fmradio")[1],
891 INT_SETTING(F_RECSETTING
, rec_prerecord_time
, LANG_RECORD_PRERECORD_TIME
, 0,
892 "prerecording time", UNIT_SEC
, 0, 30, 1,
893 formatter_unit_0_is_off
, getlang_unit_0_is_off
, NULL
),
895 TEXT_SETTING(F_RECSETTING
, rec_directory
, "rec path",
896 REC_BASE_DIR
, NULL
, NULL
),
897 #ifdef HAVE_BACKLIGHT
898 CHOICE_SETTING(F_RECSETTING
, cliplight
, LANG_CLIP_LIGHT
, 0,
899 "cliplight", "off,main,both,remote", NULL
,
900 #ifdef HAVE_REMOTE_LCD
901 4, ID2P(LANG_OFF
), ID2P(LANG_MAIN_UNIT
),
902 ID2P(LANG_REMOTE_MAIN
), ID2P(LANG_REMOTE_UNIT
)
904 2, ID2P(LANG_OFF
), ID2P(LANG_ON
)
908 #ifdef DEFAULT_REC_MIC_GAIN
909 {F_T_INT
|F_RECSETTING
,&global_settings
.rec_mic_gain
,
910 LANG_GAIN
,INT(DEFAULT_REC_MIC_GAIN
),
911 "rec mic gain",NULL
,UNUSED
},
912 #endif /* DEFAULT_REC_MIC_GAIN */
913 #ifdef DEFAULT_REC_LEFT_GAIN
914 {F_T_INT
|F_RECSETTING
,&global_settings
.rec_left_gain
,
915 LANG_GAIN_LEFT
,INT(DEFAULT_REC_LEFT_GAIN
),
916 "rec left gain",NULL
,UNUSED
},
917 #endif /* DEFAULT_REC_LEFT_GAIN */
918 #ifdef DEFAULT_REC_RIGHT_GAIN
919 {F_T_INT
|F_RECSETTING
,&global_settings
.rec_right_gain
,LANG_GAIN_RIGHT
,
920 INT(DEFAULT_REC_RIGHT_GAIN
),
921 "rec right gain",NULL
,UNUSED
},
922 #endif /* DEFAULT_REC_RIGHT_GAIN */
923 #if CONFIG_CODEC == MAS3587F
924 {F_T_INT
|F_RECSETTING
,&global_settings
.rec_frequency
,
925 LANG_RECORDING_FREQUENCY
, INT(0),
926 "rec frequency","44,48,32,22,24,16", UNUSED
},
927 INT_SETTING(F_RECSETTING
, rec_quality
, LANG_RECORDING_QUALITY
, 5,
928 "rec quality", UNIT_INT
, 0, 7, 1, NULL
, NULL
, NULL
),
929 OFFON_SETTING(F_RECSETTING
, rec_editable
, LANG_RECORDING_EDITABLE
, false,
930 "editable recordings", NULL
),
931 #endif /* CONFIG_CODEC == MAS3587F */
932 #if CONFIG_CODEC == SWCODEC
933 {F_T_INT
|F_RECSETTING
,&global_settings
.rec_frequency
,
934 LANG_RECORDING_FREQUENCY
,INT(REC_FREQ_DEFAULT
),
935 "rec frequency",REC_FREQ_CFG_VAL_LIST
,UNUSED
},
936 {F_T_INT
|F_RECSETTING
,&global_settings
.rec_format
,
937 LANG_RECORDING_FORMAT
,INT(REC_FORMAT_DEFAULT
),
938 "rec format",REC_FORMAT_CFG_VAL_LIST
,UNUSED
},
939 /** Encoder settings start - keep these together **/
941 /* (no settings yet) */
943 {F_T_INT
|F_RECSETTING
, &global_settings
.mp3_enc_config
.bitrate
,-1,
944 INT(MP3_ENC_BITRATE_CFG_DEFAULT
),
945 "mp3_enc bitrate",MP3_ENC_BITRATE_CFG_VALUE_LIST
,UNUSED
},
947 /* (no settings yet) */
949 /* (no settings yet) */
950 /** Encoder settings end **/
951 #endif /* CONFIG_CODEC == SWCODEC */
952 /* values for the trigger */
953 INT_SETTING(F_RECSETTING
, rec_start_thres_db
, LANG_RECORD_START_THRESHOLD
, -35,
954 "trigger start threshold dB", UNIT_DB
, VOLUME_MIN
/10, 0, -1, NULL
, NULL
, NULL
),
955 INT_SETTING(F_RECSETTING
, rec_start_thres_linear
, LANG_RECORD_START_THRESHOLD
, 5,
956 "trigger start threshold linear", UNIT_PERCENT
, 0, 100, 1, NULL
, NULL
, NULL
),
957 INT_SETTING(F_RECSETTING
, rec_stop_thres_db
, LANG_RECORD_STOP_THRESHOLD
, -45,
958 "trigger stop threshold dB", UNIT_DB
, VOLUME_MIN
/10, 0, -1, NULL
, NULL
, NULL
),
959 INT_SETTING(F_RECSETTING
, rec_stop_thres_linear
, LANG_RECORD_STOP_THRESHOLD
, 10,
960 "trigger stop threshold linear", UNIT_PERCENT
, 0, 100, 1, NULL
, NULL
, NULL
),
961 TABLE_SETTING(F_RECSETTING
, rec_start_duration
, LANG_MIN_DURATION
, 0,
962 "trigger start duration",
963 "0s,1s,2s,5s,10s,15s,20s,25s,30s,1min,2min,5min,10min",
964 UNIT_SEC
, NULL
, NULL
, NULL
, 13,
965 0,1,2,5,10,15,20,25,30,60,120,300,600),
966 TABLE_SETTING(F_RECSETTING
, rec_stop_postrec
, LANG_MIN_DURATION
, 0,
967 "trigger stop duration",
968 "0s,1s,2s,5s,10s,15s,20s,25s,30s,1min,2min,5min,10min",
969 UNIT_SEC
, NULL
, NULL
, NULL
, 13,
970 0,1,2,5,10,15,20,25,30,60,120,300,600),
971 TABLE_SETTING(F_RECSETTING
, rec_stop_gap
, LANG_RECORD_STOP_GAP
, 1,
973 "0s,1s,2s,5s,10s,15s,20s,25s,30s,1min,2min,5min,10min",
974 UNIT_SEC
, NULL
, NULL
, NULL
, 13,
975 0,1,2,5,10,15,20,25,30,60,120,300,600),
976 CHOICE_SETTING(F_RECSETTING
, rec_trigger_mode
, LANG_RECORD_TRIGGER
, TRIG_MODE_OFF
,
977 "trigger mode","off,once,repeat", NULL
,3,
978 ID2P(LANG_OFF
), ID2P(LANG_RECORD_TRIG_NOREARM
), ID2P(LANG_REPEAT
)),
979 CHOICE_SETTING(F_RECSETTING
, rec_trigger_type
, LANG_RECORD_TRIGGER_TYPE
, TRIG_TYPE_STOP
,
980 "trigger type","stop,pause,nf stp", NULL
,3,
981 ID2P(LANG_RECORD_TRIGGER_STOP
), ID2P(LANG_PAUSE
), ID2P(LANG_RECORD_TRIGGER_NEWFILESTP
)),
982 #endif /* HAVE_RECORDING */
984 #ifdef HAVE_SPDIF_POWER
985 OFFON_SETTING(F_SOUNDSETTING
, spdif_enable
, LANG_SPDIF_ENABLE
, false,
986 "spdif enable", spdif_power_enable
),
988 CHOICE_SETTING(0, next_folder
, LANG_NEXT_FOLDER
, FOLDER_ADVANCE_OFF
,
989 "folder navigation", "off,on,random",NULL
,3,
990 ID2P(LANG_SET_BOOL_NO
), ID2P(LANG_SET_BOOL_YES
),
992 OFFON_SETTING(0, runtimedb
, LANG_RUNTIMEDB_ACTIVE
, false,
993 "gather runtime data", NULL
),
995 #if CONFIG_CODEC == SWCODEC
997 OFFON_SETTING(F_SOUNDSETTING
, replaygain
, LANG_REPLAYGAIN_ENABLE
, false,
999 CHOICE_SETTING(F_SOUNDSETTING
, replaygain_type
, LANG_REPLAYGAIN_MODE
,
1000 REPLAYGAIN_ALBUM
, "replaygain type",
1001 "track,album,track shuffle", NULL
, 3, ID2P(LANG_TRACK_GAIN
),
1002 ID2P(LANG_ALBUM_GAIN
), ID2P(LANG_SHUFFLE_GAIN
)),
1003 OFFON_SETTING(F_SOUNDSETTING
, replaygain_noclip
, LANG_REPLAYGAIN_NOCLIP
,
1004 false, "replaygain noclip", NULL
),
1005 INT_SETTING_NOWRAP(F_SOUNDSETTING
, replaygain_preamp
,
1006 LANG_REPLAYGAIN_PREAMP
, 0, "replaygain preamp",
1007 UNIT_DB
, -120, 120, 5, db_format
, get_dec_talkid
, NULL
),
1009 CHOICE_SETTING(0, beep
, LANG_BEEP
, 0, "beep", "off,weak,moderate,strong",
1010 NULL
, 4, ID2P(LANG_OFF
), ID2P(LANG_WEAK
),
1011 ID2P(LANG_MODERATE
), ID2P(LANG_STRONG
)),
1014 CHOICE_SETTING(F_SOUNDSETTING
, crossfade
, LANG_CROSSFADE_ENABLE
, 0,
1016 "off,shuffle,track skip,shuffle and track skip,always", NULL
,
1017 5, ID2P(LANG_OFF
), ID2P(LANG_SHUFFLE
), ID2P(LANG_TRACKSKIP
),
1018 ID2P(LANG_SHUFFLE_TRACKSKIP
), ID2P(LANG_ALWAYS
)),
1019 INT_SETTING(F_SOUNDSETTING
, crossfade_fade_in_delay
,
1020 LANG_CROSSFADE_FADE_IN_DELAY
, 0,
1021 "crossfade fade in delay", UNIT_SEC
, 0, 7, 1, NULL
, NULL
, NULL
),
1022 INT_SETTING(F_SOUNDSETTING
, crossfade_fade_out_delay
,
1023 LANG_CROSSFADE_FADE_OUT_DELAY
, 0,
1024 "crossfade fade out delay", UNIT_SEC
, 0, 7, 1, NULL
, NULL
,NULL
),
1025 INT_SETTING(F_SOUNDSETTING
, crossfade_fade_in_duration
,
1026 LANG_CROSSFADE_FADE_IN_DURATION
, 2,
1027 "crossfade fade in duration", UNIT_SEC
, 0, 15, 1, NULL
, NULL
,
1029 INT_SETTING(F_SOUNDSETTING
, crossfade_fade_out_duration
,
1030 LANG_CROSSFADE_FADE_OUT_DURATION
, 2,
1031 "crossfade fade out duration", UNIT_SEC
, 0, 15, 1, NULL
, NULL
,
1033 CHOICE_SETTING(F_SOUNDSETTING
, crossfade_fade_out_mixmode
,
1034 LANG_CROSSFADE_FADE_OUT_MODE
, 0,
1035 "crossfade fade out mode", "crossfade,mix", NULL
, 2,
1036 ID2P(LANG_CROSSFADE
), ID2P(LANG_MIX
)),
1039 OFFON_SETTING(F_SOUNDSETTING
, crossfeed
, LANG_CROSSFEED
, false,
1040 "crossfeed", dsp_set_crossfeed
),
1041 INT_SETTING_NOWRAP(F_SOUNDSETTING
, crossfeed_direct_gain
,
1042 LANG_CROSSFEED_DIRECT_GAIN
, -15,
1043 "crossfeed direct gain", UNIT_DB
, -60, 0, 5,
1044 db_format
, get_dec_talkid
,dsp_set_crossfeed_direct_gain
),
1045 INT_SETTING_NOWRAP(F_SOUNDSETTING
, crossfeed_cross_gain
,
1046 LANG_CROSSFEED_CROSS_GAIN
, -60,
1047 "crossfeed cross gain", UNIT_DB
, -120, -30, 5,
1048 db_format
, get_dec_talkid
, crossfeed_cross_set
),
1049 INT_SETTING_NOWRAP(F_SOUNDSETTING
, crossfeed_hf_attenuation
,
1050 LANG_CROSSFEED_HF_ATTENUATION
, -160,
1051 "crossfeed hf attenuation", UNIT_DB
, -240, -60, 5,
1052 db_format
, get_dec_talkid
, crossfeed_cross_set
),
1053 INT_SETTING_NOWRAP(F_SOUNDSETTING
, crossfeed_hf_cutoff
,
1054 LANG_CROSSFEED_HF_CUTOFF
, 700,
1055 "crossfeed hf cutoff", UNIT_HERTZ
, 500, 2000, 100,
1056 NULL
, NULL
, crossfeed_cross_set
),
1059 OFFON_SETTING(F_EQSETTING
, eq_enabled
, LANG_EQUALIZER_ENABLED
, false,
1060 "eq enabled", NULL
),
1061 INT_SETTING_NOWRAP(F_EQSETTING
, eq_precut
, LANG_EQUALIZER_PRECUT
, 0,
1062 "eq precut", UNIT_DB
, 0, 240, 5, eq_precut_format
,
1063 get_precut_talkid
, dsp_set_eq_precut
),
1065 INT_SETTING_NOWRAP(F_EQSETTING
, eq_band0_cutoff
, LANG_EQUALIZER_BAND_CUTOFF
,
1066 60, "eq band 0 cutoff", UNIT_HERTZ
, EQ_CUTOFF_MIN
,
1067 EQ_CUTOFF_MAX
, EQ_CUTOFF_STEP
, NULL
, NULL
, NULL
),
1068 INT_SETTING_NOWRAP(F_EQSETTING
, eq_band1_cutoff
, LANG_EQUALIZER_BAND_CENTER
,
1069 200, "eq band 1 cutoff", UNIT_HERTZ
, EQ_CUTOFF_MIN
,
1070 EQ_CUTOFF_MAX
, EQ_CUTOFF_STEP
, NULL
, NULL
, NULL
),
1071 INT_SETTING_NOWRAP(F_EQSETTING
, eq_band2_cutoff
, LANG_EQUALIZER_BAND_CENTER
,
1072 800, "eq band 2 cutoff", UNIT_HERTZ
, EQ_CUTOFF_MIN
,
1073 EQ_CUTOFF_MAX
, EQ_CUTOFF_STEP
, NULL
, NULL
, NULL
),
1074 INT_SETTING_NOWRAP(F_EQSETTING
, eq_band3_cutoff
, LANG_EQUALIZER_BAND_CENTER
,
1075 4000, "eq band 3 cutoff", UNIT_HERTZ
, EQ_CUTOFF_MIN
,
1076 EQ_CUTOFF_MAX
, EQ_CUTOFF_STEP
, NULL
, NULL
, NULL
),
1077 INT_SETTING_NOWRAP(F_EQSETTING
, eq_band4_cutoff
, LANG_EQUALIZER_BAND_CUTOFF
,
1078 12000, "eq band 4 cutoff", UNIT_HERTZ
, EQ_CUTOFF_MIN
,
1079 EQ_CUTOFF_MAX
, EQ_CUTOFF_STEP
, NULL
, NULL
, NULL
),
1080 /* 0..64 (or 0.0 to 6.4) */
1081 INT_SETTING_NOWRAP(F_EQSETTING
, eq_band0_q
, LANG_EQUALIZER_BAND_Q
, 7,
1082 "eq band 0 q", UNIT_INT
, EQ_Q_MIN
, EQ_Q_MAX
, EQ_Q_STEP
,
1083 eq_q_format
, get_dec_talkid
, NULL
),
1084 INT_SETTING_NOWRAP(F_EQSETTING
, eq_band1_q
, LANG_EQUALIZER_BAND_Q
, 10,
1085 "eq band 1 q", UNIT_INT
, EQ_Q_MIN
, EQ_Q_MAX
, EQ_Q_STEP
,
1086 eq_q_format
, get_dec_talkid
, NULL
),
1087 INT_SETTING_NOWRAP(F_EQSETTING
, eq_band2_q
, LANG_EQUALIZER_BAND_Q
, 10,
1088 "eq band 2 q", UNIT_INT
, EQ_Q_MIN
, EQ_Q_MAX
, EQ_Q_STEP
,
1089 eq_q_format
, get_dec_talkid
, NULL
),
1090 INT_SETTING_NOWRAP(F_EQSETTING
, eq_band3_q
, LANG_EQUALIZER_BAND_Q
, 10,
1091 "eq band 3 q", UNIT_INT
, EQ_Q_MIN
, EQ_Q_MAX
, EQ_Q_STEP
,
1092 eq_q_format
, get_dec_talkid
, NULL
),
1093 INT_SETTING_NOWRAP(F_EQSETTING
, eq_band4_q
, LANG_EQUALIZER_BAND_Q
, 7,
1094 "eq band 4 q", UNIT_INT
, EQ_Q_MIN
, EQ_Q_MAX
, EQ_Q_STEP
,
1095 eq_q_format
, get_dec_talkid
, NULL
),
1096 /* -240..240 (or -24db to +24db) */
1097 INT_SETTING_NOWRAP(F_EQSETTING
, eq_band0_gain
, LANG_GAIN
, 0,
1098 "eq band 0 gain", UNIT_DB
, EQ_GAIN_MIN
, EQ_GAIN_MAX
,
1099 EQ_GAIN_STEP
, db_format
, get_dec_talkid
, NULL
),
1100 INT_SETTING_NOWRAP(F_EQSETTING
, eq_band1_gain
, LANG_GAIN
, 0,
1101 "eq band 1 gain", UNIT_DB
, EQ_GAIN_MIN
, EQ_GAIN_MAX
,
1102 EQ_GAIN_STEP
, db_format
, get_dec_talkid
, NULL
),
1103 INT_SETTING_NOWRAP(F_EQSETTING
, eq_band2_gain
, LANG_GAIN
, 0,
1104 "eq band 2 gain", UNIT_DB
, EQ_GAIN_MIN
, EQ_GAIN_MAX
,
1105 EQ_GAIN_STEP
, db_format
, get_dec_talkid
, NULL
),
1106 INT_SETTING_NOWRAP(F_EQSETTING
, eq_band3_gain
, LANG_GAIN
, 0,
1107 "eq band 3 gain", UNIT_DB
, EQ_GAIN_MIN
, EQ_GAIN_MAX
,
1108 EQ_GAIN_STEP
, db_format
, get_dec_talkid
, NULL
),
1109 INT_SETTING_NOWRAP(F_EQSETTING
, eq_band4_gain
, LANG_GAIN
, 0,
1110 "eq band 4 gain", UNIT_DB
, EQ_GAIN_MIN
, EQ_GAIN_MAX
,
1111 EQ_GAIN_STEP
, db_format
, get_dec_talkid
, NULL
),
1114 OFFON_SETTING(F_SOUNDSETTING
, dithering_enabled
, LANG_DITHERING
, false,
1115 "dithering enabled", dsp_dither_enable
),
1118 SOUND_SETTING(F_NO_WRAP
, bass_cutoff
, LANG_BASS_CUTOFF
,
1119 "bass cutoff", SOUND_BASS_CUTOFF
),
1120 SOUND_SETTING(F_NO_WRAP
, treble_cutoff
, LANG_TREBLE_CUTOFF
,
1121 "treble cutoff", SOUND_TREBLE_CUTOFF
),
1123 #ifdef HAVE_DIRCACHE
1124 OFFON_SETTING(0,dircache
,LANG_DIRCACHE_ENABLE
,false,"dircache",NULL
),
1125 SYSTEM_SETTING(NVRAM(4),dircache_size
,0),
1128 #ifdef HAVE_TAGCACHE
1129 #ifdef HAVE_TC_RAMCACHE
1130 OFFON_SETTING(0,tagcache_ram
,LANG_TAGCACHE_RAM
,false,"tagcache_ram",NULL
),
1132 OFFON_SETTING(0, tagcache_autoupdate
, LANG_TAGCACHE_AUTOUPDATE
, false,
1133 "tagcache_autoupdate", NULL
),
1135 CHOICE_SETTING(0, default_codepage
, LANG_DEFAULT_CODEPAGE
, 0,
1137 #ifdef HAVE_LCD_BITMAP
1138 /* The order must match with that in unicode.c */
1139 "iso8859-1,iso8859-7,iso8859-8,cp1251,iso8859-11,cp1256,"
1140 "iso8859-9,iso8859-2,cp1250,sjis,gb2312,ksx1001,big5,utf-8",
1142 ID2P(LANG_CODEPAGE_LATIN1
), ID2P(LANG_CODEPAGE_GREEK
),
1143 ID2P(LANG_CODEPAGE_HEBREW
), ID2P(LANG_CODEPAGE_CYRILLIC
),
1144 ID2P(LANG_CODEPAGE_THAI
), ID2P(LANG_CODEPAGE_ARABIC
),
1145 ID2P(LANG_CODEPAGE_TURKISH
),
1146 ID2P(LANG_CODEPAGE_LATIN_EXTENDED
),
1147 ID2P(LANG_CODEPAGE_CENTRAL_EUROPEAN
),
1148 ID2P(LANG_CODEPAGE_JAPANESE
),
1149 ID2P(LANG_CODEPAGE_SIMPLIFIED
), ID2P(LANG_CODEPAGE_KOREAN
),
1150 ID2P(LANG_CODEPAGE_TRADITIONAL
), ID2P(LANG_CODEPAGE_UTF8
)),
1151 #else /* !HAVE_LCD_BITMAP */
1152 /* The order must match with that in unicode.c */
1153 "iso8859-1,iso8859-7,cp1251,iso8859-9,iso8859-2,cp1250,utf-8",
1155 ID2P(LANG_CODEPAGE_LATIN1
), ID2P(LANG_CODEPAGE_GREEK
),
1156 ID2P(LANG_CODEPAGE_CYRILLIC
), ID2P(LANG_CODEPAGE_TURKISH
),
1157 ID2P(LANG_CODEPAGE_LATIN_EXTENDED
),
1158 ID2P(LANG_CODEPAGE_CENTRAL_EUROPEAN
),
1159 ID2P(LANG_CODEPAGE_UTF8
)),
1161 OFFON_SETTING(0, warnon_erase_dynplaylist
, LANG_WARN_ERASEDYNPLAYLIST_MENU
,
1162 false, "warn when erasing dynamic playlist",NULL
),
1164 #ifdef HAVE_BACKLIGHT
1165 #ifdef HAS_BUTTON_HOLD
1166 CHOICE_SETTING(0, backlight_on_button_hold
, LANG_BACKLIGHT_ON_BUTTON_HOLD
,
1167 0, "backlight on button hold", "normal,off,on",
1168 backlight_set_on_button_hold
, 3,
1169 ID2P(LANG_NORMAL
), ID2P(LANG_OFF
), ID2P(LANG_ON
)),
1172 #ifdef HAVE_LCD_SLEEP_SETTING
1173 STRINGCHOICE_SETTING(0, lcd_sleep_after_backlight_off
,
1174 LANG_LCD_SLEEP_AFTER_BACKLIGHT_OFF
, 3,
1175 "lcd sleep after backlight off",
1176 "always,never,5,10,15,20,30,45,60,90",
1177 lcd_set_sleep_after_backlight_off
, 10,
1178 LANG_ALWAYS
, LANG_NEVER
, TALK_ID(5, UNIT_SEC
),
1179 TALK_ID(10, UNIT_SEC
), TALK_ID(15, UNIT_SEC
),
1180 TALK_ID(20, UNIT_SEC
), TALK_ID(30, UNIT_SEC
),
1181 TALK_ID(45, UNIT_SEC
),TALK_ID(60, UNIT_SEC
),
1182 TALK_ID(90, UNIT_SEC
)),
1183 #endif /* HAVE_LCD_SLEEP_SETTING */
1184 #endif /* HAVE_BACKLIGHT */
1186 OFFON_SETTING(0, hold_lr_for_scroll_in_list
, -1, true,
1187 "hold_lr_for_scroll_in_list",NULL
),
1188 #ifdef HAVE_LCD_BITMAP
1189 CHOICE_SETTING(0, show_path_in_browser
, LANG_SHOW_PATH
, SHOW_PATH_OFF
,
1190 "show path in browser", "off,current directory,full path",
1191 NULL
, 3, ID2P(LANG_OFF
), ID2P(LANG_SHOW_PATH_CURRENT
),
1192 ID2P(LANG_DISPLAY_FULL_PATH
)),
1196 {F_T_INT
,&global_settings
.rec_agc_preset_mic
,LANG_RECORDING_AGC_PRESET
,
1197 INT(1),"agc mic preset",NULL
,UNUSED
},
1198 {F_T_INT
,&global_settings
.rec_agc_preset_line
,LANG_RECORDING_AGC_PRESET
,
1199 INT(1),"agc line preset",NULL
,UNUSED
},
1200 {F_T_INT
,&global_settings
.rec_agc_maxgain_mic
,-1,INT(104),
1201 "agc maximum mic gain",NULL
,UNUSED
},
1202 {F_T_INT
,&global_settings
.rec_agc_maxgain_line
,-1,INT(96),
1203 "agc maximum line gain",NULL
,UNUSED
},
1204 {F_T_INT
,&global_settings
.rec_agc_cliptime
,LANG_RECORDING_AGC_CLIPTIME
,
1205 INT(1),"agc cliptime","0.2s,0.4s,0.6s,0.8,1s",UNUSED
},
1208 #ifdef HAVE_REMOTE_LCD
1209 #ifdef HAS_REMOTE_BUTTON_HOLD
1210 CHOICE_SETTING(0, remote_backlight_on_button_hold
,
1211 LANG_BACKLIGHT_ON_BUTTON_HOLD
, 0,
1212 "remote backlight on button hold",
1213 "normal,off,on", remote_backlight_set_on_button_hold
, 3,
1214 ID2P(LANG_NORMAL
), ID2P(LANG_OFF
), ID2P(LANG_ON
)),
1217 #ifdef HAVE_HEADPHONE_DETECTION
1218 CHOICE_SETTING(0, unplug_mode
, LANG_HEADPHONE_UNPLUG
, 0,
1219 "pause on headphone unplug", "off,pause,pause and resume",
1220 NULL
, 3, ID2P(LANG_OFF
), ID2P(LANG_PAUSE
),
1221 ID2P(LANG_HEADPHONE_UNPLUG_RESUME
)),
1222 INT_SETTING(0, unplug_rw
, LANG_HEADPHONE_UNPLUG_RW
, 0,
1223 "rewind duration on pause", UNIT_SEC
, 0, 15, 1, NULL
, NULL
,
1225 OFFON_SETTING(0, unplug_autoresume
,
1226 LANG_HEADPHONE_UNPLUG_DISABLE_AUTORESUME
, false,
1227 "disable autoresume if phones not present",NULL
),
1230 CHOICE_SETTING(0, fm_region
, LANG_FM_REGION
, 0,
1231 "fm_region", "eu,us,jp,kr", set_radio_region
, 4,
1232 ID2P(LANG_FM_EUROPE
), ID2P(LANG_FM_US
),
1233 ID2P(LANG_FM_JAPAN
), ID2P(LANG_FM_KOREA
)),
1236 OFFON_SETTING(0, audioscrobbler
, LANG_AUDIOSCROBBLER
, false,
1237 "Last.fm Logging", NULL
),
1239 TEXT_SETTING(0, fmr_file
, "fmr", "",
1240 FMPRESET_PATH
"/", ".fmr"),
1242 #ifdef HAVE_LCD_BITMAP
1243 TEXT_SETTING(F_THEMESETTING
, font_file
, "font",
1244 DEFAULT_FONTNAME
, FONT_DIR
"/", ".fnt"),
1246 TEXT_SETTING(F_THEMESETTING
,wps_file
, "wps",
1247 DEFAULT_WPSNAME
, WPS_DIR
"/", ".wps"),
1248 TEXT_SETTING(0,lang_file
,"lang","",LANG_DIR
"/",".lng"),
1249 #ifdef HAVE_REMOTE_LCD
1250 TEXT_SETTING(F_THEMESETTING
,rwps_file
,"rwps",
1251 DEFAULT_WPSNAME
, WPS_DIR
"/", ".rwps"),
1254 TEXT_SETTING(F_THEMESETTING
,backdrop_file
,"backdrop",
1255 DEFAULT_BACKDROP
, BACKDROP_DIR
"/", ".bmp"),
1257 #ifdef HAVE_LCD_BITMAP
1258 TEXT_SETTING(0,kbd_file
,"kbd","",ROCKBOX_DIR
"/",".kbd"),
1260 #ifdef HAVE_USB_POWER
1262 OFFON_SETTING(0,usb_charging
,LANG_USB_CHARGING
,false,"usb charging",NULL
),
1265 OFFON_SETTING(0,cuesheet
,LANG_CUESHEET_ENABLE
,false,"cuesheet support",
1267 TABLE_SETTING(F_ALLOW_ARBITRARY_VALS
, skip_length
,
1268 LANG_SKIP_LENGTH
, 0, "skip length",
1269 "track,1s,2s,3s,5s,7s,10s,15s,20s,30s,45s,1min,90s,2min,3min,5min,10min,15min",
1270 UNIT_SEC
, formatter_unit_0_is_skip_track
,
1271 getlang_unit_0_is_skip_track
, NULL
,
1272 18, 0,1,2,3,5,7,10,15,20,30,45,60,90,120,180,300,600,900),
1273 CHOICE_SETTING(0, start_in_screen
, LANG_START_SCREEN
, 1,
1274 "start in screen", "previous,root,files,db,wps,menu,"
1275 #ifdef HAVE_RECORDING
1282 #if defined(HAVE_RECORDING) && CONFIG_TUNER
1284 #elif defined(HAVE_RECORDING) || CONFIG_TUNER /* only one of them */
1289 ID2P(LANG_PREVIOUS_SCREEN
), ID2P(LANG_MAIN_MENU
),
1290 ID2P(LANG_DIR_BROWSER
), ID2P(LANG_TAGCACHE
),
1291 ID2P(LANG_RESUME_PLAYBACK
), ID2P(LANG_SETTINGS
),
1292 #ifdef HAVE_RECORDING
1293 ID2P(LANG_RECORDING
),
1296 ID2P(LANG_FM_RADIO
),
1298 ID2P(LANG_BOOKMARK_MENU_RECENT_BOOKMARKS
)
1300 SYSTEM_SETTING(NVRAM(1),last_screen
,-1),
1301 #if defined(HAVE_RTC_ALARM) && \
1302 (defined(HAVE_RECORDING) || CONFIG_TUNER)
1303 {F_T_INT
, &global_settings
.alarm_wake_up_screen
, LANG_ALARM_WAKEUP_SCREEN
,
1304 INT(ALARM_START_WPS
), "alarm wakeup screen", ALARM_SETTING_TEXT
,UNUSED
},
1305 #endif /* HAVE_RTC_ALARM */
1307 /* Customizable icons */
1308 #ifdef HAVE_LCD_BITMAP
1309 TEXT_SETTING(F_THEMESETTING
, icon_file
, "iconset", DEFAULT_ICONSET
,
1310 ICON_DIR
"/", ".bmp"),
1311 TEXT_SETTING(F_THEMESETTING
, viewers_icon_file
, "viewers iconset",
1312 DEFAULT_VIEWERS_ICONSET
,
1313 ICON_DIR
"/", ".bmp"),
1315 #ifdef HAVE_REMOTE_LCD
1316 TEXT_SETTING(F_THEMESETTING
, remote_icon_file
, "remote iconset", "",
1317 ICON_DIR
"/", ".bmp"),
1318 TEXT_SETTING(F_THEMESETTING
, remote_viewers_icon_file
,
1319 "remote viewers iconset", "",
1320 ICON_DIR
"/", ".bmp"),
1321 #endif /* HAVE_REMOTE_LCD */
1322 #ifdef HAVE_LCD_COLOR
1323 TEXT_SETTING(F_THEMESETTING
, colors_file
, "filetype colours", "-",
1324 THEME_DIR
"/", ".colours"),
1326 #ifdef HAVE_BUTTON_LIGHT
1327 TABLE_SETTING(F_ALLOW_ARBITRARY_VALS
, buttonlight_timeout
,
1328 LANG_BUTTONLIGHT_TIMEOUT
, 5, "button light timeout", off_on
,
1329 UNIT_SEC
, backlight_formatter
, backlight_getlang
,
1330 buttonlight_set_timeout
, 20,
1331 -1,0,1,2,3,4,5,6,7,8,9,10,15,20,25,30,45,60,90,120),
1333 #ifdef HAVE_BUTTONLIGHT_BRIGHTNESS
1334 INT_SETTING(F_NO_WRAP
, buttonlight_brightness
, LANG_BUTTONLIGHT_BRIGHTNESS
,
1335 DEFAULT_BRIGHTNESS_SETTING
,
1336 "button light brightness",UNIT_INT
, MIN_BRIGHTNESS_SETTING
,
1337 MAX_BRIGHTNESS_SETTING
, 1, NULL
, NULL
,
1338 buttonlight_set_brightness
),
1340 #ifndef HAVE_SCROLLWHEEL
1341 INT_SETTING(0, list_accel_start_delay
, LANG_LISTACCEL_START_DELAY
,
1342 2, "list_accel_start_delay", UNIT_MS
, 0, 10, 1,
1343 formatter_unit_0_is_off
, getlang_unit_0_is_off
, NULL
),
1344 INT_SETTING(0, list_accel_wait
, LANG_LISTACCEL_ACCEL_SPEED
,
1345 3, "list_accel_wait", UNIT_SEC
, 1, 10, 1,
1346 scanaccel_formatter
, getlang_unit_0_is_off
, NULL
),
1347 #endif /* HAVE_SCROLLWHEEL */
1349 SYSTEM_SETTING(0, statusbar_forced
, 0),
1351 #if CONFIG_CODEC == SWCODEC
1353 CHOICE_SETTING(0, keyclick
, LANG_KEYCLICK
, 0,
1354 "keyclick", "off,weak,moderate,strong", NULL
, 4,
1355 ID2P(LANG_OFF
), ID2P(LANG_WEAK
), ID2P(LANG_MODERATE
),
1357 OFFON_SETTING(0, keyclick_repeats
, LANG_KEYCLICK_REPEATS
, false,
1358 "keyclick repeats", NULL
),
1359 #endif /* CONFIG_CODEC == SWCODEC */
1360 TEXT_SETTING(0, playlist_catalog_dir
, "playlist catalog directory",
1361 PLAYLIST_CATALOG_DEFAULT_DIR
, NULL
, NULL
),
1362 #ifdef HAVE_TOUCHPAD_SENSITIVITY_SETTING
1363 CHOICE_SETTING(0, touchpad_sensitivity
, LANG_TOUCHPAD_SENSITIVITY
, 0,
1364 "touchpad sensitivity", "normal,high", touchpad_set_sensitivity
, 2,
1365 ID2P(LANG_NORMAL
), ID2P(LANG_HIGH
)),
1369 const int nb_settings
= sizeof(settings
)/sizeof(*settings
);
1371 const struct settings_list
* get_settings_list(int*count
)
1373 *count
= nb_settings
;