Welcome! Log In Create A New Profile

Advanced

Common build issues in platformio at present.

Posted by Dust 
Common build issues in platformio at present.
June 27, 2020 12:53AM
There are a number of common build issues at the moment that you may encounter when you attempt to build marlin in vscode / platformio.

These are mostly related to Marlin dependencies that have been updated since release, breaking Marlin building.

These issues have been addressed in bugfix, but older marlin will continue to break as they are not updated.
A new release is coming that will resolve these issue.

This is accurate as of 27 Jun 2020

Issue 1: You get this error.
Marlin\src\HAL\STM32F1\dogm\../../../inc/../HAL/./STM32F1/fastio.h:30:10: fatal error: libmaple/gpio.h: No such file or directory:
The cause is ST STM32 framework was updated to version 7. Marlin was built on version 6.
The fix is up update your platformio.ini file
Find and replace the line "platform = ststm32" with "platform = ststm32@<6.2.0"

Issue 2: You get this error.
Adafruit BusIO_ID6214\Adafruit_I2CDevice.cpp:160:79: error: no matching function for call to 'TwoWire::requestFrom(uint8_t, uint8_t, uint8_t)'
Any errors that mention Adafruit BusIO
The fix is up update your platformio.ini file
Find the line "Adafruit_MAX31865=https://github.com/adafruit/Adafruit_MAX31865/archive/master.zip" and replace it with
"Adafruit MAX31865 library@~1.1.0"


Issue 3: You get these errors
error: 'X_HOME_BUMP_MM' was not declared in this scope
error: 'Y_HOME_BUMP_MM' was not declared in this scope
error: 'Z_HOME_BUMP_MM' was not declared in this scope
your Configuration_adv.h has the following (this is newer than the code expects)
#define HOMING_BUMP_MM { 5, 5, 2 }
when this version of code needs
#define X_HOME_BUMP_MM 5
#define Y_HOME_BUMP_MM 5
#define Z_HOME_BUMP_MM 2
Simply replace the first line with these 3 lines.

Issue 4: You get these warnings.
c_cpp_properties.json",
	Cannot find "Marlin-2.0.x/include"
	Cannot find "Marlin-2.0.x/include"
These are just warning an should be ignored.
The cause is that platformio expects all projects to have a include directory in the project. Marlin doesn't do this.

Issue 5: You get this error
Marlin\src\feature/leds/neopixel.h:34:10: fatal error: Adafruit_NeoPixel.h: No such file or directory
In platformio.ini, some platforms have Adafruit NeoPixel disabled with the line
lib_ignore = Adafruit NeoPixel, SPI
remove the Adafruit NeoPixel part to make it "lib_ignore = SPI"
But this is often disabled for a good reasion.

Issue 6: You get this error
"NeoPixel_ID28/Adafruit_NeoPixel.h:361:3: error: 'GPIO_TypeDef' does not name a type"
In platformio.ini normally found in [common] section you need to change
Adafruit NeoPixel to Adafruit NeoPixel@<=1.2.4

Edited 8 time(s). Last edit at 06/27/2020 10:11AM by Dust.
Re: Common build issues in platformio at present.
August 06, 2020 07:16AM
Thanks Dust,
great Post. Also great seeing You still active. Do you remember me?

I get this Error:

Archiving .pio\build\mks_robin_nano\lib119\libSailfishLCD.a
C:\Users\Ahmet\.platformio\packages\framework-arduinoststm32-maple\STM32F1\libraries\STM32ADC\src\utility\util_adc.c:10:30: warning: 'adc_result' initialized and declared 'extern'
extern volatile unsigned int adc_result = 0;
^~~~~~~~~~
Archiving .pio\build\mks_robin_nano\lib916\libSlowSoftI2CMaster.a
Compiling .pio\build\mks_robin_nano\liba5f\libmaple\libmaple\dma.c.o
.pio\libdeps\mks_robin_nano\libmaple\libmaple\adc.c:47:6: error: conflicting types for 'adc_init'

Edited 1 time(s). Last edit at 08/06/2020 07:24AM by ahmetcemturan.


Manufacturer of low tolerance Filaments PLA, ABS, ASA, PETG, TPU, PA, PVA,
[www.miafilament.com]
[github.com]
Re: Common build issues in platformio at present.
August 07, 2020 03:21AM
Great write, put it up as a sticky thumbs up


http://www.marinusdebeer.nl/
Re: Common build issues in platformio at present.
August 07, 2020 03:54AM
It was 'sticky' for a month or so. but all the ones I listed are now resolved. You would only get them if your trying to compile older versions without the updated platformio.ini files
Re: Common build issues in platformio at present.
August 07, 2020 03:56AM
Quote
Dust
It was 'sticky' for a month or so. but all the ones I listed are now resolved. You would only get them if your trying to compile older versions without the updated platformio.ini files

Oh thanks for letting me know. I thought this was a new topic. I must've missed the posting date.


http://www.marinusdebeer.nl/
Sorry, only registered users may post in this forum.

Click here to login