From 7ef02e7634bc62e7d7d6f1c2a4b350bff8af434a Mon Sep 17 00:00:00 2001 From: Michael Gernoth Date: Sun, 8 Feb 2009 13:06:51 +0100 Subject: [PATCH 1/1] fix boardstatus output --- rsbs2.pl | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/rsbs2.pl b/rsbs2.pl index 7f5cc0f..17f33dc 100755 --- a/rsbs2.pl +++ b/rsbs2.pl @@ -411,19 +411,21 @@ sub status { print "COM redirection:\t" . (($bs & 0x100000) ? "ON" : "OFF") . "\n"; print "UART redirect:\t\t" . (($bs & 0x200000) ? "ON" : "OFF") . "\n"; print "UART redirect pending:\t" . (($bs & 0x400000) ? "TRUE" : "FALSE") . "\n"; + print "Hex BoardStatus:\t${boardstatus}\n"; my $fws = hex ($boardfwstatus); print "FW status:\t\t"; if ($fws == 3 || $fws == 32771) { - print "WAITING\n"; + print "WAITING"; } else { - print "DONE\n"; + print "DONE"; } + print " (${boardfwstatus})\n"; if (($fws & 0x8080) || ($fws & 0x80)) { printf("FW error:\t\t0x%02x\n", ($fws & 0xff)); } - print "boardstatus:\t\t${boardstatus}\n"; - print "boardfwstatus:\t\t${boardfwstatus}\n"; - print "fw upgrade progress:\t${boardfwprogress}\n"; + if ($fws != 0) { + print "FW upgrade progress:\t${boardfwprogress}\n"; + } } sub login { -- 2.39.5