Compiling with PlatformIO (on Mac...)

Moderators: grovkillen, Stuntteam, TD-er

Post Reply
Message
Author
JR01
Normal user
Posts: 229
Joined: 14 Feb 2016, 21:04
Location: South Africa
Contact:

Compiling with PlatformIO (on Mac...)

#1 Post by JR01 » 17 May 2017, 22:01

Hi all, it is clear PlatformIO is pretty important going forward.

I tried to read all the PlatformIO articles, and the wiki pages. They are not in one place, which makes it more difficult. I am on a Mac, have gone through all the Mac related install topics of the wiki, for instance on:

https://www.letscontrolit.com/wiki/inde ... Platformio
Disable Linter / Install Atom / Started Atom / Installed the PlatformIDE (IDE 2.0.0-beta.3 and Core 3.4.0b2) / Python 2.7

Then, at the bottom of the wiki you say: "If atom is slughish, hanging and giving errors, then there is probably something wrong with the gcc-linter. I had to remove platformio-* and linter-gcc and reinstall platformio-ide to fix it."

QUESTION 1 -- How does one do removal of above? Do I go find this on the OS level, and delete it? As I do have a problem, as follows:

After downoading the source for ESPEasy_v2.0.0-dev8, I open the file ESPEasy.ino, hit F7, and then do not get any response, and then after some time, the following screen pops up:

Image

What are the steps to solve this please? I would like to get PlatformIO working, it seams the investment in time will be worth it going forward.

Ohh, I did not log into PLatformIO when atom starts up, is this required?
Attachments
Screen Shot 2017-05-17 at 9.07.18 PM.png
Screen Shot 2017-05-17 at 9.07.18 PM.png (35.23 KiB) Viewed 3735 times
-----------
IOTPLAY. Tinkerer, my projects are @ http://GitHub.com/IoTPlay . Using RPi, Node-Red, ESP8266 to prove Industry 4.0 concepts.

Domosapiens
Normal user
Posts: 283
Joined: 06 Nov 2016, 13:45

Re: Compiling with PlatformIO (on Mac...)

#2 Post by Domosapiens » 17 May 2017, 23:23

I open the file ESPEasy.ino
That's not the way in Atom.
Use File> Add Project Folder, then select the directory Source (containing .pioenvs, lib and src)
gcc-linter
can be found under Packages (I think I removed it there)
30+ ESP units for production and test. Ranging from control of heating equipment, flow sensing, floor temp sensing, energy calculation, floor thermostat, water usage, to an interactive "fun box" for my grandson. Mainly Wemos D1.

JR01
Normal user
Posts: 229
Joined: 14 Feb 2016, 21:04
Location: South Africa
Contact:

Re: Compiling with PlatformIO (on Mac...)

#3 Post by JR01 » 17 May 2017, 23:37

That's not the way in Atom.
Use File> Add Project Folder, then select the directory Source (containing .pioenvs, lib and src)
Thank you, that worked. Now busy compiling, want to see if I can get a .bin file to upload via the ESP OTA web interface.
-----------
IOTPLAY. Tinkerer, my projects are @ http://GitHub.com/IoTPlay . Using RPi, Node-Red, ESP8266 to prove Industry 4.0 concepts.

JR01
Normal user
Posts: 229
Joined: 14 Feb 2016, 21:04
Location: South Africa
Contact:

Re: Compiling with PlatformIO (on Mac...)

#4 Post by JR01 » 17 May 2017, 23:44

Okay, I think I compiled it. I chose PIO clean (normal_1024) options, see below, it runs some scripts at the bottom, but do not find a compiled .bin file after that, does it build a .bin file? Where do search for it?

Image
Attachments
Screen Shot 2017-05-17 at 11.41.50 PM.png
Screen Shot 2017-05-17 at 11.41.50 PM.png (27.09 KiB) Viewed 3722 times
-----------
IOTPLAY. Tinkerer, my projects are @ http://GitHub.com/IoTPlay . Using RPi, Node-Red, ESP8266 to prove Industry 4.0 concepts.

JR01
Normal user
Posts: 229
Joined: 14 Feb 2016, 21:04
Location: South Africa
Contact:

Re: Compiling with PlatformIO (on Mac...)

#5 Post by JR01 » 17 May 2017, 23:55

<Toggle Build Panel> option, then get below, looks like successful build, but where does it put the file?

[Wed May 17 23:53:13 2017] Processing normal_1024 (platform: espressif8266; upload_speed: 460800; build_flags
: -Wl,-Tesp8266.flash.1m128.ld -D PLUGIN_BUILD_NORMAL -D BUILD_GIT='""'; board: esp12e; framework: arduino)
--------------------------------------------------------------------------------
Build environment is clean
========================= [SUCCESS] Took 0.50 seconds =========================

================================== [SUMMARY] ==================================

Environment normal_1024 [SUCCESS]
Environment normal_4096 [SKIP]
Environment normal_8285 [SKIP]
Environment test_1024 [SKIP]
Environment test_4096 [SKIP]
Environment test_8285 [SKIP]
Environment dev_1024 [SKIP]
Environment dev_4096 [SKIP]
Environment dev_8285 [SKIP]
========================= [SUCCESS] Took 0.50 seconds =========================
-----------
IOTPLAY. Tinkerer, my projects are @ http://GitHub.com/IoTPlay . Using RPi, Node-Red, ESP8266 to prove Industry 4.0 concepts.

