summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--apps/debug_menu.c80
1 files changed, 41 insertions, 39 deletions
diff --git a/apps/debug_menu.c b/apps/debug_menu.c
index 91746d2e58..6241017bf4 100644
--- a/apps/debug_menu.c
+++ b/apps/debug_menu.c
@@ -309,7 +309,8 @@ bool dbg_hw_info(void)
309 snprintf(buf, 32, "USB: %s", usb_polarity?"positive":"negative"); 309 snprintf(buf, 32, "USB: %s", usb_polarity?"positive":"negative");
310 lcd_puts(0, 3, buf); 310 lcd_puts(0, 3, buf);
311 311
312 snprintf(buf, 32, "ATA: 0x%x", ata_io_address); 312 snprintf(buf, 32, "ATA: 0x%x,%s", ata_io_address,
313 ata_device ? "slave":"master");
313 lcd_puts(0, 4, buf); 314 lcd_puts(0, 4, buf);
314 315
315 snprintf(buf, 32, "PR: %s", pr_polarity?"positive":"negative"); 316 snprintf(buf, 32, "PR: %s", pr_polarity?"positive":"negative");
@@ -381,7 +382,8 @@ bool dbg_hw_info(void)
381 usb_polarity?"pos":"neg"); 382 usb_polarity?"pos":"neg");
382 break; 383 break;
383 case 2: 384 case 2:
384 snprintf(buf, 32, "ATA: 0x%x", ata_io_address); 385 snprintf(buf, 32, "ATA: 0x%x%s",
386 ata_io_address, ata_device ? "s","m");
385 break; 387 break;
386 case 3: 388 case 3:
387 snprintf(buf, 32, "Mask: %04x", bitmask); 389 snprintf(buf, 32, "Mask: %04x", bitmask);
@@ -1222,47 +1224,47 @@ static bool dbg_disk_info(void)
1222#endif 1224#endif
1223 1225
1224 switch (page) { 1226 switch (page) {
1225 case 0: 1227 case 0:
1226 for (i=0; i < 20; i++) 1228 for (i=0; i < 20; i++)
1227 ((unsigned short*)buf)[i]=identify_info[i+27]; 1229 ((unsigned short*)buf)[i]=identify_info[i+27];
1228 buf[40]=0; 1230 buf[40]=0;
1229 /* kill trailing space */ 1231 /* kill trailing space */
1230 for (i=39; i && buf[i]==' '; i--) 1232 for (i=39; i && buf[i]==' '; i--)
1231 buf[i] = 0; 1233 buf[i] = 0;
1232 lcd_puts(0, y++, "Model"); 1234 lcd_puts(0, y++, "Model");
1233 lcd_puts_scroll(0, y++, buf); 1235 lcd_puts_scroll(0, y++, buf);
1234 break; 1236 break;
1235 1237
1236 case 1: 1238 case 1:
1237 for (i=0; i < 4; i++) 1239 for (i=0; i < 4; i++)
1238 ((unsigned short*)buf)[i]=identify_info[i+23]; 1240 ((unsigned short*)buf)[i]=identify_info[i+23];
1239 buf[8]=0; 1241 buf[8]=0;
1240 lcd_puts(0, y++, "Firmware"); 1242 lcd_puts(0, y++, "Firmware");
1241 lcd_puts(0, y++, buf); 1243 lcd_puts(0, y++, buf);
1242 break; 1244 break;
1243 1245
1244 case 2: 1246 case 2:
1245 snprintf(buf, sizeof buf, "%d MB", 1247 snprintf(buf, sizeof buf, "%d MB",
1246 ((unsigned)identify_info[61] << 16 | 1248 ((unsigned)identify_info[61] << 16 |
1247 (unsigned)identify_info[60]) / 2048 ); 1249 (unsigned)identify_info[60]) / 2048 );
1248 lcd_puts(0, y++, "Size"); 1250 lcd_puts(0, y++, "Size");
1249 lcd_puts(0, y++, buf); 1251 lcd_puts(0, y++, buf);
1250 break; 1252 break;
1251 1253
1252 case 3: { 1254 case 3: {
1253 unsigned int free; 1255 unsigned int free;
1254 fat_size( NULL, &free ); 1256 fat_size( NULL, &free );
1255 snprintf(buf, sizeof buf, "%d MB", free / 1024 ); 1257 snprintf(buf, sizeof buf, "%d MB", free / 1024 );
1256 lcd_puts(0, y++, "Free"); 1258 lcd_puts(0, y++, "Free");
1257 lcd_puts(0, y++, buf); 1259 lcd_puts(0, y++, buf);
1258 break; 1260 break;
1259 } 1261 }
1260 1262
1261 case 4: 1263 case 4:
1262 snprintf(buf, sizeof buf, "%d ms", ata_spinup_time * (1000/HZ)); 1264 snprintf(buf, sizeof buf, "%d ms", ata_spinup_time * (1000/HZ));
1263 lcd_puts(0, y++, "Spinup time"); 1265 lcd_puts(0, y++, "Spinup time");
1264 lcd_puts(0, y++, buf); 1266 lcd_puts(0, y++, buf);
1265 break; 1267 break;
1266 } 1268 }
1267 lcd_update(); 1269 lcd_update();
1268 1270