Welcome, Guest

Author Topic: AVR-ISP-MK2 and macOS X not working  (Read 767 times)

jbz

  • Newbie
  • *
  • Posts: 3
  • Karma: +0/-0
AVR-ISP-MK2 and macOS X not working
« on: January 04, 2018, 03:01:41 PM »
I recently purchased an AVR-ISP-MK2 through Farnell. Despite following instructions to deal with avrdude bug, I cannot connect to it on a Mac. In particular, running
Code: [Select]
avrdude -v -p atmega328p -P usb -c avrispmkii -C avrdude.conf gets me
Code: [Select]
avrdude: usbdev_open(): Found AVRISP mkII, serno: 000200312345

avrdude: stk500v2_command(): command failed
avrdude: stk500v2_program_enable(): bad AVRISPmkII connection status: Unknown status 0x00
avrdude: initialization failed, rc=-1

I did follow instructions https://www.olimex.com/forum/index.php?topic=5781.0 which involves installing the libusb firmware (which I take is the same as here: https://www.olimex.com/Products/AVR/Programmers/AVR-ISP-MK2/resources/AVR-ISP-MK2-Firmware-WindowsDrivers.zip, which just to be sure I also tried) and then compiling a patched version of avrdude 6.3 (patch from here: https://www.olimex.com/Products/AVR/Programmers/AVR-ISP-MK2/resources/endpointdetect_pass1.patch; I tried both the included patched version from the instructions as well as applying the patch myself).

For reference, using my old usbTinyISP I can read/write the Arduino board (with ATMega328P) without issues.
What am I missing?

LubOlimex

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1752
  • Karma: +46/-2
Re: AVR-ISP-MK2 and macOS X not working
« Reply #1 on: January 04, 2018, 03:40:43 PM »
Did you also change the firmware of AVR-ISP-MK2 as the guide suggests?

Did you test with older version of AVRDUDE (versions prior to 6.x.x, like 5.x.x)? Such a test would determine if it is the endpointdetect_pass bug. If you are using Arduino IDE, then get version 1.5.7 or older (the last suitable Arduino IDE version that uses pre-6.x.x AVRDUDE version is Arduino IDE 1.5.7).

Best regards,
Lub/OLIMEX
Technical support and documentation manager at Olimex

jbz

  • Newbie
  • *
  • Posts: 3
  • Karma: +0/-0
Re: AVR-ISP-MK2 and macOS X not working
« Reply #2 on: January 04, 2018, 03:48:29 PM »
I did change the firmware, and I also tried older versions of avrdude (compiled 5.9), to no avail.

LubOlimex

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1752
  • Karma: +46/-2
Re: AVR-ISP-MK2 and macOS X not working
« Reply #3 on: January 04, 2018, 03:55:09 PM »
It can be something else, not related to the software installation. You mentioned that Usbtinyisp works fine. Usbtinyisp has two ISP connectors - 6-pin and 10-pin one. Did you notice that AVR-ISP-MK2 has NO 6-pin ISP connector; and only a 10-pin ISP connector?

Edit: This error might also appear if the target is not powered or insufficiently powered; how do you power the target ATmega328p? If you power it from the AVR-ISP-MK2, are the jumpers set properly?
« Last Edit: January 04, 2018, 04:15:37 PM by LubOlimex »
Technical support and documentation manager at Olimex

jbz

  • Newbie
  • *
  • Posts: 3
  • Karma: +0/-0
Re: AVR-ISP-MK2 and macOS X not working
« Reply #4 on: January 04, 2018, 04:33:59 PM »
 :-[ D’oh. It’ll be the ISP connector. It didn’t even occur to me they might not be the same. Cannot test it now, but that’ll be it. Sorry for the waste of your time.