-
-
Notifications
You must be signed in to change notification settings - Fork 792
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Custom board with linker script for libOpenCM3 #474
Comments
You can specify full path in board's definition ( |
Hmm... I guess I could, but it's kinda not portable, if other developers
|
To make portable project you need to take a look at extra_script. You can prepend here "current project directory" to |
Also, don't forget that you can change build environment on-the-fly using |
Ok, extra_script can become a solution, but it looks like my extra script On Tue, Jan 26, 2016 at 6:37 PM, Ivan Kravets [email protected]
"One must have a chaos inside oneself to give birth to a dancing star." - |
@valeros please remove assertion https://github.com/platformio/platformio/blob/develop/platformio/builder/scripts/frameworks/libopencm3.py#L59 and allow to specify own LD Script using |
Ok, just removing assert doesn't help it - the same exception appears later, in Also, since now my custom build flag works, I wonder how can I trick the platformio to ignore the ldscript specified in board JSON configuration? Currently I specify a "common" linker script or any other ld script that exists in opencm3 sources, but it seems really ugly. Also, I can't just ignore the ldscript because JSON parser checks for this field. |
This is GOOD approach. It should work in any case. @valeros will fix
I've changed this issue to P.S: Have you tried Ukrainian PlatformIO IDE? :) |
Круто, дякую! Доречі, такий сценарій як в мене мабуть буде дуже типовий, бо мало хто в продакшені використовує всякі ардуїни, здебільшого кастомні чіпи з малою пам’яттю, бо ціна і всяке таке. То може б детальніше в доках розписати що до чого... With regards to the IDE - I'm a religious vim user, but Atom seems to be on the rise these days, so I'll definitely give it a try and spread the word about it in my team! |
Hi @zserge! Please try development version with |
Yes, I confirm that this works. Thanks for such a quick fix! |
I'm trying to use platformio with custom boards (specifically, stm32f401rb).
I've created a JSON file describing my board like this:
I use libopencm3 framework, it contains a "common" stm32f4 linker script which is supposed to be included like this (this is my
stm32f401.ld
from the config above):So the question is - where should I put my custom ldscript for my custom board? I would prefer it to be next to my sources, in my project directory.
Currently the only working location was
~/.platformio/packages/frameworks/libopencm3/lib/stm32/f4/
. Neither project root, norsrc
directory worked and printed the following error:And in fact during the first build my linker script in opencm3 source tree has been expanded and my include statement has been replaced by full contents of the
libopencm32_stm32f4.ld
.The text was updated successfully, but these errors were encountered: