2

I'm using quite a few different types of microcontrollers with the Arduino IDE (v 1.8.19). Several AVR-based boards, but also ESP32 and Arduino Due. Particularly the newer boards have a quite long set of options in the tool menu, as seen in this screen shot (for an ESP32-Dev module).

List of menu options

Each time I swap boards, the settings revert back to defaults and I have to remember updating them according to my needs. Is there a way to save the current IDE configuration, so that I can easily load all the settings I need for e.g. "ESP32"? When I haven't used a certain board for some time, I often even fail to remember exactly what settings I needed.

asked Nov 13, 2022 at 20:05
6
  • I didn't find a way Commented Nov 13, 2022 at 20:20
  • @Juraj Thanks for trying. Maybe someone knows a way to backup a settings file or something. Because at least the IDE remembers the last settings. Commented Nov 13, 2022 at 20:24
  • 1
    even the IDE 2 doesn't have it. only the WebEditor and CLI have it arduino.github.io/arduino-cli/0.28/sketch-specification/… Commented Nov 13, 2022 at 20:33
  • 2
    a workaround could be to define own board in boards.local.txt with all the settings predefined Commented Nov 13, 2022 at 20:38
  • 3
    One of the many reasons people switch to VS Code + platformIO plugin for Arduino programming. It configures the setting on each project with platformio.ini file. Commented Nov 15, 2022 at 1:21

1 Answer 1

3

You can save and restore your board settings by using the preferences.txt file, as Juraj mentioned. The settings for the selected board are stored in this file. You can find its location here.

For example, if you select "ESP32 Dev Module" and then close the IDE, preferences.txt will include settings like:

board=esp32
...
custom_CPUFreq=esp32_240
(snip)

By backing up this file before switching boards and restoring it later, you can bring back your previous settings. Just make sure to close the IDE before modifying or replacing the file.

Hope this helps!

answered Feb 10 at 12:02
1
  • 2
    Is a workaround, but might still be useful. Commented Feb 10 at 12:17

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.