bdring / PendantsForFluidNC

Pendants for controlling FluidNC CNC firmware
Other
30 stars 13 forks source link

Error during LessArduino branch compilation #19

Closed robercy closed 4 months ago

robercy commented 4 months ago

Hi, I'm having this error during compilation:

Processing m5dial (platform: espressif32; board: m5stack-stamps3; framework: arduino)

Verbose mode can be enabled via -v, --verbose option CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/m5stack-stamps3.html PLATFORM: Espressif 32 (6.5.0) > M5Stack StampS3 HARDWARE: ESP32S3 240MHz, 320KB RAM, 8MB Flash DEBUG: Current (cmsis-dap) External (cmsis-dap, esp-bridge, esp-builtin, esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa) PACKAGES:

Could you help me ?

Thanks.

MitchBradley commented 4 months ago

I pushed a possible fix a few minutes ago.

robercy commented 4 months ago

Hi Mitch, thanks by you quick reply, but unfortunately didn't work. I commented SCK, MISO, MOSI and SS on platformio.ini, and get a different error.


build_flags = ${common.build_flags}

-DSCK=-1 -DMISO=-1 -DMOSI=-1 -DSS=-1

# There are no default SPI pins for S3.  M5Dial will establish the ones it needs

Error :

Processing m5dial (platform: espressif32; board: m5stack-stamps3; framework: arduino)

Verbose mode can be enabled via -v, --verbose option CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/m5stack-stamps3.html PLATFORM: Espressif 32 (6.5.0) > M5Stack StampS3 HARDWARE: ESP32S3 240MHz, 320KB RAM, 8MB Flash DEBUG: Current (cmsis-dap) External (cmsis-dap, esp-bridge, esp-builtin, esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa) PACKAGES:

MitchBradley commented 4 months ago

image

In the error you show, there is a comment character at the beginning of the highlighted line. How did that get there?

robercy commented 4 months ago

Without comments, I get the same error, and when I comment line 34 on platformio.ini, I can compile but get this error:

Error without comments: ----------------------------------------

C:/Users/Robercy/.platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal-uart.c: In function 'uartSetPins': C:/Users/Robercy/.platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal-uart.c:153:9: warning: 'return' with no value, in function returning non-void return; ^~ C:/Users/Robercy/.platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal-uart.c:149:6: note: declared here bool uartSetPins(uint8_t uart_num, int8_t rxPin, int8_t txPin, int8_t ctsPin, int8_t rtsPin) ^~~ Archiving .pio\build\m5dial\libFrameworkArduino.a Linking .pio\build\m5dial\firmware.elf Retrieving maximum program size .pio\build\m5dial\firmware.elf Checking size .pio\build\m5dial\firmware.elf Advanced Memory Usage is available via "PlatformIO Home > Project Inspect"
RAM: [= ] 8.5% (used 27960 bytes from 327680 bytes) Flash: [== ] 17.7% (used 589997 bytes from 3342336 bytes) Building .pio\build\m5dial\firmware.bin esptool.py v4.5.1 Creating esp32s3 image... Merged 3 ELF sections Successfully created esp32s3 image. ========================= [SUCCESS] Took 14.24 seconds =========================

Environment Status Duration


m5dial SUCCESS 00:00:14.240 ========================== 1 succeeded in 00:00:14.240 ==========================


It's Ok, this way, with comments on Line 34.

robercy commented 4 months ago

Anyway, with this comment, works.

MitchBradley commented 4 months ago

It turns out that line 34 was only needed for an old version of framework-arduinoespressif32 that was on my system. When I updated the platformio packages to get the new version, I had to remove that line too. I pushed the change.

The "warning: 'return' with no value," thing is a warning, not an error. It is a bug in the Arduino framework code. Complain to them. It will not cause any problems in practice because that code path is not used in FluidDial.