Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » C / C++ IDE (CDT) » Wrongly marked as unresolved(in the Arduino CDT plugin)
Wrongly marked as unresolved [message #1755286] Thu, 02 March 2017 07:22 Go to next message
Francis Pantus is currently offline Francis PantusFriend
Messages: 3
Registered: February 2017
Junior Member
Dear Forum Members
Using a Mega 2560 board, calls to the 'extra' hardware serial ports (other than the standard) are consistently marked as 'could not be resolved' (red wiggly line). However, they build and run fine.
I've seen a similar post, but can't find it anymore. Its an annoyance more than a problem, just another item for the to-do list (sorry Dave).
Re: Wrongly marked as unresolved [message #1758504 is a reply to message #1755286] Wed, 29 March 2017 12:09 Go to previous messageGo to next message
Rainer H. is currently offline Rainer H.Friend
Messages: 21
Registered: July 2009
Junior Member
I had such a problem a while ago. At my project the problem was that the definition was conditional through a ifdef. The definition of the condition - in my case the existence of a def - was set in my own makefile. Compiling worked. But the indexer doesn't know the condition(flag).

Solution was to define the flag in "Project settings / C/C++ General / Path and Symbols", tab Symbols. Define the Symbol there according to your language.

Hope it helps.
Re: Wrongly marked as unresolved [message #1781406 is a reply to message #1755286] Tue, 06 February 2018 21:46 Go to previous message
Markus Göbel is currently offline Markus GöbelFriend
Messages: 1
Registered: February 2018
Junior Member
I did encounter the same issue. Though the solution was a bit different for me. Therefore documenting this here, in case somebody else is running into the same problem.

Setup:
- Eclipse Oxygen (4.7.2)
- OS: Linux Mint & Windows 10 (error is reproducible in both environments)
- Eclipse C++ IDE for Arduino 3.0
- Arduino AVR Boards 1.6.20

Issue:
No problem with the declaration of the ports A0 - A7. This was correctly resolved.
But the declaration for the addional ports A8 - A15 on my Mega 2560 board could not be resolved, resulting in error messages in the syntax check.

These ports are declared in pins_arduino.h which is board specific and which is included via Arduino.h.

Of course I had the connection and launch target correctly configured for the Mega 2560 board.
When navigating to pins_arduino.h via the outline view in Eclipse, the correct pins_arduino.h file was opened. The one for Mega 2560 with all ports A0 - A15 declared.

Though when navigating to the declaration of one of the ports A0 - A7 directly in the editor, the wrong pins_arduino.h file was opened. The one from Arduino Uni with just the ports A0 - A7.

Solution:
Preferences -> C/C++ -> Indexer
Temporarily activating "Index source and header files opened in editor" did solve the issue for me.

Seems like a bug in the indexer.



Previous Topic:undefined reference to - error build
Next Topic:C++ in Eclipse - From the beginning
Goto Forum:
  


Current Time: Fri Apr 26 01:33:58 GMT 2024

Powered by FUDForum. Page generated in 0.03144 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top