Your new topic does not fit any of the above??? Check first. Then post here. Thanks.

Moderator: igrr

User avatar
By btidey
#76996 [TIP]

My Arduino IDE has both the ESP8266 and ESP32 support which works well but makes switching boards a bit of a nightmare. The boards selection menu was very long and I had to make sure to remember to switch things like memory configuration and programming method every time I changed board type.

To simplify this I edited the boards.txt in both the esp8266 and the esp32 branches (having taken back ups). Even if one just has an esp8266 set up the simplification can be worthwhile.

The edits were basically to remove all the board sections I never use and also to put my default selection for a parameter at the top so that it is immediately chosen once the board is selected.

Removing whole boards is fairly obvious as all their parameters are grouped together under the board name.

In my case I ended up with 2 boards in the esp8266 file (espuino and esp8266 generic) and 1 board in the esp32. By moving the memory section for the ESP8266 cases I use up (4M 3M SPIFFS) that becomes the defualt and avoids inadvertent slips which can wipe out existing SPIFFS set up.

Obviously updating boards.txt from elsewhere would wipe the changes so I also back up my changed files.
User avatar
By rudy
#76998 I took a different approach. Not as efficient as you though.

When I decided to start with the ESP32 last year I was concerned about things getting messy as far as libraries and other differences. So I bought another computer. A refurbished off lease HP. I'm able to run two monitors off it so I also set up this computer for PCB layout. So far it hasn't had much use since I haven't had much time to focus on those.

It did come in handy as a backup computer when my old computer refused to work for a week.
User avatar
By btidey
#77001 Yes. Can also be good to separate things well between esp32 and esp8266. Library usage can get messy.

My motivation started from esp8266 having 26 board variants and esp32 with 33. Either seems a bit excessive particularly as a lot of them differ hardly at all. I guess people feel more comfortable selecting their own brand board name but in reality one still often has to check / modify some of the parameters.

I guess it would be even better if the IDE had a method of choosing favorites or hiding stuff.
User avatar
By btidey
#77002 Digging around a bit further I tried this technique for separating out the esp32 and esp8266 environments on the same machine and it works very nicely.

Starting up arduino allows for command line options https://github.com/arduino/Arduino/blob ... npage.adoc

I used --preferences-file filename to allow starting up the IDE with a different preferences file. This means things like sketchbook folder and last board / sketch used are kept separately.

I copied my existing preferences file which in my case was in D:\Utils\Arduino\portable\preferences.txt and renamed it to preferences32.txt

I then copied the Arduino start up shortcut and renamed it Arduino32

I added --preferences-file D:\Utils\Arduino\portable\preferences32.txt onto the target for the new shortcut.

Starting with the arduino32 shortcut now uses the new preferences file and allows a different sketchbook location to be used. It also retains the board selection and last / recent sketches independently of the esp8266 environment.