Problems while compiling the project Hello_World

ESP_Sprite
Posts: 9772
Joined: Thu Nov 26, 2015 4:08 am

Re: Problems while compiling the project Hello_World

Postby ESP_Sprite » Mon Feb 27, 2023 12:13 am

The errors you mention all sound like IDE issues. Have you actually tried compiling the project? For the first run, CMake resolves a bunch of dependencies etc, without that IDEs are generally incapable of finding everything.

User avatar
mbratch
Posts: 303
Joined: Fri Jun 11, 2021 1:51 pm

Re: Problems while compiling the project Hello_World

Postby mbratch » Mon Feb 27, 2023 3:21 am

ThomasESP32 wrote:
Mon Jan 16, 2023 9:35 am
Using ESP-IDF, I created a new project based on the Hello_World example project.
I gave it a name different from "Hello_World".
I copied the hello_world program from the ESP-IDF v5.0 examples folder as-is without modifying it. It includers the esp_chip_info.h header and it built fine, from scratch. So there's something about your modification of the project that is leading to the error for some reason.

yaconsult
Posts: 5
Joined: Tue Feb 21, 2023 2:06 am

Re: Problems while compiling the project Hello_World

Postby yaconsult » Tue Feb 28, 2023 5:26 am

As I said above, the example code DOES build and run properly - both from the command line and in the IDE. The issue is that the Espressif-IDE can not resolve the CHIP_FEATURE macros in the IDE. They are there and properly defined but the IDE underlines them as errors and says that they are not defined.

The issue is with the IDE not knowing the CHIP_FEATURE_* definitions even though they are found by the build system. The include files that define them are right there in the source - how do we get the Espressif-IDE to find the definitions and realize that they are not undefined errors?

Is the IDE syntax checker not processing all of the include files?
Last edited by yaconsult on Thu Mar 02, 2023 9:03 pm, edited 1 time in total.

yaconsult
Posts: 5
Joined: Tue Feb 21, 2023 2:06 am

Re: Problems while compiling the project Hello_World

Postby yaconsult » Tue Feb 28, 2023 5:33 am

Here is a picture of what I mean showing the red underlines:
Image
Do you see them in Espressif-IDE when you load the program? If not, what's different about our configurations?

User avatar
mbratch
Posts: 303
Joined: Fri Jun 11, 2021 1:51 pm

Re: Problems while compiling the project Hello_World

Postby mbratch » Thu Mar 02, 2023 3:53 pm

The Eclipse plugin also sometimes has issues with the visual symbol reference checker (the so called "indexer"). You can double check that all of the Espressif component path settings are correct in the setup. Also, performing a reindex will sometimes resolve it. It can be difficult to resolve in some cases, but if you can build fine, then it's only a visual issue. This problem comes and goes on my Eclipse plugin setup.
Last edited by mbratch on Fri Mar 03, 2023 12:47 pm, edited 1 time in total.

RalphD
Posts: 103
Joined: Thu Nov 25, 2021 9:02 pm

Re: Problems while compiling the project Hello_World

Postby RalphD » Thu Mar 02, 2023 5:32 pm

I experienced as well that after rebuilding the index an eclipse restart solves the issue in my case.

yaconsult
Posts: 5
Joined: Tue Feb 21, 2023 2:06 am

Re: Problems while compiling the project Hello_World

Postby yaconsult » Sat Mar 04, 2023 8:24 pm

I have reindexed and it had no effect for me. I'm still playing with this and tried creating a parser log and here are the parts at the end detailing the errors. The fact that it says esp_chip_info.h is not indexed would seem to be the problem, but WHY is it not indexed??? I checked the permissions and ownership of the file and they are fine. The file is intact and correct - otherwise, I wouldn't be able to successfully build with idf.py and Espressif-IDE.

Code: Select all

Unresolved includes (from headers in index):
   file:/home/me/esp/esp-idf-v5.0.1/components/newlib/platform_include/sys/reent.h is not indexed
   file:/home/me/esp/esp-idf-v5.0.1/components/newlib/platform_include/sys/reent.h is not indexed
   file:/home/me/esp/esp-idf-v5.0.1/components/esp_hw_support/include/esp_chip_info.h is not indexed
   file:/home/me/esp/esp-idf-v5.0.1/components/spi_flash/include/esp_flash.h is not indexed

Unresolved names:
   Attempt to use symbol failed: CHIP_FEATURE_BT in file /home/me/esp-idf-workspace/hello_world/main/hello_world_main.c:27
   Attempt to use symbol failed: CHIP_FEATURE_BLE in file /home/me/esp-idf-workspace/hello_world/main/hello_world_main.c:28
   Attempt to use symbol failed: CHIP_FEATURE_EMB_FLASH in file /home/me/esp-idf-workspace/hello_world/main/hello_world_main.c:39

snikul
Posts: 7
Joined: Mon Oct 08, 2018 5:57 pm

Re: Problems while compiling the project Hello_World

Postby snikul » Fri Mar 17, 2023 11:45 am

I have exactly the same problem with the same 3 semantic errors.

Waiting for explanation how to fix it.

Regards

martins
Posts: 52
Joined: Tue Aug 24, 2021 8:58 am

Re: Problems while compiling the project Hello_World

Postby martins » Wed Mar 22, 2023 10:58 am

+1, different project, same problem.

leo_liang
Posts: 1
Joined: Fri Apr 23, 2021 3:27 pm

Re: Problems while compiling the project Hello_World

Postby leo_liang » Sat Apr 01, 2023 6:24 pm

+1, I have the same problem also. Have tried the indexer rebuild. Same!

Who is online

Users browsing this forum: No registered users and 89 guests