avrdude: error: usbtiny_send: usb_control_msg(DeviceRequestT

USB AVR Programmer and SPI interface. Adafruit's USBtinyISP.

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
cykey
 
Posts: 12
Joined: Sun Nov 17, 2013 11:41 am

avrdude: error: usbtiny_send: usb_control_msg(DeviceRequestT

Post by cykey »

Hi!

I'm experiencing a weird issue when using avrdude + usbtinyisp on an attiny84 chip.

Here is the error:

Code: Select all

avrdude -c usbtiny -p attiny84 -U lfuse:w:0xe2:m -U hfuse:w:0xd7:m -U efuse:w:0xff:m -U eeprom:w:.eeprom.hex

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.01s

avrdude: Device signature = 0x1e930c
avrdude: reading input file "0xe2"
avrdude: writing lfuse (1 bytes):

Writing | ################################################## | 100% 0.00s

avrdude: 1 bytes of lfuse written
avrdude: verifying lfuse memory against 0xe2:
avrdude: load data lfuse data from input file 0xe2:
avrdude: input file 0xe2 contains 1 bytes
avrdude: reading on-chip lfuse data:

Reading | ################################################## | 100% 0.00s

avrdude: verifying ...
avrdude: 1 bytes of lfuse verified
avrdude: reading input file "0xd7"
avrdude: writing hfuse (1 bytes):

Writing | ################################################## | 100% 0.00s

avrdude: 1 bytes of hfuse written
avrdude: verifying hfuse memory against 0xd7:
avrdude: load data hfuse data from input file 0xd7:
avrdude: input file 0xd7 contains 1 bytes
avrdude: reading on-chip hfuse data:

Reading | ################################################## | 100% 0.00s

avrdude: verifying ...
avrdude: 1 bytes of hfuse verified
avrdude: reading input file "0xff"
avrdude: writing efuse (1 bytes):

Writing | ################################################## | 100% 0.00s

avrdude: 1 bytes of efuse written
avrdude: verifying efuse memory against 0xff:
avrdude: load data efuse data from input file 0xff:
avrdude: input file 0xff contains 1 bytes
avrdude: reading on-chip efuse data:

Reading | ################################################## | 100% 0.00s

avrdude: verifying ...
avrdude: 1 bytes of efuse verified
avrdude: reading input file ".eeprom.hex"
avrdude: input file .eeprom.hex auto detected as Intel Hex
avrdude: writing eeprom (16 bytes):

Writing | #########################                          | 50% 4.05s
avrdude: error: usbtiny_send: usb_control_msg(DeviceRequestTO): transaction timed out (expected 128, got -60)
Writing | ################################################## | 100% 7.02s

avrdude: 16 bytes of eeprom written
avrdude: verifying eeprom memory against .eeprom.hex:
avrdude: load data eeprom data from input file .eeprom.hex:
avrdude: input file .eeprom.hex auto detected as Intel Hex
avrdude: input file .eeprom.hex contains 16 bytes
avrdude: reading on-chip eeprom data:

Reading | ################################################## | 100% 0.70s

avrdude: verifying ...
avrdude: 16 bytes of eeprom verified

avrdude: safemode: Fuses OK (H:FF, E:D7, L:E2)

avrdude done.  Thank you.
And here is my "code:

Code: Select all

prepare-chip:
	@# Generate a random serial number using uuidgen.
	$(ECHO_NOTHING)uuidgen | tr -d '-' | head -c 16 > .tmp.txt$(ECHO_END)

	@# Create an eeprom file (Intel Hex) using avr-objcopy.
	$(ECHO_NOTHING)avr-objcopy -I binary -O ihex .tmp.txt .eeprom.hex$(ECHO_END)

	@# Upload the eeprom file & set the correct fuses.
	@echo "Setting fuses and writing eeprom..."
	avrdude -c usbtiny -p attiny84 -U lfuse:w:0xe2:m -U hfuse:w:0xd7:m -U efuse:w:0xff:m -U eeprom:w:.eeprom.hex

	$(ECHO_NOTHING)rm -rf .tmp.txt .eeprom.hex$(ECHO_END)
Thank you!

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: avrdude: error: usbtiny_send: usb_control_msg(DeviceRequ

Post by adafruit_support_rick »

I don't know what's up with that message, but the fuse and eeprom operation seems to have worked. It verified the fuses and eeprom against the values you gave it.

User avatar
cykey
 
Posts: 12
Joined: Sun Nov 17, 2013 11:41 am

Re: avrdude: error: usbtiny_send: usb_control_msg(DeviceRequ

Post by cykey »

Yeah, it does work but I'm just not sure on why this is happening.

Thanks.

adafruit
 
Posts: 12151
Joined: Thu Apr 06, 2006 4:21 pm

Re: avrdude: error: usbtiny_send: usb_control_msg(DeviceRequ

Post by adafruit »

Some usb systems just have a hiccup - or perhaps your chip is slower than expected. as long as verification is OK, you're golden!

Locked
Please be positive and constructive with your questions and comments.

Return to “USBtinyISP”