Author Topic: dylib upload problem on MacOSX 10.9 Mavericks  (Read 8390 times)

joshmarinacci

  • Newbie
  • *
  • Posts: 4
dylib upload problem on MacOSX 10.9 Mavericks
« on: July 02, 2014, 02:36:47 pm »
I'm working on support for Digispark in Electron, my new open source Arduino IDE.  I've gotten sketches to compile correctly but I can't upload. Both the official Arduino IDE and my own show this error when you invoke avrdude:

▶ /Users/josh/projects/Digistump/hardware/digistump/avr/tools/avrdude -cdigispark --timeout 60 -Uflash:w:build/out/DigitalPotControl.hex:i
Running Digispark Uploader...
Plug in device now... (will timeout in 60 seconds)
dyld: Library not loaded: /usr/local/lib/libusb-0.1.4.dylib
  Referenced from: /Users/josh/projects/Digistump/hardware/digistump/avr/tools/micronucleus
  Reason: image not found

Any idea what libusb is? Generally OSX doesn't use /usr/local/lib so I'm surprised this is a dependency. Mac apps usually use ObjC frameworks.


netguy204

  • Newbie
  • *
  • Posts: 20
Re: dylib upload problem on MacOSX 10.9 Mavericks
« Reply #1 on: July 02, 2014, 08:13:36 pm »
I bet that's the location that my copy of lib usb was in when I built the mac addins. That's where home brew puts its libraries. I should either rebuild with static Libusb linkage or distribute Libusb with the mac build.

As a workaround you can install Libusb via home brew to satisfy the dependency.

joshmarinacci

  • Newbie
  • *
  • Posts: 4
Re: dylib upload problem on MacOSX 10.9 Mavericks
« Reply #2 on: July 03, 2014, 08:48:49 pm »
Ah. That makes sense. Yes, a new build would be great. I'm almost done with everything else to support DigisparkPro in Electron.

joshmarinacci

  • Newbie
  • *
  • Posts: 4
Re: dylib upload problem on MacOSX 10.9 Mavericks
« Reply #3 on: July 11, 2014, 07:11:03 pm »
I just downloaded the latest build from the website. It looks like it has the broken dylib.  Are there instructions so I can compile it myself, preferably from a public github repo? I'd really like to get Electron support done before the final kits go out to the non-beta backers.

SamMacJunkie

  • Newbie
  • *
  • Posts: 1
Re: dylib upload problem on MacOSX 10.9 Mavericks
« Reply #4 on: September 30, 2014, 05:10:47 pm »
Was there any update to this? I got my Pro's in the mail and have this same error after following the instructions to use Arduino 1.5.7. I also don't have Digispark Pro under programmer.

eeKnud

  • Newbie
  • *
  • Posts: 1
Re: dylib upload problem on MacOSX 10.9 Mavericks
« Reply #5 on: November 07, 2014, 10:32:24 am »
Same question? Any update?

From the Arduino IDE I see the board, but not the programmer, though micronucleus is there.

Installed libusb-1.0.19 and when trying to upload I get in the IDE

Running Digispark Uploader...
Plug in device now... (will timeout in 60 seconds)
dyld: Library not loaded: /usr/local/lib/libusb-0.1.4.dylib
  Referenced from: /Users/knud/Documents/Arduino/hardware/digistump/avr/tools/micronucleus
  Reason: image not found


If I link the libusb-1.0.0.dylib to libusb-0.1.4.dylib, I get

Running Digispark Uploader...
Plug in device now... (will timeout in 60 seconds)
dyld: Library not loaded: /usr/local/lib/libusb-0.1.4.dylib
  Referenced from: /Users/knud/Documents/Arduino/hardware/digistump/avr/tools/micronucleus
  Reason: Incompatible library version: micronucleus requires version 9.0.0 or later, but libusb-0.1.4.dylib provides version 2.0.0


which really seems confusing.

I suppose I'll move to linux and see if that can work, but I'd much prefer to keep all my arduino dev where it is, on my Mac.

sk

digistump

  • Administrator
  • Hero Member
  • *****
  • Posts: 1465
Re: dylib upload problem on MacOSX 10.9 Mavericks
« Reply #6 on: November 08, 2014, 02:20:11 pm »

xyster

  • Newbie
  • *
  • Posts: 1
Re: dylib upload problem on MacOSX 10.9 Mavericks
« Reply #7 on: November 09, 2014, 05:07:56 am »
Hi,

I had this very same problem with the dylib as provided by the Digispark Pro getting started page. After downloading the 0.92 version you linked to here, it seems to be able to program the board. However, 0.92 also trashes my Macbook Air's keyboard and mouse. After clicking upload, both the mouse and keyboard cease responding and I have to hard power down to restart the machine.

Help!
« Last Edit: November 10, 2014, 06:58:34 am by xyster »

digistump

  • Administrator
  • Hero Member
  • *****
  • Posts: 1465
Re: dylib upload problem on MacOSX 10.9 Mavericks
« Reply #8 on: November 10, 2014, 10:47:18 am »
Good news on the dylib - that means we have it fixed like we thought.

The keyboard/mouse issue is something we see on some Macs (no rhyme or reason to which model or OSX version it seems) - I'd suggest trying a different set of ports and/or a hub - basically the USB controller is having collisions between the low speed devices, this can be seen with some other non-FTDI development boards as well.