Welcome! Log In Create A New Profile

Advanced

Unable to compile Marlin 2.0.7.2

Posted by e415ldc 
Unable to compile Marlin 2.0.7.2
December 20, 2020 01:32PM
I'm using the latest Win10 App Store download if Arduino IDE. The Motherboard is configured as the GT2650 A Plus. The error comes during the final linking process. The error does not seem to give any clues as to what is wrong. I can compile the 2.0.1 version of Marlin without issues. This is just a compile, I am not attempting to "push" the code to my GT2650 at this time.

The log from the compile is attached (I hope).

Thank you in advance for any help.
Re: Unable to compile Marlin 2.0.7.2
December 20, 2020 01:39PM
My attachment didn't seem to work. I'll try again using a zip file.
Attachments:
open | download - 207error.zip (28.9 KB)
Re: Unable to compile Marlin 2.0.7.2
December 20, 2020 05:44PM
This is a Arduino IDE on Windows issue. Windows has a hard coded unchangeable max path/fork limit of 32K characters. Arduino IDE is written badly, when it attempts to link all the .o files together to form the final .bin file on large projects, such as Marlin, it generate one very long command that can easily exceed the windows limit.

There are a number of tricks to shorten the path under windows.
Move marlin to root of drive, rename it to m
Delete unused parts of marlin such as unused HAL directories and unused display types. But this require in depth knowledge of how marlin works to know what is safe to remove.

Ultimately it is far better to use PlatformIO on vscode instead of Arduino IDE
PlatformIO only complies and links the code you need for your system, this avoids the Windows limitation. It also produces smaller binaries and is faster.
Re: Unable to compile Marlin 2.0.7.2
December 20, 2020 06:16PM
I'm a retired networking tech (CNE 3,4,5,6). It looked like a pathing issue to me, but I wasn't sure.

I have never even seen the PlatformIO you speak of. Where and how would I access it?

Thank you again.
Re: Unable to compile Marlin 2.0.7.2
December 20, 2020 06:33PM
See Marlin documentation [marlinfw.org]
Re: Unable to compile Marlin 2.0.7.2
December 20, 2020 07:49PM
Thank you.

I hadn't seen the VSCode page previously. Looks like I get to start learning again.*>)

Thank you again.
Re: Unable to compile Marlin 2.0.7.2
December 20, 2020 11:33PM
I finally got a successful compile after about 4 hours of "learning". I have three different printers and at least 3 different versions of code for each as I test new features. Each of these 9+ versions have a unique directory structure, none of them are "marlin". Once I pulled a fresh copy of 2.0.7.2 and then copied in my unique config files, I was able to "import" one set of code and compile it. But I still can't figure out how to configure the upload and then do the upload.

Time for sleep.

Again thank you.
Re: Unable to compile Marlin 2.0.7.2
December 20, 2020 11:40PM
uploads methods are defined in the platformio.ini files.

not all boards have automatic uploads, notably a lot of stm32f103 boards, that have usb/serial chips, have dumb boot loaders that only read firmware from the onboard sdcard.

lpc176x based boards mount the sdcard as a drive and just copy the firmware to that drive, (uploading firmware is still only done on board reset)
Re: Unable to compile Marlin 2.0.7.2
December 20, 2020 11:57PM
I'm using GT2560 boards. So USB is the only option.
Re: Unable to compile Marlin 2.0.7.2
December 21, 2020 12:12AM
actually it not, but it is the most common.
You can install a bootloader that loads from sd card on that also.

Unfortunately for the atmega2560 there are a number of options for the boot loader. Which use different protocols and upload baud rates.
Guessing what it has can be time consuming.
It is often far easier to upload a known boot loader where you know the protocol and baudrate.

also many cheap suppliers do not even install a boot loader...
I believe the GT2560 is one that doesn't normally comes with a boot loader... so you need to install one, or use a AVRISP to directly put firmware on the board.
Re: Unable to compile Marlin 2.0.7.2
December 21, 2020 10:20AM
So I can't just upload the code via the serial port like I do with the Arduino IDE?

Than, I REALLY have a bunch of learning to do. Are there any tutorials directly related to the Geeetech version of the board? If not I guess I'm stuck on 2.0.1 with my modification to remove the Z axis debug info during an extract.

Thank you again.
Sorry, only registered users may post in this forum.

Click here to login