User Tools

Site Tools


arduino:code_completion

This is an old revision of the document!


Arduino Code Completion Directories

The directories

Directories to include by default

The following is a list of known directories to add to your IDE for effective code completion using AVR-based Arduinos.

{path-to-arduino}/hardware/arduino/avr/cores/arduino/
{path-to-arduino}/hardware/arduino/avr/libraries/EEPROM/
{path-to-arduino}/hardware/arduino/avr/libraries/SPI/
{path-to-arduino}/hardware/arduino/avr/libraries/SoftwareSerial/
{path-to-arduino}/hardware/arduino/avr/libraries/Wire/
{path-to-arduino}/hardware/tools/avr/avr/include/
{path-to-arduino}/hardware/tools/avr/avr/include/avr/
{path-to-arduino}/hardware/tools/avr/avr/include/compat/
{path-to-arduino}/hardware/tools/avr/avr/include/util/
{path-to-arduino}/hardware/tools/avr/lib/gcc/avr/4.8.1/include/
{path-to-arduino}/hardware/tools/avr/lib/gcc/avr/4.8.1/include-fixed/

With this list, you'll want to do one of the following:

  • If your IDE lets you configure custom toolsets, add the directories to the toolset's list of directories checked for code completion if possible.1)
  • If your IDE is workspace based and you use separate workspaces for Arduino development, add these to the list of the workspace's additional directories to check for code completion.2)
  • Add the list to your IDE's global list of of additional directories for code completion—which means the directories will be parsed for every project, not just Arduino ones.
  • Add the list to the IDE project's list of additional directories for code completion. If you take this approach (or if it's your only option), then you'll have to repeat this for every Arduino project you start.

Including libraries

In addition to the above, you should add any libraries used by your project to the IDE project's list of additional directories for code completion. These will typically be of the form:

../libraries/{name-of-library}
1)
This is how I do it with NetBeans.
2)
This works well with CodeLite for me.
arduino/code_completion.1445777757.txt.gz · Last modified: 2015/10/25 12:55 by mithat

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki