Skip to content

Manage Messages

Messages during compilation includes error messages , warning messages , and general messages like makefiles integrity, new release download, and project update.

Manage Error Messages

In case of a failed compilation, the Issue navigator display messages, either warning messages or error messages.

Error

LED was not declared in this scope.

An error message is highlighted in red and stops the compilation. It points at the line that originated the error.

Here, the board isn't connected and thus the serial port is not available.

The warning messages are explained in the next section.

Here, LED was not declared in this scope.

The Report navigator on the right side provides more details.

The Issue navigator provides a list of all the errors found during compilation.

To display the list of error messages and the corresponding lines of code,

  • Click on the icon of the middle to display the Issue navigator:

  • Click once on the message highlighted in red to display the line where the error is located.

The cursor points at LED line 89: the correct variable name is myLED. The error is just a misspelling. Note that the whole line is in black.

  • Change LED for myLED. The line is coloured back.

This feature doesn't work on the LaunchPad C2000 and on the BeagleBone.

Manage Warning Messages

A warning message is highlighted in yellow and doesn’t stop the compilation, but points at possible cause of errors.

Warning

unusedVariable is an unused variable.

To display the list of warning messages and the corresponding lines of code,

  • Select a target among All, Build, Make, Fast and click on Run.

  • Click on the icon of the middle to display the Issue navigator:

  • Click once on the message highlighted in yellow to display the line where the warning was generated.

Select Scope for Warning Messages

This section requires embedXcode+.

The variable WARNING_OPTIONS on the main Makefile selects the scope of the warning messages.

By default, the variable WARNING_OPTIONS is set to 0: no warning messages are reported.

# Warning options
#
WARNING_OPTIONS = 0

If WARNING_OPTIONS is left empty, all warnings are displayed.

# Warning options
#
WARNING_OPTIONS =

This is the same as WARNING_OPTIONS = all.

# Warning options
#
WARNING_OPTIONS = all

The all option usually generates a very long list of warning messages, making the analysis difficult if not impossible. Moreover, only the 200 first messages are displayed.

The solution consists on selecting a scope and targeting specific warnings.

Define the selected warnings by listing the options after the variable WARNING_OPTIONS.

Here are two example I use the most.

  • To check all the unused elements and save precious SRAM and Flash memory, define the following warning options.
# Warning options
#
WARNING_OPTIONS = unused-variable unused-function unused-label unused-value

The variable unusedVariable is defined but not used.

Defining but not using a variable is perfectly allowed, but uses SRAM memory.

  • To check all the use of NULL, define the following warning options.
# Warning options
#

WARNING_OPTIONS = conversion-null pointer-arith

The myLED variable corresponds to a pin number. Setting it to NULL is a correct operation but may rise an error somewhere else.

There are many other options for selecting warning messages. For more information,

Define Warning Statements

This section requires embedXcode+.

It is also possible to define a warning statement that will raise a warning message during compilation.

  • Type in the following line on the code with a #warning statement followed by the message to display.

To display the list of warning messages and the corresponding lines of code,

  • Select a target and click on Run.

  • Click on the icon of the middle to display the Issue navigator.



Click once on the message highlighted in yellow to display the line where the warning is located.

Manage General Messages

Check Makefiles Integrity

The integrity of the makefiles is also checked.

If a makefile has been modified or corrupted, a warning message is displayed. This is a non-blocking warning message.

In the example below, About.mk differs from the distributed version.

The names of the modified makefiles are listed on the Report Navigator.

==== Check project embed1 ==== 
WARNING non-valid makefile: About.mk 
==== Project embed1 checked ====
  • Reinstall the template for greater security.

Check New Release

This feature is by default turned off, and implemented only if the user has opted-in explicitly.

During the first use of embedXcode, a dialogue box asks for an explict authorisation to check embedXcocde new releases.

  • Click on Enable to check the availability of new releases of embedXcode.

  • Click on Disable otherwise.

For more information, and on how to change this option anytime after,

Warning

Opting-out turns the automatic Check and Download New Release procedure off.

Download New Release

During the first compilation of the project, a dialogue box prompts if a new release of embedXcode is available.

Info

Due to a change of server, the update message no longer works for versions prior to 7.5.1.

The dialogue box closes automatically after 10 seconds.

  • Click on Go to Download to download the new release or Ignore to ignore it.

  • Proceed with the installation.

During the following compilations of the project, the dialogue box is replaced by a notification.

In all cases, a message is printed on the Report Navigator.

==== Check project embed1 ==== 
---- A new release 7.5.3 is available ---- 
04 Jul 2017 release 7.5.3 • Improved stability for compact main.cpp 
Template provides release 7.5.2 
==== Project embed1 checked ==== 

For embedXcode, the new release of the template only applies for new projects. Existing projects are not updated with the new template.

With embedXcode+ release 7.0 and later, all the projects use the latest release of the installed template. There is no need to update the projects themselves.

Project created with embedXcode+ prior to release 7.0 need to be updated.

Select the Project Update Procedure

Depending on the initial project and the edition, different procedures are available.

To update a project with embedXcode standard edition,

To update a project created with embedXcode standard edition to embedXcode+ edition,