Closed Bouni closed 9 years ago
Hi :smiley:
PlatformIO has two ways to define embedded board options:
board_mcu
and board_f_cpu
in platformio.ini
(it depends on the MCU)board
type and PlatformIO will use settings from the Framework (Arduino, Energia and etc.)In this case, no "single" command here to print supported boards. Because you can define them by self. For example, Arduino Framework has support for several boards. And with Arduino IDE you can use ONLY boards, that are defined and allowed inside it. But with PlatformIO you can use thousands third-party boards and define board_mcu
and board_f_cpu
(this information you can take from datasheet of your MCU ).
Again example: we have an Arduino Pro Mini board or similar to it that also uses the same MCU - "ATmega168". Then we can type to google "ATmega168" and follow to the first link from AVR site. OK... We have board_mcu
now. The only one thing that we need is MCU Frequency. From the AVR site we can see "Max. Operating Freq. (MHz): 20 MHz". This is MAX... :smile: You can choose board_f_cpu
between 0 and 20Mhz. But how you can define it with platformio.ini
? You should define it via Hertz. 1Mhz = 10^6Hz
or 1Mhz = 1000000Hz
. In this case, 20Mhz = 20000000Hz
. Then put this value to platformio.ini
in LONG type, like: 20Mhz = 20000000L
. Notice: Arduino IDE uses 16MHz
for "ATmega168".
Finally, these both platformio.ini
environments are the same:
[env:board_settings_from_arduino_framework]
platform = atmelavr
framework = arduino
board = pro16MHzatmega168
[env:board_settings_manually]
platform = atmelavr
board_mcu = atmega168
board_f_cpu = 16000000L
I thinks I can add ability to print supported boards for special platform via $ platformio show %PLATFORM_NAME%
. But the best way for me is extended information with ALL values (board_mcu, board_f_cpu, and etc) that will be located on separated page of new documentation.
What do you think?
I've released new documentation with "search" functionality today. In this situation is easier to support WEB-documentation then physical "boards.txt" files. Because a search result from "boards.txt" will not match with WEB-documentation.
@Bouni Sorry for the late answer. I've just implemented it and will release in the 0.10.0 release. See documentation http://docs.platformio.ikravets.com/en/latest/userguide/cmd_boards.html
Hi,
i think it would be really helpful to have some helpers/help-texts for platformio. For example when i create a platformio.ini file, i would really like to have the ability to call for example
to get a list of all valid board name rather than have to serach the online doc. Maybe this could do a query in the online docs so that i keep s up to date!