DigistumpArduino icon indicating copy to clipboard operation
DigistumpArduino copied to clipboard

Micronucleus not configured correctly for MacOS

Open douglasheld2 opened this issue 3 years ago • 4 comments

If you have handling problems or questions, consider to open a discussion https://github.com/ArminJo/DigistumpArduino/discussions instead of an issue.

Bug Report

Board

  • [ x ] Digispark

IDE

  • [ x ] Arduino IDE

Example from the core libraries to reproduce the issue

Version

  • [ x ] Yes I use the latest core version and verified this!

Please delete all unchecked lines above :-)

Current behavior

  1. Install release 1.7.5 using Arduino IDE 1.8.19 on MacOS 11.5.2, on computer with 1.4 GHz Dual-Core Intel Core i5 Processor.
  2. Set Board to Digispark
  3. Set Clock to 16.5MHz
  4. Programmer is set to "Micronucleus 2.5" - which is preselected.
  5. Load "Blink" sketch from Arduino base examples.
  6. Verify (code compiles OK)
  7. Upload
  8. Error message: "/Users/douglasheld/Library/Arduino15/packages/digistump/tools/micronucleus/2.6/micronucleus" - file not found
  9. Note, directory "/Users/douglasheld/Library/Arduino15/packages/digistump/tools/micronucleus/2.5" does not exist
  10. directory "/Users/douglasheld/Library/Arduino15/packages/digistump/tools/micronucleus/2.6" contains one directory entry, "GNUSparseFile.0"
  11. directory "GNUSparseFile.0" contains one file, "micronucleus"
  12. "micronucleus" file is not an executable file type on MacOS. "/usr/bin/file" command simply reports "data".

Expected behavior

  1. Invocation of micronucleus by the IDE
  2. Choice of micronucleus should be the version installed and available
  3. Choice should match version selected/displayed in user interface menu
  4. Choice of micronucleus should be valid executable.

Additional context

  1. Note, user has copied executable from master->tools/micronucleus/micronucleus-cli-2.6-x86_64-apple-darwin.tar.gz and tried again with the executable in the expected path.
  2. This file is a MacOS executable file
  3. Running it reports "'micronucleus' cannot be opened because the developer cannot be verified." and "macOS cannot verify that this app is free from malware. Chrome downloaded this file today at 20:20 from github.com."
  4. Presumably, the executable is built without a valid digital signature. So, it cannot be used as a workaround for the problem with release 1.7.5.

douglasheld2 avatar Jan 01 '22 21:01 douglasheld2

Downgrading to release 1.7.4 seems to work fine (with micronucleus 2.5)

douglasheld2 avatar Jan 01 '22 21:01 douglasheld2

Have you tried the ATTiny core with Mac? Does it have the same problems?

ArminJo avatar Jan 02 '22 10:01 ArminJo

Regarding "'micronucleus' cannot be opened because the developer cannot be verified",

This is a problem with Micronucleus. Reported here https://github.com/micronucleus/micronucleus/issues/258

douglasheld2 avatar Jan 02 '22 19:01 douglasheld2

Have you tried the ATTiny core with Mac? Does it have the same problems?

Thank you for the suggestion. I did try ATTIny Core version 1.5.2. It is bundling micronucleus version 2.5 and works correctly; so it is functionally equivalent to downgrading to 1.7.4.

douglasheld2 avatar Jan 02 '22 19:01 douglasheld2