forked from len0rd/rockbox
Ondio FM: Removed S/PDIF option for recording source, as the Ondio doesn't have S/PDIF input. Bumped config block version so save your settings.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7482 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
cff7b0614b
commit
8fd5b177ed
6 changed files with 31 additions and 11 deletions
|
|
@ -93,9 +93,14 @@
|
||||||
bool f2_rec_screen(void);
|
bool f2_rec_screen(void);
|
||||||
bool f3_rec_screen(void);
|
bool f3_rec_screen(void);
|
||||||
|
|
||||||
#define SOURCE_MIC 0
|
#define SOURCE_MIC 0
|
||||||
#define SOURCE_LINE 1
|
#define SOURCE_LINE 1
|
||||||
|
#ifdef HAVE_SPDIF_IN
|
||||||
#define SOURCE_SPDIF 2
|
#define SOURCE_SPDIF 2
|
||||||
|
#define MAX_SOURCE SOURCE_SPDIF
|
||||||
|
#else
|
||||||
|
#define MAX_SOURCE SOURCE_LINE
|
||||||
|
#endif
|
||||||
|
|
||||||
#define MAX_FILE_SIZE 0x7FF00000 /* 2 GB - 1 MB */
|
#define MAX_FILE_SIZE 0x7FF00000 /* 2 GB - 1 MB */
|
||||||
|
|
||||||
|
|
@ -699,8 +704,7 @@ bool recording_screen(void)
|
||||||
last_seconds = 0;
|
last_seconds = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Show mic gain if input source is Mic */
|
if(global_settings.rec_source == SOURCE_MIC)
|
||||||
if(global_settings.rec_source == 0)
|
|
||||||
{
|
{
|
||||||
snprintf(buf, 32, "%s: %s", str(LANG_RECORDING_GAIN),
|
snprintf(buf, 32, "%s: %s", str(LANG_RECORDING_GAIN),
|
||||||
fmt_gain(SOUND_MIC_GAIN,
|
fmt_gain(SOUND_MIC_GAIN,
|
||||||
|
|
@ -746,7 +750,9 @@ bool recording_screen(void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef SOURCE_SPDIF
|
||||||
if(global_settings.rec_source != SOURCE_SPDIF)
|
if(global_settings.rec_source != SOURCE_SPDIF)
|
||||||
|
#endif
|
||||||
put_cursorxy(0, 4 + cursor, true);
|
put_cursorxy(0, 4 + cursor, true);
|
||||||
|
|
||||||
if (global_settings.rec_source != SOURCE_LINE) {
|
if (global_settings.rec_source != SOURCE_LINE) {
|
||||||
|
|
@ -987,7 +993,7 @@ bool f3_rec_screen(void)
|
||||||
case BUTTON_LEFT:
|
case BUTTON_LEFT:
|
||||||
case BUTTON_F3 | BUTTON_LEFT:
|
case BUTTON_F3 | BUTTON_LEFT:
|
||||||
global_settings.rec_source++;
|
global_settings.rec_source++;
|
||||||
if(global_settings.rec_source > 2)
|
if(global_settings.rec_source > MAX_SOURCE)
|
||||||
global_settings.rec_source = 0;
|
global_settings.rec_source = 0;
|
||||||
used = true;
|
used = true;
|
||||||
break;
|
break;
|
||||||
|
|
|
||||||
|
|
@ -78,7 +78,7 @@ const char rec_base_directory[] = REC_BASE_DIR;
|
||||||
#include "pcm_playback.h"
|
#include "pcm_playback.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#define CONFIG_BLOCK_VERSION 26
|
#define CONFIG_BLOCK_VERSION 27
|
||||||
#define CONFIG_BLOCK_SIZE 512
|
#define CONFIG_BLOCK_SIZE 512
|
||||||
#define RTC_BLOCK_SIZE 44
|
#define RTC_BLOCK_SIZE 44
|
||||||
|
|
||||||
|
|
@ -364,8 +364,11 @@ static const struct bit_entry hd_bits[] =
|
||||||
{1, S_O(rec_channels), 0, "rec channels", "stereo,mono" },
|
{1, S_O(rec_channels), 0, "rec channels", "stereo,mono" },
|
||||||
{4, S_O(rec_mic_gain), 8, "rec mic gain", NULL },
|
{4, S_O(rec_mic_gain), 8, "rec mic gain", NULL },
|
||||||
{3, S_O(rec_quality), 5, "rec quality", NULL },
|
{3, S_O(rec_quality), 5, "rec quality", NULL },
|
||||||
{2, S_O(rec_source), 0, /* 0=mic */
|
#ifdef HAVE_SPDIF_IN
|
||||||
"rec source", "mic,line,spdif" },
|
{2, S_O(rec_source), 0 /* 0=mic */, "rec source", "mic,line,spdif" },
|
||||||
|
#else
|
||||||
|
{1, S_O(rec_source), 0 /* 0=mic */, "rec source", "mic,line" },
|
||||||
|
#endif
|
||||||
{3, S_O(rec_frequency), 0, /* 0=44.1kHz */
|
{3, S_O(rec_frequency), 0, /* 0=44.1kHz */
|
||||||
"rec frequency", "44,48,32,22,24,16" },
|
"rec frequency", "44,48,32,22,24,16" },
|
||||||
{4, S_O(rec_left_gain), 2, /* 0dB */
|
{4, S_O(rec_left_gain), 2, /* 0dB */
|
||||||
|
|
|
||||||
|
|
@ -255,11 +255,13 @@ static bool recsource(void)
|
||||||
static const struct opt_items names[] = {
|
static const struct opt_items names[] = {
|
||||||
{ STR(LANG_RECORDING_SRC_MIC) },
|
{ STR(LANG_RECORDING_SRC_MIC) },
|
||||||
{ STR(LANG_RECORDING_SRC_LINE) },
|
{ STR(LANG_RECORDING_SRC_LINE) },
|
||||||
{ STR(LANG_RECORDING_SRC_DIGITAL) }
|
#ifdef HAVE_SPDIF_IN
|
||||||
|
{ STR(LANG_RECORDING_SRC_DIGITAL) },
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
return set_option(str(LANG_RECORDING_SOURCE),
|
return set_option(str(LANG_RECORDING_SOURCE),
|
||||||
&global_settings.rec_source, INT,
|
&global_settings.rec_source, INT, names,
|
||||||
names, 3, NULL );
|
sizeof(names)/sizeof(struct opt_items), NULL );
|
||||||
}
|
}
|
||||||
|
|
||||||
static bool recfrequency(void)
|
static bool recfrequency(void)
|
||||||
|
|
|
||||||
|
|
@ -86,6 +86,9 @@
|
||||||
/* define this if the unit can be powered or charged via USB */
|
/* define this if the unit can be powered or charged via USB */
|
||||||
#define HAVE_USB_POWER
|
#define HAVE_USB_POWER
|
||||||
|
|
||||||
|
/* Define this for S/PDIF input available */
|
||||||
|
#define HAVE_SPDIF_IN
|
||||||
|
|
||||||
#define CONFIG_LCD LCD_SSD1815
|
#define CONFIG_LCD LCD_SSD1815
|
||||||
|
|
||||||
#define BOOTFILE_EXT "ajz"
|
#define BOOTFILE_EXT "ajz"
|
||||||
|
|
|
||||||
|
|
@ -77,6 +77,9 @@
|
||||||
/* Define this for S/PDIF output available */
|
/* Define this for S/PDIF output available */
|
||||||
#define HAVE_SPDIF_OUT
|
#define HAVE_SPDIF_OUT
|
||||||
|
|
||||||
|
/* Define this for S/PDIF input available */
|
||||||
|
#define HAVE_SPDIF_IN
|
||||||
|
|
||||||
#define CONFIG_LCD LCD_SSD1815
|
#define CONFIG_LCD LCD_SSD1815
|
||||||
|
|
||||||
#define BOOTFILE_EXT "ajz"
|
#define BOOTFILE_EXT "ajz"
|
||||||
|
|
|
||||||
|
|
@ -86,6 +86,9 @@
|
||||||
/* define this if the unit can be powered or charged via USB */
|
/* define this if the unit can be powered or charged via USB */
|
||||||
#define HAVE_USB_POWER
|
#define HAVE_USB_POWER
|
||||||
|
|
||||||
|
/* Define this for S/PDIF input available */
|
||||||
|
#define HAVE_SPDIF_IN
|
||||||
|
|
||||||
#define CONFIG_LCD LCD_SSD1815
|
#define CONFIG_LCD LCD_SSD1815
|
||||||
|
|
||||||
#define BOOTFILE_EXT "ajz"
|
#define BOOTFILE_EXT "ajz"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue