Hello,
My apologies again for the repeat post.
I have asked for help and received it in another post for adding the same board.
However, when I upgraded platformIO to 3.0 alpha the build system broke.
The boards folder was filled with several json files and the custom board.json was no where to be found.
So I tried again by recreating the customboard.json and initializing a new project, and thats where I got this error
Here is my board.json
{"disco_f030r8" :
{
"build": {
"core": "stm32",
"cpu": "cortex-m0",
"f_cpu": "48000000L",
"mcu": "stm32f030r8t6",
"variant": "stm32f030r8t6",
"ldscript": "stm32f03xz6.ld"
},
"frameworks": ["libopencm3","mbed","cmsis","spl"],
"platform":"ststm32",
"name": "ST STM32F030DISCOVERY",
"upload": {
"maximum_ram_size": 8192,
"maximum_size": 65536,
"protocol": "stlink"
},
"vendor": "ST"
}
}
and here is my platformio.ini
#
# PlatformIO Project Configuration File
#
# Please make sure to read documentation with examples first
# http://docs.platformio.org/en/stable/projectconf.html
#
[env:disco_f030r8]
platform = ststm32
framework = libopencm3
board = disco_f030r8
build_flags = -DSTM32F0
I just tried to reinitialize a new project in the same project folder but it failed.
Please help!!
PlatformIO 3.0 doesn’t handle multiple boards from the single manifest. Each board should be located in the own manifest. See docs Custom Embedded Boards — PlatformIO latest documentation
Please report here if it doesn’t work. That is important for us because we are going to release PlatformIO 3.0 next week.
That is exactly what I did. As I understand it is no different from custom boards in Platformio 2.x.
Create a single json file in the boards directory and pass build_flags in the platformio.ini
I tried the same thing and that is the error it threw up.
Or am I missing the point entirely??
Your manfiest is invalid for PlatformIO 3.0. It should contain JSON Object
without board ID. The file name of manifest is board id.
Try this disco_f030r8.json
:
{
"build":{
"core":"stm32",
"cpu":"cortex-m0",
"f_cpu":"48000000L",
"mcu":"stm32f030r8t6",
"variant":"stm32f030r8t6",
"ldscript":"stm32f03xz6.ld"
},
"frameworks":[
"libopencm3",
"mbed",
"cmsis",
"spl"
],
"platform":"ststm32",
"name":"ST STM32F030DISCOVERY",
"upload":{
"maximum_ram_size":8192,
"maximum_size":65536,
"protocol":"stlink"
},
"url": "http://example.com",
"vendor":"ST"
}
Thank you,
I tried doing that and also placing the same file in the default install location of board manifests.
No success…
Please remove invalid manifests from boards
folder and keep only converted from PIO2 to PIO3. PlatformIO did it automatically for you. I don’t know why do you changed it back.
Okay,
this is my boards folder structure with the files in it.
and the json file contains the code copy pasted from your earlier response.
Is this the right way??
I got it. You have missed url
field in manifest. See updated manifest above
Your manfiest is invalid for PlatformIO 3.0. It should contain JSON Object without board ID. The file name of manifest is board id.
Try this disco_f030r8.json:
{
"build":{
"core":"stm32",
"cpu":"cortex-m0",
"f_cpu":"48000000L",
"mcu":"stm32f030r8t6",
"variant":"stm32f030r8t6",
"ldscript":"stm32f03xz6.ld"
},
"frameworks":[
"libopencm3",
"mbed",
"cmsis",
"spl"
],
"platform":"ststm32",
"name":"ST STM32F030DISCOVERY",
"upload":{
"ma…
ivankravets:
{
“build”:{
“core”:“stm32”,
“cpu”:“cortex-m0”,
“f_cpu”:“48000000L”,
“mcu”:“stm32f030r8t6”,
“variant”:“stm32f030r8t6”,
“ldscript”:“stm32f03xz6.ld”
},
“frameworks”:[
“libopencm3”,
“mbed”,
“cmsis”,
“spl”
],
“platform”:“ststm32”,
“name”:“ST STM32F030DISCOVERY”,
“upload”:{
“maximum_ram_size”:8192,
“maximum_size”:65536,
“protocol”:“stlink”
},
“url”: “http://example.com ”,
“vendor”:“ST”
}
Thank you again!!
Worked like a charm!!!
Again!! Thank you so much for the help!!!
The exception dump is informative
File "platformio/managers/platform.py", line 495, in __init__
assert set(["name", "url", "vendor"]) <= set(self._manifest.keys())
AssertionError
In any case, thanks a lot for the post. Now, we are sure that this functionality works in PlatformIO 3.0
Could you try new Build System for ARM mbed?
Dear @mbed-dev ,
We have great news for ARM mbed developers! We have refactored Build System for ARM mbed OS/Framework that doesn’t require initial pre-compilation for the ARM mbed source code (we need it in PlatformIO 2.0).
The first results are impressive! PlatformIO 3.0 Build System requires a few seconds to build WHOLE ARM mbed hal/lib.
Library/Module Managment
PlatformIO 3.0 supports ARM mbed yotta module.json manifest and its features (dependencies, extra includes, etc…
Thanks, the feedback is very important for us.
Yes, I should really pay more attention to the error first instead of freaking out and posting prematurely.
I ll try and be more responsible from next time.
Please give me half a days time. I need to dig up my mbed1768 to try out on it!!
Will definitely give the appropriate feedback…
(at work )
1 Like