Skip to content

Commit

Permalink
Merge branch 'release/v0.3.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
ivankravets committed Jun 21, 2014
2 parents 6b9b780 + c10e76f commit 75dcb0b
Show file tree
Hide file tree
Showing 45 changed files with 904 additions and 84 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,5 @@
.pioenvs
.tox
.sconsign.dblite
examples/ide-eclipse/.metadata
examples/ide-eclipse/RemoteSystemsTempFiles
10 changes: 10 additions & 0 deletions HISTORY.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,16 @@
Release History
===============

0.3.0 (2014-06-21)
---------

* Allowed to pass multiple "SomePlatform" to install/uninstall commands
* Added "IDE Integration" section to README with Eclipse project examples
* Created auto installer script for *PlatformIO* (`issue #3 <https://github.com/ivankravets/platformio/issues/3>`_)
* Added "Super-Quick" way to Installation section (README)
* Implemented "build_flags" option for environments (`issue #4 <https://github.com/ivankravets/platformio/issues/4>`_)


0.2.0 (2014-06-15)
------------------

Expand Down
67 changes: 52 additions & 15 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -10,19 +10,22 @@ PlatformIO
.. image:: https://pypip.in/version/platformio/badge.png
:target: https://pypi.python.org/pypi/platformio/
:alt: Latest Version
.. image:: https://pypip.in/download/platformio/badge.png
:target: https://pypi.python.org/pypi/platformio/
:alt: Downloads
.. image:: https://pypip.in/license/platformio/badge.png
:target: https://pypi.python.org/pypi/platformio/
:alt: License


**Platformio** is a console tool to build code with different development
**PlatformIO** is a console tool to build code with different development
platforms.

You have no need to install any *IDE* or compile any toolchains. *Platformio*
You have no need to install any *IDE* or compile any toolchains. *PlatformIO*
has pre-built different development platforms including: compiler, debugger,
flasher (for embedded) and many other useful tools.

**Platformio** allows developer to compile the same code with different
**PlatformIO** allows developer to compile the same code with different
platforms using only one command ``platformio run``. This happens due to
``platformio.ini`` project's file (see
`default template <https://github.com/ivankravets/platformio/blob/develop/platformio/projectconftpl.ini>`_)
Expand All @@ -33,7 +36,12 @@ Each platform consists of packages which are located in own repository.
Due to ``platformio update`` command you will have up-to-date development
instruments.

**Platformio** is well suited for **embedded development**. It can:
.. image:: examples/platformio-examples.png
:target: https://github.com/ivankravets/platformio/raw/develop/examples/platformio-examples.png
:alt: Examples
:width: 730px

**PlatformIO** is well suited for **embedded development**. It can:

* Automatically analyse dependency
* Reliably detect build changes
Expand All @@ -56,10 +64,16 @@ It has support for many popular embedded platforms like these:
See project `examples with screenshots <https://github.com/ivankravets/platformio/tree/develop/examples>`_.


IDE Integration
---------------

* [Eclipse] `Building and debugging Atmel AVR (Arduino-based) project using Eclipse IDE+PlatformIO <http://www.ikravets.com/computer-life/programming/2014/06/20/building-and-debugging-atmel-avr-arduino-based-project-using-eclipse-ideplatformio>`_


Python & OS Support
-------------------

**Platformio** is written in `Python <https://www.python.org>`_ and works with
**PlatformIO** is written in `Python <https://www.python.org>`_ and works with
versions 2.6 and 2.7 on Unix/Linux, OS X, and Windows.


Expand All @@ -68,9 +82,6 @@ Quickstart

.. code-block:: bash
# Install platformio
$ pip install platformio && pip install --egg scons
# Print all availalbe development platforms for installing
$ platformio search all
Expand All @@ -93,29 +104,55 @@ Installation

All commands below should be executed in
`Command-line <http://en.wikipedia.org/wiki/Command-line_interface>`_
application in your OS:
application in your *OS*:

* *Unix/Linux/OS X* this is *Terminal* application.
* *Windows* this is
`Command Prompt <http://en.wikipedia.org/wiki/Command_Prompt>`_ (``cmd.exe``)
application.

2. Check a ``python`` version:
Also, the `Python Interpreter <https://www.python.org/downloads/>`_ (2.6 or 2.7)
is required.


Super-Quick
~~~~~~~~~~~

To install or upgrade *PlatformIO*, download
`get-platformio.py <https://raw.githubusercontent.com/ivankravets/platformio/develop/scripts/get-platformio.py>`_ script.

Then run the following (which may require administrator access):

.. code-block:: bash
$ python get-platformio.py
On *Windows OS* it may look like:

.. code-block:: bash
C:\Python27\python.exe get-platformio.py
Full Guide
~~~~~~~~~~

1. Check a ``python`` version (only 2.6-2.7 is supported):

.. code-block:: bash
$ python --version
Windows OS Users only:
*Windows OS* Users only:

