diff options
author | Linus Nielsen Feltzing <linus@haxx.se> | 2002-07-02 15:58:27 +0000 |
---|---|---|
committer | Linus Nielsen Feltzing <linus@haxx.se> | 2002-07-02 15:58:27 +0000 |
commit | d506e7a3577bc20a0b72084d0315ce93334ceeeb (patch) | |
tree | 9d84c877ec4c033509a8bed37252ee0267bab59c /apps | |
parent | 9309c4d508780f161a6ff450324948178d01c72c (diff) | |
download | rockbox-d506e7a3577bc20a0b72084d0315ce93334ceeeb.tar.gz rockbox-d506e7a3577bc20a0b72084d0315ce93334ceeeb.zip |
Removed debug code
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@1301 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps')
-rw-r--r-- | apps/main_menu.c | 76 |
1 files changed, 0 insertions, 76 deletions
diff --git a/apps/main_menu.c b/apps/main_menu.c index 7ec57bc7ee..516c74ca49 100644 --- a/apps/main_menu.c +++ b/apps/main_menu.c | |||
@@ -38,16 +38,8 @@ | |||
38 | #include "screensavers_menu.h" | 38 | #include "screensavers_menu.h" |
39 | #include "bmp.h" | 39 | #include "bmp.h" |
40 | #include "icons.h" | 40 | #include "icons.h" |
41 | |||
42 | #ifndef SIMULATOR | ||
43 | #ifdef ARCHOS_RECORDER | ||
44 | #include "adc.h" | ||
45 | #endif | ||
46 | #endif | ||
47 | #endif | 41 | #endif |
48 | 42 | ||
49 | void dbg_ports(void); | ||
50 | |||
51 | int show_logo( void ) | 43 | int show_logo( void ) |
52 | { | 44 | { |
53 | #ifdef HAVE_LCD_BITMAP | 45 | #ifdef HAVE_LCD_BITMAP |
@@ -153,71 +145,3 @@ void main_menu(void) | |||
153 | menu_run(m); | 145 | menu_run(m); |
154 | menu_exit(m); | 146 | menu_exit(m); |
155 | } | 147 | } |
156 | |||
157 | /*---------------------------------------------------*/ | ||
158 | /* SPECIAL DEBUG STUFF */ | ||
159 | /*---------------------------------------------------*/ | ||
160 | #ifndef SIMULATOR | ||
161 | #ifdef ARCHOS_RECORDER | ||
162 | extern int ata_device; | ||
163 | extern int ata_io_address; | ||
164 | |||
165 | /* Test code!!! */ | ||
166 | void dbg_ports(void) | ||
167 | { | ||
168 | unsigned short porta; | ||
169 | unsigned short portb; | ||
170 | unsigned char portc; | ||
171 | char buf[32]; | ||
172 | int button; | ||
173 | |||
174 | lcd_clear_display(); | ||
175 | |||
176 | while(1) | ||
177 | { | ||
178 | porta = PADR; | ||
179 | portb = PBDR; | ||
180 | portc = PCDR; | ||
181 | |||
182 | snprintf(buf, 32, "PADR: %04x", porta); | ||
183 | lcd_puts(0, 0, buf); | ||
184 | snprintf(buf, 32, "PBDR: %04x", portb); | ||
185 | lcd_puts(0, 1, buf); | ||
186 | |||
187 | snprintf(buf, 32, "AN0: %03x AN4: %03x", adc_read(0), adc_read(4)); | ||
188 | lcd_puts(0, 3, buf); | ||
189 | snprintf(buf, 32, "AN1: %03x AN5: %03x", adc_read(1), adc_read(5)); | ||
190 | lcd_puts(0, 4, buf); | ||
191 | snprintf(buf, 32, "AN2: %03x AN6: %03x", adc_read(2), adc_read(6)); | ||
192 | lcd_puts(0, 5, buf); | ||
193 | snprintf(buf, 32, "AN3: %03x AN7: %03x", adc_read(3), adc_read(7)); | ||
194 | lcd_puts(0, 6, buf); | ||
195 | |||
196 | snprintf(buf, 32, "%s : 0x%x", | ||
197 | ata_device?"slave":"master", ata_io_address); | ||
198 | lcd_puts(0, 7, buf); | ||
199 | |||
200 | lcd_update(); | ||
201 | sleep(HZ/10); | ||
202 | |||
203 | button = button_get(false); | ||
204 | |||
205 | switch(button) | ||
206 | { | ||
207 | case BUTTON_ON: | ||
208 | /* Toggle the charger */ | ||
209 | PBDR ^= 0x20; | ||
210 | break; | ||
211 | |||
212 | #ifdef HAVE_RECORDER_KEYPAD | ||
213 | case BUTTON_OFF: | ||
214 | #else | ||
215 | case BUTTON_STOP: | ||
216 | #endif /* Disable the charger */ | ||
217 | PBDR |= 0x20; | ||
218 | return; | ||
219 | } | ||
220 | } | ||
221 | } | ||
222 | #endif | ||
223 | #endif | ||