From 04f9cc79937a6939e800c646b4c8e9650898bd7e Mon Sep 17 00:00:00 2001 From: Linus Nielsen Feltzing Date: Wed, 4 Feb 2004 09:53:22 +0000 Subject: Added a debug option for the FM radio detection git-svn-id: svn://svn.rockbox.org/rockbox/trunk@4293 a1c6a512-1295-4272-9138-f99709370657 --- apps/recorder/radio.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'apps/recorder') diff --git a/apps/recorder/radio.c b/apps/recorder/radio.c index 65b8beb164..819d2a5d5b 100644 --- a/apps/recorder/radio.c +++ b/apps/recorder/radio.c @@ -64,6 +64,8 @@ static struct fmstation presets[MAX_PRESETS]; static char default_filename[] = "/.rockbox/fm-presets-default.fmr"; +int debug_fm_detection; + void radio_load_presets(void); bool radio_preset_select(void); bool radio_menu(void); @@ -81,6 +83,7 @@ bool radio_hardware_present(void) fmradio_set(2, 0x140885); /* 5kHz, 7.2MHz crystal, test mode 1 */ val = fmradio_read(0); + debug_fm_detection = val; if(val == 0x140885) return true; else @@ -554,7 +557,7 @@ void radio_load_presets(void) if(fd >= 0) { i = 0; - while(!done) + while(!done && num_presets < MAX_PRESETS) { rc = read_line(fd, buf, 128); if(rc > 0) -- cgit v1.2.3