Skip to content
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

Add more help-texts #11

Closed
Bouni opened this issue Aug 7, 2014 · 3 comments
Closed

Add more help-texts #11

Bouni opened this issue Aug 7, 2014 · 3 comments
Assignees
Milestone

Comments

@Bouni
Copy link

Bouni commented Aug 7, 2014

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

$ platformio boards

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!

@ivankravets ivankravets added this to the 1.0.0 milestone Aug 7, 2014
@ivankravets
Copy link
Member

Hi 😃

PlatformIO has two ways to define embedded board options:

  1. Define directly board_mcu and board_f_cpu in platformio.ini (it depends on the MCU)
  2. Define 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... 😄 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?

@ivankravets
Copy link
Member

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.

@ivankravets ivankravets self-assigned this Nov 30, 2014
@ivankravets ivankravets modified the milestones: 0.10.0, 1.0.0 Dec 19, 2014
@ivankravets
Copy link
Member

@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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants