Updating Platformio
Sometimes, when building and uploading the firmware, you may run into bizarre, even-though the code is correct - platformio will refuse to build and instead will complain with some weird error.
It usually means that either PlatformIO, or ArduinoSDK got and update and that's the moment when this guide may come in handy.
Updating PlatformIO itself
There are two ways to update your platformio installation
Via CLI
You can update it easily by simply typing in one command into your terminal.
- Open a terminal / command prompt
- Type
pio upgrade
and press enter - Wait for it to finish
- Done
Via PlatformIO in Visual Studio Code
You can also update it using the platformio tab in your Visual Studio Code.
- Open VSC
- Click on that little and icon on the sidebar
- A side panel will open, there will be a couple of sections, one of them called
Quick Access
, open it.
- In
Quick Access
section, click on theMiscelleneous
tab
- Then, click on the
Upgrade PlatformIO Core
- Wait for it to finnish and done!
Upgrading the SDK
You'll also need to upgrade the SDK from timem to do this
Upgrading the SDK via VSC
- Follow the guide above up until clicking on the
Quick Access
section. - Instead, open the
PIO Home
and selectOpen
- This will open a window for PlatformIO dashboard, in there, click on a
Platforms
button on the sidebar
- Once there, you should see a couple of tabs next to the side bard, things like
Installed
orEmbedded
. Click onUpdates
- Locate a platform called
Espressif 32
and click onUpdate to <version>
- Wait until it is done and that's it!