Difference between revisions of "Setting up Eclipse for ESP-IDF"
Line 29: | Line 29: | ||
=Setup Environment Variables= | =Setup Environment Variables= | ||
+ | These variables are setup to tell eclipse where the tool-chain and the ESP-IDF core is located. | ||
+ | # Right Click on the Project Name. | ||
+ | # Select Properties. | ||
+ | <br /> | ||
+ | |||
[[File:3_proj_properties.jpg]] | [[File:3_proj_properties.jpg]] | ||
+ | <br/> | ||
+ | |||
+ | To add the environment variables: | ||
+ | # Expand ''C/C++ Build'' and click on ''Environment'' | ||
+ | # Click on the Add Button as shown below. Also notice that the IDE picks up some variable from the make file | ||
+ | <br/> | ||
[[File:4_env_variables.JPG]] | [[File:4_env_variables.JPG]] | ||
+ | |||
+ | # Click on the “Environment” properties page under “C/C++ Build”. Click “Add...” and enter name V and value 1. | ||
+ | # Click “Add...” again, and enter name IDF_PATH. The value should be the full path where ESP-IDF is installed. Windows users: Use forward-slashes not backslashes for this path, ie C:/Users/MyUser/Development/esp-idf. | ||
+ | |||
[[File:5_update_env_variables.JPG]] | [[File:5_update_env_variables.JPG]] | ||
[[File:6_path_variables.JPG]] | [[File:6_path_variables.JPG]] |
Revision as of 15:30, 23 December 2016
(Tutorial in the making...)
Eclipse offers a very good development environment with numerous features, however setting it correctly is sometimes frustrating. Once it is done, it make the workflow quite simple. So let's set it up and see how it goes!
The first thing that needs to be done is to set-up ESP-IDF and ensure that all the dependencies are taken care of. Check the detailed tutorial on setting up ESP-IDF to get that done.
The ESP-IDF is setup in such a way that you can develop your application without modifying the ESP-IDF files. The application can reside in a completely separate directory from the ESP-IDF files. This allows the ESP-IDF core files to be updated independently of the application. We will be configuring the same 01_hello_world example from the above tutorial.
Ensure that the tool-chain works from command line, before proceeding with this tutorial. In fact this tutorial uses the makefile setup from the previous tutorial to configure the tool-chain.
Contents
Download and Install Eclipse C/C++ IDE
To get started download the latest eclipse IDE for C/C++
http://www.eclipse.org/downloads/packages/eclipse-ide-cc-developers-includes-incubating-components/indigosr2
Create a New Project
All the images below have steps marked with numbers, please perform them in a series. To start with
- Select the project type as Empty Project
- Toolchains as Cross GCC
- Uncheck Use Default Location
- Enter the project Name as 01_hello_world
Setup Environment Variables
These variables are setup to tell eclipse where the tool-chain and the ESP-IDF core is located.
- Right Click on the Project Name.
- Select Properties.
To add the environment variables:
- Expand C/C++ Build and click on Environment
- Click on the Add Button as shown below. Also notice that the IDE picks up some variable from the make file
- Click on the “Environment” properties page under “C/C++ Build”. Click “Add...” and enter name V and value 1.
- Click “Add...” again, and enter name IDF_PATH. The value should be the full path where ESP-IDF is installed. Windows users: Use forward-slashes not backslashes for this path, ie C:/Users/MyUser/Development/esp-idf.