* `Download Python <https://www.python.org/downloads/>`_ and install it.
* `Download Python 2.7 <https://www.python.org/downloads/>`_ and install it.
* Add to PATH system variable ``;C:\Python27;C:\Python27\Scripts;`` and
reopen *Command Prompt* (``cmd.exe``) application. Please read this
article `How to set the path and environment variables in Windows
<http://www.computerhope.com/issues/ch000549.htm>`_.


2. Check a ``pip`` tool for installing and managing Python packages:
2. Check a ``pip`` tool for installing and managing *Python* packages:

.. code-block:: bash
Expand Down Expand Up @@ -193,7 +230,7 @@ Search for development platforms:
``platformio install``
~~~~~~~~~~~~~~~~~~~~~~

*Platformio* has pre-built development platforms with related packages. You
*PlatformIO* has pre-built development platforms with related packages. You
can install one of them:

.. code-block:: bash
Expand Down Expand Up @@ -294,7 +331,7 @@ Initialize new platformio based project.
After this command ``platformio`` will create:
* ``.pioenvs`` - a temporary working directory.
* ``lib`` - a directory for project specific libraries. Platformio will
* ``lib`` - a directory for project specific libraries. PlatformIO will
compile their to static libraries and link to executable file
* ``src`` - a source directory. Put code here.
* ``platformio.ini`` - a configuration file for project
Expand Down
14 changes: 14 additions & 0 deletions examples/ide-eclipse/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
Eclipse IDE Integration
=======================

The detailed information and steps are described in this article:
`Building and debugging Atmel AVR (Arduino-based) project using Eclipse IDE+PlatformIO <http://www.ikravets.com/computer-life/programming/2014/06/20/building-and-debugging-atmel-avr-arduino-based-project-using-eclipse-ideplatformio>`_.


.. image:: http://www.ikravets.com/wp-content/uploads/2014/06/eclipse_build_arduino_pro5v-1024x822.png
:width: 850px
:target: http://www.ikravets.com/computer-life/programming/2014/06/20/building-and-debugging-atmel-avr-arduino-based-project-using-eclipse-ideplatformio

.. image:: http://www.ikravets.com/wp-content/uploads/2014/06/eclipse_debugging_result_1-1024x775.png
:width: 850px
:target: http://www.ikravets.com/computer-life/programming/2014/06/20/building-and-debugging-atmel-avr-arduino-based-project-using-eclipse-ideplatformio
77 changes: 77 additions & 0 deletions examples/ide-eclipse/arduino_pro5/.cproject
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<?fileVersion 4.0.0?>

