Skip to content

Passing additional configuration to arduino-cli compile #698

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

Closed
panigrah opened this issue May 9, 2020 · 1 comment
Closed

Passing additional configuration to arduino-cli compile #698

panigrah opened this issue May 9, 2020 · 1 comment

Comments

@panigrah
Copy link

panigrah commented May 9, 2020

Arduino-ide allows setting up of additional build parameters specific to each board. e.g. when building for an esp32 board i can set configuration parameters such as partition in the arduino IDE.

How do I configure a partition when using arduino-cli? It always picks the default.

@per1234
Copy link
Contributor

per1234 commented May 9, 2020

You do this by specifying the board configuration options in the arduino-cli command's --fqbn option.

For example, if you wanted to compile with the equivalent of having the Tools > Partition Scheme > Minimal (1.3MB APP/700KB SPIFFS) setting selected in the Arduino IDE, you would use this command:

arduino-cli compile --fqbn esp32:esp32:esp32:PartitionScheme=minimal

As you discovered, when you don't specify a configuration option value in the FQBN (e.g., esp32:esp32:esp32), the default option is used.

I have provided more information on how custom boards options work with FQBNs and how to determine the correct FQBN in these earlier issues:

We probably do need to further improve the documentation to make this easier for the Arduino CLI users, but we have an existing issue about that (#355), so I'll go ahead and close this one.

@per1234 per1234 closed this as completed May 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants