Convert arduino project into Platform IO project. I've had enough of the default IDE!

This commit is contained in:
Starbeamrainbowlabs 2017-03-02 18:38:18 +00:00
parent deee56ea9e
commit 4bf1548aad
4 changed files with 65 additions and 0 deletions

8
.gitignore vendored
View file

@ -5,6 +5,14 @@
# Created by https://www.gitignore.io/api/visualstudio
## Platform IDE
.pioenvs
.piolibdeps
.clang_complete
.gcc-flags.json
### VisualStudio ###
## Ignore Visual Studio temporary files, build results, and
## files generated by popular Visual Studio add-ons.

View file

@ -1,3 +1,5 @@
#include <Arduino.h>
/*
* Connecting to a WiFi network with WPA
************************************************

View file

@ -0,0 +1,36 @@
This directory is intended for the project specific (private) libraries.
PlatformIO will compile them to static libraries and link to executable file.
The source code of each library should be placed in separate directory, like
"lib/private_lib/[here are source files]".
For example, see how can be organized `Foo` and `Bar` libraries:
|--lib
| |--Bar
| | |--docs
| | |--examples
| | |--src
| | |- Bar.c
| | |- Bar.h
| |--Foo
| | |- Foo.c
| | |- Foo.h
| |- readme.txt --> THIS FILE
|- platformio.ini
|--src
|- main.c
Then in `src/main.c` you should use:
#include <Foo.h>
#include <Bar.h>
// rest H/C/CPP code
PlatformIO will find your libraries automatically, configure preprocessor's
include paths and build them.
More information about PlatformIO Library Dependency Finder
- http://docs.platformio.org/page/librarymanager/ldf.html

View file

@ -0,0 +1,19 @@
; PlatformIO Project Configuration File
;
; Build options: build flags, source filter
; Upload options: custom upload port, speed and extra flags
; Library options: dependencies, extra library storages
; Advanced options: extra scripting
;
; Please visit documentation for the other options and examples
; http://docs.platformio.org/page/projectconf.html
[env:d1]
platform = espressif8266
board = d1
framework = arduino
[env:d1_mini]
platform = espressif8266
board = d1_mini
framework = arduino