<cproject storage_type_id="org.eclipse.cdt.core.XmlProjectDescriptionStorage">
<storageModule moduleId="org.eclipse.cdt.core.settings">
<cconfiguration id="0.910961921">
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="0.910961921" moduleId="org.eclipse.cdt.core.settings" name="Default">
<externalSettings/>
<extensions>
<extension id="org.eclipse.cdt.core.VCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.CWDLocator" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GCCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GLDErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
</extensions>
</storageModule>
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
<configuration artifactName="${ProjName}" buildProperties="" description="" id="0.910961921" name="Default" parent="org.eclipse.cdt.build.core.prefbase.cfg">
<folderInfo id="0.910961921." name="/" resourcePath="">
<toolChain id="org.eclipse.cdt.build.core.prefbase.toolchain.952979152" name="No ToolChain" resourceTypeBasedDiscovery="false" superClass="org.eclipse.cdt.build.core.prefbase.toolchain">
<targetPlatform id="org.eclipse.cdt.build.core.prefbase.toolchain.952979152.52310970" name=""/>
<builder id="org.eclipse.cdt.build.core.settings.default.builder.1519453406" keepEnvironmentInBuildfile="false" managedBuildOn="false" name="Gnu Make Builder" superClass="org.eclipse.cdt.build.core.settings.default.builder"/>
<tool id="org.eclipse.cdt.build.core.settings.holder.libs.1409095472" name="holder for library settings" superClass="org.eclipse.cdt.build.core.settings.holder.libs"/>
<tool id="org.eclipse.cdt.build.core.settings.holder.1624502120" name="Assembly" superClass="org.eclipse.cdt.build.core.settings.holder">
<option id="org.eclipse.cdt.build.core.settings.holder.incpaths.239157887" superClass="org.eclipse.cdt.build.core.settings.holder.incpaths" valueType="includePath">
<listOptionValue builtIn="false" value="&quot;${HOME}/.platformio/atmelavr/tools/toolchain/avr/include&quot;"/>
<listOptionValue builtIn="false" value="&quot;${HOME}/.platformio/atmelavr/frameworks/arduino/cores/arduino&quot;"/>
</option>
<option id="org.eclipse.cdt.build.core.settings.holder.symbols.922107295" superClass="org.eclipse.cdt.build.core.settings.holder.symbols" valueType="definedSymbols">
<listOptionValue builtIn="false" value="__AVR_ATmega168__"/>
</option>
<inputType id="org.eclipse.cdt.build.core.settings.holder.inType.149990277" languageId="org.eclipse.cdt.core.assembly" languageName="Assembly" sourceContentType="org.eclipse.cdt.core.asmSource" superClass="org.eclipse.cdt.build.core.settings.holder.inType"/>
</tool>
<tool id="org.eclipse.cdt.build.core.settings.holder.54121539" name="GNU C++" superClass="org.eclipse.cdt.build.core.settings.holder">
<option id="org.eclipse.cdt.build.core.settings.holder.incpaths.1096940598" superClass="org.eclipse.cdt.build.core.settings.holder.incpaths" valueType="includePath">
<listOptionValue builtIn="false" value="&quot;${HOME}/.platformio/atmelavr/tools/toolchain/avr/include&quot;"/>
<listOptionValue builtIn="false" value="&quot;${HOME}/.platformio/atmelavr/frameworks/arduino/cores/arduino&quot;"/>
</option>
<option id="org.eclipse.cdt.build.core.settings.holder.symbols.1198905600" superClass="org.eclipse.cdt.build.core.settings.holder.symbols" valueType="definedSymbols">
<listOptionValue builtIn="false" value="__AVR_ATmega168__"/>
</option>
<inputType id="org.eclipse.cdt.build.core.settings.holder.inType.762536863" languageId="org.eclipse.cdt.core.g++" languageName="GNU C++" sourceContentType="org.eclipse.cdt.core.cxxSource,org.eclipse.cdt.core.cxxHeader" superClass="org.eclipse.cdt.build.core.settings.holder.inType"/>
</tool>
<tool id="org.eclipse.cdt.build.core.settings.holder.1310559623" name="GNU C" superClass="org.eclipse.cdt.build.core.settings.holder">
<option id="org.eclipse.cdt.build.core.settings.holder.incpaths.41298875" superClass="org.eclipse.cdt.build.core.settings.holder.incpaths" valueType="includePath">
<listOptionValue builtIn="false" value="&quot;${HOME}/.platformio/atmelavr/tools/toolchain/avr/include&quot;"/>
<listOptionValue builtIn="false" value="&quot;${HOME}/.platformio/atmelavr/frameworks/arduino/cores/arduino&quot;"/>
</option>
<option id="org.eclipse.cdt.build.core.settings.holder.symbols.884639970" superClass="org.eclipse.cdt.build.core.settings.holder.symbols" valueType="definedSymbols">
<listOptionValue builtIn="false" value="__AVR_ATmega168__"/>
</option>
<inputType id="org.eclipse.cdt.build.core.settings.holder.inType.549319812" languageId="org.eclipse.cdt.core.gcc" languageName="GNU C" sourceContentType="org.eclipse.cdt.core.cSource,org.eclipse.cdt.core.cHeader" superClass="org.eclipse.cdt.build.core.settings.holder.inType"/>
</tool>
</toolChain>
</folderInfo>
</configuration>
</storageModule>
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
</cconfiguration>
</storageModule>
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
<project id="arduino_pro5.null.189551033" name="arduino_pro5"/>
</storageModule>
<storageModule moduleId="scannerConfiguration">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
<scannerConfigBuildInfo instanceId="0.910961921">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
</scannerConfigBuildInfo>
</storageModule>
<storageModule moduleId="org.eclipse.cdt.core.LanguageSettingsProviders"/>
<storageModule moduleId="refreshScope" versionNumber="2">
<configuration configurationName="Default">
<resource resourceType="PROJECT" workspacePath="/arduino_pro5"/>
</configuration>
</storageModule>
</cproject>
27 changes: 27 additions & 0 deletions examples/ide-eclipse/arduino_pro5/.project
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>arduino_pro5</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.cdt.managedbuilder.core.genmakebuilder</name>
<triggers>clean,full,incremental,</triggers>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>org.eclipse.cdt.managedbuilder.core.ScannerConfigBuilder</name>
<triggers>full,incremental,</triggers>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.cdt.core.cnature</nature>
<nature>org.eclipse.cdt.core.ccnature</nature>
<nature>org.eclipse.cdt.managedbuilder.core.managedBuildNature</nature>
<nature>org.eclipse.cdt.managedbuilder.core.ScannerConfigNature</nature>
</natures>
</projectDescription>
5 changes: 5 additions & 0 deletions examples/ide-eclipse/arduino_pro5/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
all:
platformio run -t upload

clean:
platformio run -t clean
8 changes: 8 additions & 0 deletions examples/ide-eclipse/arduino_pro5/platformio.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Copyright (C) Ivan Kravets <[email protected]>
# See LICENSE for details.

[env:arduino_pro5v]
platform = atmelavr
framework = arduino
board = pro16MHzatmega168
upload_port = /dev/tty.SLAB_USBtoUART
20 changes: 20 additions & 0 deletions examples/ide-eclipse/arduino_pro5/src/main.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/**
* Copyright (C) Ivan Kravets <[email protected]>
* See LICENSE for details.
*/

#include "Arduino.h"
#define WLED 13 // Most Arduino boards already have an LED attached to pin 13 on the board itself

void setup()
{
pinMode(WLED, OUTPUT); // set pin as output
}

void loop()
{
digitalWrite(WLED, HIGH); // set the LED on
delay(1000); // wait for a second
digitalWrite(WLED, LOW); // set the LED off
delay(1000); // wait for a second
}
Loading

0 comments on commit 75dcb0b

Please sign in to comment.