Problem uploading to CR-10 printer

I am a new user to platformio, but have used the Arduino IDE for updating Marlin firmware on my CR-10S 3d printer. I am running Ubuntu Linux 16.04, and platformio 3.5.2 which I believe is installed correctly and is up-to-date. In the Marlin configuration, the board is defined as a RAMPS EFB, and this is working well using the Arduino IDE. Using platformio, I have configured Marlin, have run build, and also run upload. The build and upload appear to run successfully, including the upload, but when I restart the printer I am met with a blue screen and an inoperative printer. I would include the text of the terminal window, but I am apparently unable to do that yet since this is my first post. I see the READING, WRITING, and READING (again) progress bars, and the last line reads:
“========================= [SUCCESS] Took 36.19 seconds =========================” and the window borders etc. all turn green.

The only indication of anything being out of the ordinary is the first three lines when the build starts:

Blockquote
Warning! Ignore unknown envs_dir option in [platformio] section
Processing megaatmega2560 (platform: atmelavr; board: megaatmega2560; framework: arduino)

Warning! board_f_cpu option is deprecated and will be removed in the next release! Please use board_build.f_cpu instead.

I hope I have given enough info for someone to get me pointed in the right direction.

Wayne

No, please pio upgrade.

Thanks for the tip, but after upgrading platformio to 3.5.4, the problem still exists without change.

Could you post this issue to Issues · MarlinFirmware/Marlin · GitHub?

I don’t think this is a Marlin issue since I can use the very same firmware with Arduino IDE, coded line by line the same as with platformio, and it works.

I admit that I am VERY new to this, so please explain why you think this is a Marlin issue.

(I hope that doesn’t come across as being snippy because it is certainly not meant to.)

Wayne

Could you provide “Dependency Graph” here? You will see it when start project building.

I’m having a spot of bother getting the data into proper format. Most of the text is not being displayed.

Wayne

Scanning dependencies…
Dependency Graph
|-- “U8glib” 1.19.1
|-- “TMC2130Stepper” 2.4.3
| |-- “SPI” 1.0
|-- “Adafruit NeoPixel” 1.1.6
|-- “LiquidTWI2” #30aa480
| |-- “Wire” 1.0
|-- “TMC26XStepper” #c1921b4
| |-- “SPI” 1.0
|-- “SoftwareSerial” 1.0
|-- “Wire” 1.0
|-- “LiquidCrystal” 1.0.5
|-- “SPI” 1.0
Compiling .pioenvs/megaatmega2560/src/Marlin.ino.cpp.o

I had to replace all of the greater than and less than symbols with quotation marks

Next time please use triple of “```” before and after source code.

Nevertheless, please edit platformio.ini and find [env:megaatmega2560] section. Try to add this line lib_archive = false. Reflash board. Does it work now?

Modified platformio.ini as below -

[env:megaatmega2560]
platform = atmelavr
framework = arduino
board = megaatmega2560
build_flags = ${common.build_flags}
board_f_cpu = 16000000L
lib_deps = ${common.lib_deps}
lib_archive = false

No change. Still does not load properly.

Wayne

I have finally been able to properly upload firmware to my printer. I think the problem just came down to not fully understanding what a “project” was. I did mention that I was VERY new to this, didn’t I? In my initial setup, I had cloned Marlin 2.0 into a folder called “Marlin 2.0” using git. then in Platformio, I opened that folder as a project. Next, still in Platformio, I Duplicated that into a folder called “Max_BLinear”. I then made all of the configuration changes I needed to make in the “Max_BiLinear” copy. All the intermedite Build operations I performed in the process all completed successfully. I was a little concerned about the program size never changing, but I chalked that up to my inexperience. That’s my story and I’m sticking to it. What dawned on me later was that the firmware that was being compiled was the initial “Marlin 2.0” folder with none of the changes I made to “Max_BiLinear”. This resulted in firmware being upload successfully, but for starters it had the wrong display configured so of course the printer display was blank.

So what I have done is remove all project folders and started with a blank slate. I now just open the one project folder I want to update, Like Max_BiLinear for example (I Duplicated 4 copies), make the changes I want, Build, and Upload. TaDaaaaa.

I still have a lot of learning to do, especially using git for now. But this issue is resolved as a ID 10 T error.

Wayne