summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Sevakis <jethead71@rockbox.org>2007-03-11 15:33:59 +0000
committerMichael Sevakis <jethead71@rockbox.org>2007-03-11 15:33:59 +0000
commitc7954a0becc84c3d2aa46c8d1df32c39f5dd7232 (patch)
treeed43e436be4c6e19efee2f8b4c58284b03274f53
parent94c4724420218c678151b610da096773dca9a49c (diff)
downloadrockbox-c7954a0becc84c3d2aa46c8d1df32c39f5dd7232.tar.gz
rockbox-c7954a0becc84c3d2aa46c8d1df32c39f5dd7232.zip
Clean up the debug menu serial number display code a bit and save a few bytes.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12725 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--apps/debug_menu.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/apps/debug_menu.c b/apps/debug_menu.c
index 6b5194f147..b08fcb461f 100644
--- a/apps/debug_menu.c
+++ b/apps/debug_menu.c
@@ -567,27 +567,26 @@ static bool dbg_hw_info(void)
567 { 567 {
568 struct ds2411_id id; 568 struct ds2411_id id;
569 569
570 line++; 570 lcd_puts(0, ++line, "Serial Number:");
571 lcd_puts(0, line++, "Serial Number:");
572 571
573 got_id = ds2411_read_id(&id); 572 got_id = ds2411_read_id(&id);
574 573
575 if (got_id == DS2411_OK) 574 if (got_id == DS2411_OK)
576 { 575 {
577 snprintf(buf, 32, " FC=%02x", (unsigned)id.family_code); 576 snprintf(buf, 32, " FC=%02x", (unsigned)id.family_code);
578 lcd_puts(0, line++, buf); 577 lcd_puts(0, ++line, buf);
579 snprintf(buf, 32, " ID=%02X %02X %02X %02X %02X %02X", 578 snprintf(buf, 32, " ID=%02X %02X %02X %02X %02X %02X",
580 (unsigned)id.uid[0], (unsigned)id.uid[1], (unsigned)id.uid[2], 579 (unsigned)id.uid[0], (unsigned)id.uid[1], (unsigned)id.uid[2],
581 (unsigned)id.uid[3], (unsigned)id.uid[4], (unsigned)id.uid[5]); 580 (unsigned)id.uid[3], (unsigned)id.uid[4], (unsigned)id.uid[5]);
582 lcd_puts(0, line++, buf); 581 lcd_puts(0, ++line, buf);
583 snprintf(buf, 32, " CRC=%02X", (unsigned)id.crc); 582 snprintf(buf, 32, " CRC=%02X", (unsigned)id.crc);
584 lcd_puts(0, line++, buf);
585 } 583 }
586 else 584 else
587 { 585 {
588 snprintf(buf, 32, "READ ERR=%d", got_id); 586 snprintf(buf, 32, "READ ERR=%d", got_id);
589 lcd_puts(0, line++, buf);
590 } 587 }
588
589 lcd_puts(0, ++line, buf);
591 } 590 }
592#endif 591#endif
593 592