开源改变世界

使用 1.1h 和 Arduino Uno 编译错误 #842

推推 grbl 2年前 (2023-01-23) 124次浏览

关闭
LYHTSPD 打开了这个问题 2020 年 3 月 26 日 · 1条评论

注释

使用 1.1h 和 Arduino Uno 编译错误 #842

所以,我在使用 Arduino IDE 进行编译时遇到了问题。我修改了 config.h、cpu_map.h 和 grbl.h 文件以允许我使用 Dual_Axis 选项。当我尝试编译草图时出现此错误。

Compiling sketch...
/home/pi/arduino-1.8.12/hardware/tools/avr/bin/avr-g++ -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega328p -DF_CPU=16000000L -DARDUINO=10812 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR -I/home/pi/arduino-1.8.12/hardware/arduino/avr/cores/arduino -I/home/pi/arduino-1.8.12/hardware/arduino/avr/variants/standard -I/home/pi/Arduino/libraries/grbl /tmp/arduino_build_603156/sketch/grblUpload.ino.cpp -o /tmp/arduino_build_603156/sketch/grblUpload.ino.cpp.o
In file included from /tmp/arduino_modified_sketch_75852/grblUpload.ino:2:0:
/home/pi/Arduino/libraries/grbl/planner.h:58:18: error: 'N_AXIS' was not declared in this scope
   uint32_t steps[N_AXIS];    // Step count along each axis
                  ^~~~~~
Using library grbl in folder: /home/pi/Arduino/libraries/grbl (legacy)
exit status 1
Error compiling for board Arduino Uno.

我也尝试编译 grbl 的新副本并获得相同的结果。我不知道该去哪里。
谁能帮我?

使用 1.1h 和 Arduino Uno 编译错误 #842
作者

好吧,事实证明这是我的无知。深入挖掘后,我意识到我错误地添加了 GRBL 库。

喜欢 (0)