avrdudes / avrdude

AVRDUDE is a utility to program AVR microcontrollers
GNU General Public License v2.0
759 stars 139 forks source link

Issue with avrdude using PICkit4 and ATtiny88 #1913

Closed JorgeTorres01 closed 3 months ago

JorgeTorres01 commented 3 months ago

I am encountering the following problem when trying to program an ATtiny88 using avrdude v8.0 with the PICkit4 in ISP mode.

Command Executed:

avrdude -C avrdude.conf -v -p attiny88 -c pickit4_isp -P usb -e

Command Output:

Avrdude version 8.0
Copyright see https://github.com/avrdudes/avrdude/blob/main/AUTHORS

System wide configuration file is C:\Users\JorgeTorres\Desktop\avrdude\avrdude.conf

Using port            : usb
Using programmer      : pickit4_isp
AVR part              : ATtiny88
Programming modes     : SPM, ISP, HVPP, debugWIRE
Programmer type       : JTAG3_ISP
Description           : MPLAB(R) PICkit 4 in ISP mode
ICE HW version        : 3
ICE FW version        : 1.14 (rel. 268)
Serial number         : BUR181875242
Vtarget               : 0.0 V
SCK period            : 8.0 us
Vtarget               : 4.87 V

Jtag3_edbg_recv_frame(): unexpected response 0x82
Error: initialization failed  (rc = -1)
 - double check the connections and try again
 - use -B to set lower the bit clock frequency, e.g. -B 125kHz
 - use -F to override this check
Jtag3_edbg_send(): unexpected response 0x81, 0x11
Jtag3_edbg_recv_frame(): unexpected response 0x80
Error: unable to receive
Jtag3_edbg_send(): unexpected response 0x81, 0x11
Jtag3_edbg_recv_frame(): unexpected response 0x80
Jtag3_edbg_send(): unexpected response 0x81, 0x11
Jtag3_edbg_recv_frame(): unexpected response 0x80
Jtag3_edbg_signoff(): unexpected response 0x81, 0x11
Jtag3_edbg_signoff(): unexpected response 0x01, 0x00

Avrdude done.  Thank you.

Additional Information:

Programming the ATtiny88 using Microchip Studio works correctly with the same PICkit4. This indicates that the issue is specific to avrdude and not related to the hardware or connections.

Any ideas on how to resolve this issue?

JorgeTorres01 commented 3 months ago

Solution:

The issue was resolved by closing the "Device Programming" window in Microchip Studio, which was conflicting with avrdude. Once the Device Programming tool was closed, the avrdude command executed successfully.