【问题标题】:Arduino not compiling - bad CPU type in executableArduino未编译-可执行文件中的CPU类型错误
【发布时间】:2020-08-17 05:39:53
【问题描述】:

最近我试图在我的 Arduino 上上传一些代码并得到这个错误:

****Arduino: 1.8.9 (Mac OS X), Board: "Arduino/Genuino Uno"

fork/exec /Users/Gu/Desktop/Every single yhing/coding stuff/Arduino.app/Contents/Java/hardware/tools/avr/bin/avr-g++: bad CPU type in executable
Error compiling for board Arduino/Genuino Uno.

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.****

我很快了解到这是由于 macOS 更新 Catalina 不再支持 32 位应用程序,而 avr-g++ 钥匙串工具是通过 32 位进程运行的。

如果有人有解决此问题的任何方法,请帮助我。

【问题讨论】:

    标签: macos arduino macos-catalina avr-gcc


    【解决方案1】:

    在为 ESP8266 编译 IDE 时遇到了同样的问题,我按照此处链接的 Arduino 论坛中的线程进行操作:

    https://forum.arduino.cc/index.php?topic=620175.0

    长话短说,我将 Arduino IDE 更新为版本 1.8.13,它在 Catalina 上对我有用。

    【讨论】:

    • @python_man 你能接受这个答案吗?这似乎是正确的步骤。
    【解决方案2】:

    对我来说,它在 Catalina 上工作:

    • 将 Arduino IDE 更新到 1.8.13
    • 在 IDE 中,将“Arduino AVR Boards”更新到最新版本(在 Mac 上,工具 -> Board:“xxxx”-> Boards Manager... -> Arduino AVR Boards)

    Access to Boards Manager in the IDE Arduino AVR Boards update location

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2013-12-14
      • 1970-01-01
      • 1970-01-01
      • 2022-06-16
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多