Developing ESP32 with Eclipse on Linux
The following procedure shows how to build ESP32 microcontroller projects with the Eclipse Integrated Development Environment on Debian-based Linux distributions.
==========
1. INSTALLATION
1.1. Install Espressif's IoT Development Framework for ESP32 with the RTOS SDK.
1.2. Download and install the Eclipse IDE.
2. PREPARATION
2.1. On the Eclipse IDE, click on the following to install ESP-IDF plugins for Eclipse.
[ Help -> Install New Software -> Add... ]
Name: Espressif IDF Plugin for Eclipse
Click [ Add ].
Go to [ Espressif IDF dropdown ].
Check [ CMake Editor ].
Check [ Espressif IDF Plugins for Eclipse ].
Click [ Next -> Accept license terms -> Finish ].
Wait for plugins download and installation to complete.
Click [ Select All -> Trust ] if asked to trust some sources.
Restart Eclipse to show the [ Espressif ] menu item in the IDE.
2.2. Set the ESP-IDF directory and install the toolchain.
[ Espressif -> Download and Configure ESP-IDF ]
[ Choose existing ESP-IDF directory -> Browse... ]
Example: ~/esp/esp-idf
Click [ Finish ].
[ Espressif -> ESP-IDF Tools Manager -> Install Tools ]
Accept defaults and click [ Install Tools ].
Wait for tools download and installation to complete.
2.3. Reset the C/C++ perspective to default. This will show menu items in Eclipse for creating and importing ESP-IDF projects.
[ Window -> Perspective -> Reset Perspective... ]
Click [ Reset Perspective ].
2.4. On the Eclipse IDE, click on the following to open the target ESP32 project folder.
[ File -> Import... ]
[ Espressif -> Existing IDF Project -> Next ]
[ Existing Project Location -> Browse... ]
Example: ~/esp/esp-idf/examples/get-started/hello_world
Click [ Finish ].
2.5. Remove any incompatible settings inherited from other non-Eclipse builds.
[ Project Explorer tab -> Drop down project folder -> Right-click build folder -> Delete ]
[ Project Explorer tab -> Drop down project folder -> Right-click sdkconfig file -> Delete ]
3. UTILIZATION
3.1. Initially build the project, then configure its ESP-IDF SDK settings.
[ Project Explorer tab -> Right-click on project name -> Build Project ]
[ Project Explorer tab -> Drop down project folder -> Double-click sdkconfig file ]
Modify settings where needed in [ SDK Configuration tab ].
[ File -> Save ]
3.2. Remove old build files, if any.
[ Project Explorer tab -> Right-click on project name -> Clean Project ]
3.3. Build the ESP32 project binaries.
[ Project Explorer tab -> Right-click on project name -> Build Project ]
3.4. Flash the binaries to the ESP32 microcontroller.
[ Project Explorer tab -> Right-click on project name -> Run As -> Run Configurations... ]
Go to [ ESP-IDF Application -> Project name -> Run ].
If prompted for serial port, click [ OK -> ESP Target -> Serial Port -> /dev/ttyUSBx -> Finish ].
==========
REFERENCES
1. Espressif Systems. ESP-IDF Eclipse Plugin.
==========
Comments
Post a Comment