X-Git-Url: https://git.gag.com/?p=fw%2Faltos;a=blobdiff_plain;f=ao-tools%2Fao-sky-flash%2Fsky_bin.c;h=d728d0c22413cb30dde726b1e8309cb5417e7d48;hp=e693c89204d16f02c8c9ed30744dbf525080679f;hb=1085ec5d57e0ed5d132f2bbdac1a0b6a32c0ab4a;hpb=dd8b2eadab12965d232640449b1d1c9f2484238c diff --git a/ao-tools/ao-sky-flash/sky_bin.c b/ao-tools/ao-sky-flash/sky_bin.c index e693c892..d728d0c2 100644 --- a/ao-tools/ao-sky-flash/sky_bin.c +++ b/ao-tools/ao-sky-flash/sky_bin.c @@ -3,7 +3,8 @@ * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; version 2 of the License. + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. * * This program is distributed in the hope that it will be useful, but * WITHOUT ANY WARRANTY; without even the implied warranty of @@ -40,14 +41,12 @@ skytraq_send_bin(int fd, const char *filename) return -1; } - printf ("computing checksum...\n"); fflush(stdout); /* Compute checksum, figure out how long the file */ cksum = 0; while ((c = getc(file)) != EOF) cksum += (unsigned char) c; size = ftell(file); rewind(file); - printf ("checksum: %d\n", cksum); fflush(stdout); sprintf(message, "BINSIZE = %d Checksum = %d Loopnumber = %d ", size, cksum, 1); @@ -65,7 +64,7 @@ skytraq_send_bin(int fd, const char *filename) } if (count == 0) break; - printf ("write %ld of %ld ", pos + count, size); fflush(stdout); + skytraq_dbg_printf (0, "%7d of %7d ", pos + count, size); pos += count; ret = skytraq_cmd_wait(fd, buf, count, "OK", 20000); if (ret < 0)