PlatformIO is written in Python and works on Mac OS X, Linux, Windows OS and ARM-based credit-card computers (Raspberry Pi, BeagleBoard, CubieBoard).
- Operating systems:
- Mac OS X
- Linux, +ARM
- Windows
- Python 2.6 or Python 2.7
All commands below should be executed in Command-line application:
- Mac OS X / Linux this is Terminal application.
- Windows this is Command Prompt (
cmd.exe
) application.
Warning
If you are going to run PlatformIO from subprocess, you MUST DISABLE all prompts. It will allow you to avoid blocking. There are a few options:
- using environment variable
PLATFORMIO_SETTING_ENABLE_PROMPTS=No <envvar_PLATFORMIO_SETTING_ENABLE_PROMPTS>
- disable global setting
enable_prompts
viacmd_settings
command - masking under Continuous Integration system via environment variable
CI=true <envvar_CI>
.
Please choose one of the following:
To install or upgrade PlatformIO paste that at a Terminal prompt (you might need to run sudo
first):
python -c "$(curl -fsSL https://raw.githubusercontent.com/ivankravets/platformio/master/scripts/get-platformio.py)"
To install or upgrade PlatformIO, download get-platformio.py script. Then run the following (you might need to run sudo
first):
python get-platformio.py
On Windows OS it may look like:
C:\Python27\python.exe get-platformio.py
Warning
If you have an error pkg_resources.DistributionNotFound
please upgrade SetupTools package: $ [sudo] pip uninstall setuptools
and $ [sudo] pip install setuptools
. Then re-install PlatformIO: $ [sudo] pip uninstall platformio
and $ [sudo] pip install platformio
.
- Check a
python
version (only 2.6-2.7 is supported):
$ python --version
Windows OS Users only:
- Download Python 2.7 and install it.
- Add to PATH system variable
;C:\Python27;C:\Python27\Scripts;
andreopen Command Prompt (
cmd.exe
) application. Please read this article How to set the path and environment variables in Windows.
- Check a
pip
tool for installing and managing Python packages:
$ pip search platformio
You should see short information about platformio
package.
If your computer does not recognize pip
command, try to install it first using these instructions.
- Install a
platformio
and related packages:
$ pip install platformio && pip install --egg scons
For upgrading the platformio
to new version please use this command:
$ pip install -U platformio
Warning
We don't recommend to use develop
version in production.
- If you had have already installed PlatformIO, please uninstall it:
$ pip uninstall platformio
- Install the latest PlatformIO from the
develop
branch:
$ pip install https://github.com/ivankravets/platformio/archive/develop.zip
If you want to be up-to-date with the latest develop
version of PlatformIO, then you need to perform step #2 each time if you see the new commits in PlatformIO GitHub repository.