added verbose level in avrdude_message()

git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1321 81a1dc3b-b13d-400b-aceb-764788c761c2
This commit is contained in:
awachtler
2014-06-13 20:07:40 +00:00
parent 81a6464d53
commit bb48be1ac0
45 changed files with 1854 additions and 2128 deletions

156
usbasp.c
View File

@@ -180,7 +180,7 @@ static int usbasp_tpi_write_byte(PROGRAMMER * pgm, AVRPART * p, AVRMEM * m, unsi
static void usbasp_setup(PROGRAMMER * pgm)
{
if ((pgm->cookie = malloc(sizeof(struct pdata))) == 0) {
avrdude_message("%s: usbasp_setup(): Out of memory allocating private data\n",
avrdude_message(MSG_INFO, "%s: usbasp_setup(): Out of memory allocating private data\n",
progname);
exit(1);
}
@@ -229,15 +229,15 @@ static int usbasp_transmit(PROGRAMMER * pgm,
int nbytes;
if (verbose > 3) {
avrdude_message("%s: usbasp_transmit(\"%s\", 0x%02x, 0x%02x, 0x%02x, 0x%02x)\n",
avrdude_message(MSG_TRACE, "%s: usbasp_transmit(\"%s\", 0x%02x, 0x%02x, 0x%02x, 0x%02x)\n",
progname,
usbasp_get_funcname(functionid), send[0], send[1], send[2], send[3]);
if (!receive && buffersize > 0) {
int i;
avrdude_message("%s => ", progbuf);
avrdude_message(MSG_TRACE, "%s => ", progbuf);
for (i = 0; i < buffersize; i++)
avrdude_message("[%02x] ", buffer[i]);
avrdude_message("\n");
avrdude_message(MSG_TRACE, "[%02x] ", buffer[i]);
avrdude_message(MSG_TRACE, "\n");
}
}
@@ -251,7 +251,7 @@ static int usbasp_transmit(PROGRAMMER * pgm,
buffersize & 0xffff,
5000);
if(nbytes < 0){
avrdude_message("%s: error: usbasp_transmit: %s\n", progname, strerror(libusb_to_errno(nbytes)));
avrdude_message(MSG_INFO, "%s: error: usbasp_transmit: %s\n", progname, strerror(libusb_to_errno(nbytes)));
return -1;
}
#else
@@ -263,17 +263,17 @@ static int usbasp_transmit(PROGRAMMER * pgm,
(char *)buffer, buffersize,
5000);
if(nbytes < 0){
avrdude_message("%s: error: usbasp_transmit: %s\n", progname, usb_strerror());
avrdude_message(MSG_INFO, "%s: error: usbasp_transmit: %s\n", progname, usb_strerror());
return -1;
}
#endif
if (verbose > 3 && receive && nbytes > 0) {
int i;
avrdude_message("%s<= ", progbuf);
avrdude_message(MSG_TRACE, "%s<= ", progbuf);
for (i = 0; i < nbytes; i++)
avrdude_message("[%02x] ", buffer[i]);
avrdude_message("\n");
avrdude_message(MSG_TRACE, "[%02x] ", buffer[i]);
avrdude_message(MSG_TRACE, "\n");
}
return nbytes;
@@ -314,7 +314,7 @@ static int usbOpenDevice(libusb_device_handle **device, int vendor,
r = libusb_open(dev, &handle);
if (!handle) {
errorCode = USB_ERROR_ACCESS;
avrdude_message("%s: Warning: cannot open USB device: %s\n",
avrdude_message(MSG_INFO, "%s: Warning: cannot open USB device: %s\n",
progname, strerror(libusb_to_errno(r)));
continue;
}
@@ -325,12 +325,11 @@ static int usbOpenDevice(libusb_device_handle **device, int vendor,
if (r < 0) {
if ((vendorName != NULL) && (vendorName[0] != 0)) {
errorCode = USB_ERROR_IO;
avrdude_message("%s: Warning: cannot query manufacturer for device: %s\n",
avrdude_message(MSG_INFO, "%s: Warning: cannot query manufacturer for device: %s\n",
progname, strerror(libusb_to_errno(r)));
}
} else {
if (verbose > 1)
avrdude_message("%s: seen device from vendor ->%s<-\n",
avrdude_message(MSG_NOTICE2, "%s: seen device from vendor ->%s<-\n",
progname, string);
if ((vendorName != NULL) && (vendorName[0] != 0) && (strcmp(string, vendorName) != 0))
errorCode = USB_ERROR_NOTFOUND;
@@ -340,12 +339,11 @@ static int usbOpenDevice(libusb_device_handle **device, int vendor,
if (r < 0) {
if ((productName != NULL) && (productName[0] != 0)) {
errorCode = USB_ERROR_IO;
avrdude_message("%s: Warning: cannot query product for device: %s\n",
avrdude_message(MSG_INFO, "%s: Warning: cannot query product for device: %s\n",
progname, strerror(libusb_to_errno(r)));
}
} else {
if (verbose > 1)
avrdude_message("%s: seen product ->%s<-\n",
avrdude_message(MSG_NOTICE2, "%s: seen product ->%s<-\n",
progname, string);
if((productName != NULL) && (productName[0] != 0) && (strcmp(string, productName) != 0))
errorCode = USB_ERROR_NOTFOUND;
@@ -389,7 +387,7 @@ static int didUsbInit = 0;
handle = usb_open(dev);
if(!handle){
errorCode = USB_ERROR_ACCESS;
avrdude_message("%s: Warning: cannot open USB device: %s\n",
avrdude_message(MSG_INFO, "%s: Warning: cannot open USB device: %s\n",
progname, usb_strerror());
continue;
}
@@ -401,12 +399,11 @@ static int didUsbInit = 0;
if(len < 0){
if ((vendorName != NULL) && (vendorName[0] != 0)) {
errorCode = USB_ERROR_IO;
avrdude_message("%s: Warning: cannot query manufacturer for device: %s\n",
avrdude_message(MSG_INFO, "%s: Warning: cannot query manufacturer for device: %s\n",
progname, usb_strerror());
}
} else {
if (verbose > 1)
avrdude_message("%s: seen device from vendor ->%s<-\n",
avrdude_message(MSG_NOTICE2, "%s: seen device from vendor ->%s<-\n",
progname, string);
if((vendorName != NULL) && (vendorName[0] != 0) && (strcmp(string, vendorName) != 0))
errorCode = USB_ERROR_NOTFOUND;
@@ -417,12 +414,11 @@ static int didUsbInit = 0;
if(len < 0){
if ((productName != NULL) && (productName[0] != 0)) {
errorCode = USB_ERROR_IO;
avrdude_message("%s: Warning: cannot query product for device: %s\n",
avrdude_message(MSG_INFO, "%s: Warning: cannot query product for device: %s\n",
progname, usb_strerror());
}
} else {
if (verbose > 1)
avrdude_message("%s: seen product ->%s<-\n",
avrdude_message(MSG_NOTICE2, "%s: seen product ->%s<-\n",
progname, string);
if((productName != NULL) && (productName[0] != 0) && (strcmp(string, productName) != 0))
errorCode = USB_ERROR_NOTFOUND;
@@ -448,8 +444,7 @@ static int didUsbInit = 0;
/* Interface - prog. */
static int usbasp_open(PROGRAMMER * pgm, char * port)
{
if (verbose > 2)
avrdude_message("%s: usbasp_open(\"%s\")\n",
avrdude_message(MSG_DEBUG, "%s: usbasp_open(\"%s\")\n",
progname, port);
/* usb_init will be done in usbOpenDevice */
@@ -458,7 +453,7 @@ static int usbasp_open(PROGRAMMER * pgm, char * port)
if (usbpid) {
pid = *(int *)(ldata(usbpid));
if (lnext(usbpid))
avrdude_message("%s: Warning: using PID 0x%04x, ignoring remaining PIDs in list\n",
avrdude_message(MSG_INFO, "%s: Warning: using PID 0x%04x, ignoring remaining PIDs in list\n",
progname, pid);
} else {
pid = USBASP_SHARED_PID;
@@ -469,12 +464,12 @@ static int usbasp_open(PROGRAMMER * pgm, char * port)
if(strcasecmp(ldata(lfirst(pgm->id)), "usbasp") == 0) {
/* for id usbasp autodetect some variants */
if(strcasecmp(port, "nibobee") == 0) {
avrdude_message("%s: warning: Using \"-C usbasp -P nibobee\" is deprecated,"
avrdude_message(MSG_INFO, "%s: warning: Using \"-C usbasp -P nibobee\" is deprecated,"
"use \"-C nibobee\" instead.\n",
progname);
if (usbOpenDevice(&PDATA(pgm)->usbhandle, USBASP_NIBOBEE_VID, "www.nicai-systems.com",
USBASP_NIBOBEE_PID, "NIBObee") != 0) {
avrdude_message("%s: error: could not find USB device "
avrdude_message(MSG_INFO, "%s: error: could not find USB device "
"\"NIBObee\" with vid=0x%x pid=0x%x\n",
progname, USBASP_NIBOBEE_VID, USBASP_NIBOBEE_PID);
return -1;
@@ -485,7 +480,7 @@ static int usbasp_open(PROGRAMMER * pgm, char * port)
if (usbOpenDevice(&PDATA(pgm)->usbhandle, USBASP_OLD_VID, "www.fischl.de",
USBASP_OLD_PID, "USBasp") == 0) {
/* found USBasp with old IDs */
avrdude_message("%s: Warning: Found USB device \"USBasp\" with "
avrdude_message(MSG_INFO, "%s: Warning: Found USB device \"USBasp\" with "
"old VID/PID! Please update firmware of USBasp!\n",
progname);
return 0;
@@ -494,15 +489,15 @@ static int usbasp_open(PROGRAMMER * pgm, char * port)
/* no alternative found => fall through to generic error message */
}
avrdude_message("%s: error: could not find USB device with vid=0x%x pid=0x%x",
avrdude_message(MSG_INFO, "%s: error: could not find USB device with vid=0x%x pid=0x%x",
progname, vid, pid);
if (pgm->usbvendor[0] != 0) {
avrdude_message(" vendor='%s'", pgm->usbvendor);
avrdude_message(MSG_INFO, " vendor='%s'", pgm->usbvendor);
}
if (pgm->usbproduct[0] != 0) {
avrdude_message(" product='%s'", pgm->usbproduct);
avrdude_message(MSG_INFO, " product='%s'", pgm->usbproduct);
}
avrdude_message("\n");
avrdude_message(MSG_INFO, "\n");
return -1;
}
@@ -511,8 +506,7 @@ static int usbasp_open(PROGRAMMER * pgm, char * port)
static void usbasp_close(PROGRAMMER * pgm)
{
if (verbose > 2)
avrdude_message("%s: usbasp_close()\n", progname);
avrdude_message(MSG_DEBUG, "%s: usbasp_close()\n", progname);
if (PDATA(pgm)->usbhandle!=NULL) {
unsigned char temp[4];
@@ -566,8 +560,7 @@ static int usbasp_initialize(PROGRAMMER * pgm, AVRPART * p)
unsigned char res[4];
IMPORT_PDATA(pgm);
if (verbose > 2)
avrdude_message("%s: usbasp_initialize()\n", progname);
avrdude_message(MSG_DEBUG, "%s: usbasp_initialize()\n", progname);
/* get capabilities */
memset(temp, 0, sizeof(temp));
@@ -631,8 +624,7 @@ static int usbasp_initialize(PROGRAMMER * pgm, AVRPART * p)
static int usbasp_spi_cmd(PROGRAMMER * pgm, const unsigned char *cmd,
unsigned char *res)
{
if (verbose > 2)
avrdude_message("%s: usbasp_cpi_cmd(0x%02x, 0x%02x, 0x%02x, 0x%02x)%s",
avrdude_message(MSG_DEBUG, "%s: usbasp_cpi_cmd(0x%02x, 0x%02x, 0x%02x, 0x%02x)%s",
progname, cmd[0], cmd[1], cmd[2], cmd[3],
verbose > 3? "...\n": "");
@@ -643,16 +635,13 @@ static int usbasp_spi_cmd(PROGRAMMER * pgm, const unsigned char *cmd,
if (verbose == 3)
putc('\n', stderr);
avrdude_message("%s: error: wrong responds size\n",
avrdude_message(MSG_INFO, "%s: error: wrong responds size\n",
progname);
return -1;
}
if (verbose > 2) {
if (verbose > 3)
avrdude_message("%s: usbasp_cpi_cmd()", progname);
avrdude_message(" => 0x%02x, 0x%02x, 0x%02x, 0x%02x\n",
res[0], res[1], res[2], res[3]);
}
avrdude_message(MSG_TRACE, "%s: usbasp_cpi_cmd()", progname);
avrdude_message(MSG_DEBUG, " => 0x%02x, 0x%02x, 0x%02x, 0x%02x\n",
res[0], res[1], res[2], res[3]);
return 0;
}
@@ -666,15 +655,14 @@ static int usbasp_spi_program_enable(PROGRAMMER * pgm, AVRPART * p)
cmd[0] = 0;
if (verbose > 2)
avrdude_message("%s: usbasp_program_enable()\n",
avrdude_message(MSG_DEBUG, "%s: usbasp_program_enable()\n",
progname);
int nbytes =
usbasp_transmit(pgm, 1, USBASP_FUNC_ENABLEPROG, cmd, res, sizeof(res));
if ((nbytes != 1) | (res[0] != 0)) {
avrdude_message("%s: error: program enable: target doesn't answer. %x \n",
avrdude_message(MSG_INFO, "%s: error: program enable: target doesn't answer. %x \n",
progname, res[0]);
return -1;
}
@@ -687,12 +675,11 @@ static int usbasp_spi_chip_erase(PROGRAMMER * pgm, AVRPART * p)
unsigned char cmd[4];
unsigned char res[4];
if (verbose > 2)
avrdude_message("%s: usbasp_chip_erase()\n",
avrdude_message(MSG_DEBUG, "%s: usbasp_chip_erase()\n",
progname);
if (p->op[AVR_OP_CHIP_ERASE] == NULL) {
avrdude_message("chip erase instruction not defined for part \"%s\"\n",
avrdude_message(MSG_INFO, "chip erase instruction not defined for part \"%s\"\n",
p->desc);
return -1;
}
@@ -718,8 +705,7 @@ static int usbasp_spi_paged_load(PROGRAMMER * pgm, AVRPART * p, AVRMEM * m,
unsigned char *buffer = m->buf + address;
int function;
if (verbose > 2)
avrdude_message("%s: usbasp_program_paged_load(\"%s\", 0x%x, %d)\n",
avrdude_message(MSG_DEBUG, "%s: usbasp_program_paged_load(\"%s\", 0x%x, %d)\n",
progname, m->desc, address, n_bytes);
if (strcmp(m->desc, "flash") == 0) {
@@ -763,7 +749,7 @@ static int usbasp_spi_paged_load(PROGRAMMER * pgm, AVRPART * p, AVRMEM * m,
n = usbasp_transmit(pgm, 1, function, cmd, buffer, blocksize);
if (n != blocksize) {
avrdude_message("%s: error: wrong reading bytes %x\n",
avrdude_message(MSG_INFO, "%s: error: wrong reading bytes %x\n",
progname, n);
return -3;
}
@@ -787,8 +773,7 @@ static int usbasp_spi_paged_write(PROGRAMMER * pgm, AVRPART * p, AVRMEM * m,
unsigned char blockflags = USBASP_BLOCKFLAG_FIRST;
int function;
if (verbose > 2)
avrdude_message("%s: usbasp_program_paged_write(\"%s\", 0x%x, %d)\n",
avrdude_message(MSG_DEBUG, "%s: usbasp_program_paged_write(\"%s\", 0x%x, %d)\n",
progname, m->desc, address, n_bytes);
if (strcmp(m->desc, "flash") == 0) {
@@ -837,7 +822,7 @@ static int usbasp_spi_paged_write(PROGRAMMER * pgm, AVRPART * p, AVRMEM * m,
n = usbasp_transmit(pgm, 0, function, cmd, buffer, blocksize);
if (n != blocksize) {
avrdude_message("%s: error: wrong count at writing %x\n",
avrdude_message(MSG_INFO, "%s: error: wrong count at writing %x\n",
progname, n);
return -3;
}
@@ -876,8 +861,7 @@ static int usbasp_spi_set_sck_period(PROGRAMMER *pgm, double sckperiod)
unsigned char res[4];
unsigned char cmd[4];
if (verbose > 2)
avrdude_message("%s: usbasp_spi_set_sck_period(%g)\n",
avrdude_message(MSG_DEBUG, "%s: usbasp_spi_set_sck_period(%g)\n",
progname, sckperiod);
memset(cmd, 0, sizeof(cmd));
@@ -889,16 +873,14 @@ static int usbasp_spi_set_sck_period(PROGRAMMER *pgm, double sckperiod)
if (sckperiod == 0) {
/* auto sck set */
if (verbose >= 1)
avrdude_message("%s: auto set sck period (because given equals null)\n", progname);
avrdude_message(MSG_NOTICE, "%s: auto set sck period (because given equals null)\n", progname);
} else {
int sckfreq = 1 / sckperiod; /* sck in Hz */
int usefreq = 0;
if (verbose >= 2)
avrdude_message("%s: try to set SCK period to %g s (= %i Hz)\n", progname, sckperiod, sckfreq);
avrdude_message(MSG_NOTICE2, "%s: try to set SCK period to %g s (= %i Hz)\n", progname, sckperiod, sckfreq);
if (sckfreq >= usbaspSCKoptions[0].frequency) {
clockoption = usbaspSCKoptions[0].id;
@@ -919,7 +901,7 @@ static int usbasp_spi_set_sck_period(PROGRAMMER *pgm, double sckperiod)
/* save used sck frequency */
PDATA(pgm)->sckfreq_hz = usefreq;
avrdude_message("%s: set SCK frequency to %i Hz\n", progname, usefreq);
avrdude_message(MSG_INFO, "%s: set SCK frequency to %i Hz\n", progname, usefreq);
}
cmd[0] = clockoption;
@@ -928,7 +910,7 @@ static int usbasp_spi_set_sck_period(PROGRAMMER *pgm, double sckperiod)
usbasp_transmit(pgm, 1, USBASP_FUNC_SETISPSCK, cmd, res, sizeof(res));
if ((nbytes != 1) | (res[0] != 0)) {
avrdude_message("%s: warning: cannot set sck period. please check for usbasp firmware update.\n",
avrdude_message(MSG_INFO, "%s: warning: cannot set sck period. please check for usbasp firmware update.\n",
progname);
return -1;
}
@@ -955,7 +937,7 @@ static int usbasp_tpi_recv_byte(PROGRAMMER * pgm)
if(usbasp_transmit(pgm, 1, USBASP_FUNC_TPI_RAWREAD, temp, temp, sizeof(temp)) != 1)
{
avrdude_message("%s: error: wrong responds size\n", progname);
avrdude_message(MSG_INFO, "%s: error: wrong responds size\n", progname);
return -1;
}
@@ -967,8 +949,7 @@ static int usbasp_tpi_nvm_waitbusy(PROGRAMMER * pgm)
{
int retry;
if (verbose > 2)
avrdude_message("%s: usbasp_tpi_nvm_waitbusy() ...", progname);
avrdude_message(MSG_DEBUG, "%s: usbasp_tpi_nvm_waitbusy() ...", progname);
for(retry=50; retry>0; retry--)
{
@@ -976,21 +957,19 @@ static int usbasp_tpi_nvm_waitbusy(PROGRAMMER * pgm)
if(usbasp_tpi_recv_byte(pgm) & NVMCSR_BSY)
continue;
if (verbose > 2)
avrdude_message(" ready\n");
avrdude_message(MSG_DEBUG, " ready\n");
return 0;
}
if (verbose > 2)
avrdude_message(" failure\n");
avrdude_message(MSG_DEBUG, " failure\n");
return -1;
}
static int usbasp_tpi_cmd(PROGRAMMER * pgm, const unsigned char *cmd, unsigned char *res)
{
avrdude_message("%s: error: spi_cmd used in TPI mode: not allowed\n", progname);
avrdude_message(MSG_INFO, "%s: error: spi_cmd used in TPI mode: not allowed\n", progname);
return -1;
}
@@ -998,8 +977,7 @@ static int usbasp_tpi_program_enable(PROGRAMMER * pgm, AVRPART * p)
{
int retry;
if (verbose > 2)
avrdude_message("%s: usbasp_tpi_program_enable()\n", progname);
avrdude_message(MSG_DEBUG, "%s: usbasp_tpi_program_enable()\n", progname);
/* change guard time */
usbasp_tpi_send_byte(pgm, TPI_OP_SSTCS(TPIPCR));
@@ -1029,7 +1007,7 @@ static int usbasp_tpi_program_enable(PROGRAMMER * pgm, AVRPART * p)
}
if(retry >= 10)
{
avrdude_message("%s: error: program enable: target doesn't answer.\n", progname);
avrdude_message(MSG_INFO, "%s: error: program enable: target doesn't answer.\n", progname);
return -1;
}
@@ -1038,8 +1016,7 @@ static int usbasp_tpi_program_enable(PROGRAMMER * pgm, AVRPART * p)
static int usbasp_tpi_chip_erase(PROGRAMMER * pgm, AVRPART * p)
{
if (verbose > 2)
avrdude_message("%s: usbasp_tpi_chip_erase()\n", progname);
avrdude_message(MSG_DEBUG, "%s: usbasp_tpi_chip_erase()\n", progname);
/* Set PR to flash */
usbasp_tpi_send_byte(pgm, TPI_OP_SSTPR(0));
@@ -1070,8 +1047,7 @@ static int usbasp_tpi_paged_load(PROGRAMMER * pgm, AVRPART * p, AVRMEM * m,
uint16_t pr;
if (verbose > 2)
avrdude_message("%s: usbasp_tpi_paged_load(\"%s\", 0x%0x, %d)\n",
avrdude_message(MSG_DEBUG, "%s: usbasp_tpi_paged_load(\"%s\", 0x%0x, %d)\n",
progname, m->desc, addr, n_bytes);
dptr = addr + m->buf;
@@ -1092,7 +1068,7 @@ static int usbasp_tpi_paged_load(PROGRAMMER * pgm, AVRPART * p, AVRMEM * m,
n = usbasp_transmit(pgm, 1, USBASP_FUNC_TPI_READBLOCK, cmd, dptr, clen);
if(n != clen)
{
avrdude_message("%s: error: wrong reading bytes %x\n", progname, n);
avrdude_message(MSG_INFO, "%s: error: wrong reading bytes %x\n", progname, n);
return -3;
}
@@ -1114,8 +1090,7 @@ static int usbasp_tpi_paged_write(PROGRAMMER * pgm, AVRPART * p, AVRMEM * m,
uint16_t pr;
if (verbose > 2)
avrdude_message("%s: usbasp_tpi_paged_write(\"%s\", 0x%0x, %d)\n",
avrdude_message(MSG_DEBUG, "%s: usbasp_tpi_paged_write(\"%s\", 0x%0x, %d)\n",
progname, m->desc, addr, n_bytes);
sptr = addr + m->buf;
@@ -1142,7 +1117,7 @@ static int usbasp_tpi_paged_write(PROGRAMMER * pgm, AVRPART * p, AVRMEM * m,
n = usbasp_transmit(pgm, 0, USBASP_FUNC_TPI_WRITEBLOCK, cmd, sptr, clen);
if(n != clen)
{
avrdude_message("%s: error: wrong count at writing %x\n", progname, n);
avrdude_message(MSG_INFO, "%s: error: wrong count at writing %x\n", progname, n);
return -3;
}
@@ -1165,8 +1140,7 @@ static int usbasp_tpi_read_byte(PROGRAMMER * pgm, AVRPART * p, AVRMEM * m, unsig
uint16_t pr;
if (verbose > 2)
avrdude_message("%s: usbasp_tpi_read_byte(\"%s\", 0x%0lx)\n",
avrdude_message(MSG_DEBUG, "%s: usbasp_tpi_read_byte(\"%s\", 0x%0lx)\n",
progname, m->desc, addr);
pr = m->offset + addr;
@@ -1179,7 +1153,7 @@ static int usbasp_tpi_read_byte(PROGRAMMER * pgm, AVRPART * p, AVRMEM * m, unsig
n = usbasp_transmit(pgm, 1, USBASP_FUNC_TPI_READBLOCK, cmd, value, 1);
if(n != 1)
{
avrdude_message("%s: error: wrong reading bytes %x\n", progname, n);
avrdude_message(MSG_INFO, "%s: error: wrong reading bytes %x\n", progname, n);
return -3;
}
return 0;
@@ -1187,7 +1161,7 @@ static int usbasp_tpi_read_byte(PROGRAMMER * pgm, AVRPART * p, AVRMEM * m, unsig
static int usbasp_tpi_write_byte(PROGRAMMER * pgm, AVRPART * p, AVRMEM * m, unsigned long addr, unsigned char data)
{
avrdude_message("%s: error: usbasp_write_byte in TPI mode: all writes have to be done at page level\n", progname);
avrdude_message(MSG_INFO, "%s: error: usbasp_write_byte in TPI mode: all writes have to be done at page level\n", progname);
return -1;
}
@@ -1229,7 +1203,7 @@ void usbasp_initpgm(PROGRAMMER * pgm)
static int usbasp_nousb_open (struct programmer_t *pgm, char * name)
{
avrdude_message("%s: error: no usb support. please compile again with libusb installed.\n",
avrdude_message(MSG_INFO, "%s: error: no usb support. please compile again with libusb installed.\n",
progname);
return -1;