costo
Normal user
Posts: 490
Joined: 21 Nov 2015, 15:03

Re: Compiling with PlatformIO (on Mac...)

#6 Post by costo » 18 May 2017, 03:58

JR01 wrote:
17 May 2017, 23:55
<Toggle Build Panel> option, then get below, looks like successful build, but where does it put the file?
In my Linux machine PlatformIO puts the binaries in a hidden folder called ¨ .pioenvs ¨ ( note the dot in front of the name, meaning it is hidden). Every compile option creates itś own subfolder in .pioenvs and places the binfile as firmware.bin there.

JR01
Normal user
Posts: 229
Joined: 14 Feb 2016, 21:04
Location: South Africa
Contact:

Re: Compiling with PlatformIO (on Mac...)

#7 Post by JR01 » 18 May 2017, 09:24

Thank you Costo, I do see that hidden folder, but compiled image not there...

Image
Attachments
Screen Shot 2017-05-18 at 9.21.13 AM.png
Screen Shot 2017-05-18 at 9.21.13 AM.png (42.06 KiB) Viewed 3679 times
-----------
IOTPLAY. Tinkerer, my projects are @ http://GitHub.com/IoTPlay . Using RPi, Node-Red, ESP8266 to prove Industry 4.0 concepts.

costo
Normal user
Posts: 490
Joined: 21 Nov 2015, 15:03

Re: Compiling with PlatformIO (on Mac...)

#8 Post by costo » 18 May 2017, 14:59

My folder looks like this
platformIO.jpg
platformIO.jpg (28.03 KiB) Viewed 3672 times

To get these files in the .pioenvs folder I opened the ESPEasy2.8.ino file (renamed it myself) , then pressed F7 and choose PIO Build. Then PlatformIO was busy for a few minutes and was compiling all the different options and placed the output files in this .pioenvs folder.

As say´d my system is on Linux-OS , not MAC, so your files may be placed in another place ?

JR01
Normal user
Posts: 229
Joined: 14 Feb 2016, 21:04
Location: South Africa
Contact:

Re: Compiling with PlatformIO (on Mac...)

#9 Post by JR01 » 30 May 2017, 00:24

Thank you Costo. I now tried to get going with PlatformIO again. Updated atom, platformIO, etc, downloaded ESPEasy-2.0.0-dev10, went to the src file, and opened ESPEasy.ino.

Pressed F7 for the 'overview of the possible versions to build', but only get 'No target found'.

Does anybody know where the F7 instructions are controlled, and how I can move forward on using PlatoformIO on Mac?
-----------
IOTPLAY. Tinkerer, my projects are @ http://GitHub.com/IoTPlay . Using RPi, Node-Red, ESP8266 to prove Industry 4.0 concepts.

Shardan
Normal user
Posts: 1112
Joined: 03 Sep 2016, 23:27
Location: Bielefeld / Germany

Re: Compiling with PlatformIO (on Mac...)

#10 Post by Shardan » 30 May 2017, 14:10

Try this:

Do not simply open the ESPEasy.ino.
In Atom/Platformio use "Open Project"
and add the Folder above "src", "dist",".github" etc.
Then in the left pane go to ESPEasy.ino and open it, press F7 etc etc.

Regards
Shardan
Regards
Shardan

JR01
Normal user
Posts: 229
Joined: 14 Feb 2016, 21:04
Location: South Africa
Contact:

Re: Compiling with PlatformIO (on Mac...)

#11 Post by JR01 » 30 May 2017, 19:26

Thank you. Nope, still not working. Any other way to compile, or where are the def's carried that comes up under F7 ?
-----------
IOTPLAY. Tinkerer, my projects are @ http://GitHub.com/IoTPlay . Using RPi, Node-Red, ESP8266 to prove Industry 4.0 concepts.

Shardan
Normal user
Posts: 1112
Joined: 03 Sep 2016, 23:27
Location: Bielefeld / Germany

Re: Compiling with PlatformIO (on Mac...)

#12 Post by Shardan » 30 May 2017, 20:02

Something in your Platformio setup has gone wrong,.. i followed the Howto in the wiki and it works.

Anyways, you may use the arduino ide for compiling, a howto is in the wiki.
Just i've seen many people run into problems when using the arduino ide for flashing.
Choose "Export Binary File" and use the flash tool delivered with the ESPEasy 2.0.0 zip file.

Regards
Shardan
Regards
Shardan

JR01
Normal user
Posts: 229
Joined: 14 Feb 2016, 21:04
Location: South Africa
Contact:

Solved: Compiling with PlatformIO (on Mac...)

#13 Post by JR01 » 01 Jun 2017, 22:22

Thank you all, I got it working.

the instructions on wiki letscontrolit is not that clear.

Like contributor @Domosapiens earlier on this post stated, open the directory which contains:

Code: Select all

Use File> Add Project Folder, then select the directory Source (containing .pioenvs, lib and src)
-----------
IOTPLAY. Tinkerer, my projects are @ http://GitHub.com/IoTPlay . Using RPi, Node-Red, ESP8266 to prove Industry 4.0 concepts.

Post Reply

Who is online

Users browsing this forum: No registered users and 21 guests