Difference between revisions of "NESCDT"

From TinyOS Wiki
Jump to: navigation, search
(Using the ''nescdt'' plugin for Eclipse)
Line 1: Line 1:
 
==Using the ''nescdt'' plugin for Eclipse==
 
==Using the ''nescdt'' plugin for Eclipse==
 
A basic plugin for Eclipse with [http://nescc.sourceforge.net/papers/nesc-ref.pdf '''nesC'''] syntax highlighting and '''.nc''' file content detection for the follow types:
 
A basic plugin for Eclipse with [http://nescc.sourceforge.net/papers/nesc-ref.pdf '''nesC'''] syntax highlighting and '''.nc''' file content detection for the follow types:
* interface [[Image:Inter.gif]],
+
* ''interface'' [[Image:Inter.gif]],
* module [[Image:Mod.gif]],
+
* ''module'' [[Image:Mod.gif]],
* generic module [[Image:Genmod.gif]],
+
* ''generic module'' [[Image:Genmod.gif]],
* configuration [[Image:Conf.gif]],
+
* ''configuration'' [[Image:Conf.gif]],
* and generic configuration [[Image:Genconf.gif]].  
+
* and ''generic configuration'' [[Image:Genconf.gif]].  
 
The same symbols are used as in [[Getting_Started_with_TinyOS#Visualizing_a_Component_Graph| nesdoc]]. The source is included in the jar file, and it is possible to refine it. To install the plugin:
 
The same symbols are used as in [[Getting_Started_with_TinyOS#Visualizing_a_Component_Graph| nesdoc]]. The source is included in the jar file, and it is possible to refine it. To install the plugin:
 
* Download the '''nescdt_0.0.6.jar''' file [[http://nxtmote.sf.net/nescdt_0.0.6.jar here]]
 
* Download the '''nescdt_0.0.6.jar''' file [[http://nxtmote.sf.net/nescdt_0.0.6.jar here]]

Revision as of 02:36, 18 April 2008

Using the nescdt plugin for Eclipse

A basic plugin for Eclipse with nesC syntax highlighting and .nc file content detection for the follow types:

  • interface Inter.gif,
  • module Mod.gif,
  • generic module Genmod.gif,
  • configuration Conf.gif,
  • and generic configuration Genconf.gif.

The same symbols are used as in nesdoc. The source is included in the jar file, and it is possible to refine it. To install the plugin:

  • Download the nescdt_0.0.6.jar file [here]
  • Save it in the root of Eclipse plugin directory (where the other (jar) plugins also reside)
  • Restart Eclipse (perhaps verify for yourself that it is installed: Help->About Eclipse SDK->Plug-in Details)
  • Associate the *.nc files with this editor: Windows->Preferences->General->Editors->File Associations

Nxtmote-fileassosi.png

  • Create a new empty project Nxtmote-newproject.jpg and name it what you want to (for example nescsampleproject)
  • Create a new folder in the project (right-click on the project) and name it what you want (recommended to name it similar to the folder name that we will link to in the next step)
  • Import and link to the part of the TinyOS tree or your own code(right-click and press import)

Nxtmote-folderlink.jpg

  • Choose the Link to folder in the file system option and proceed (this will not change your TinyOS code at all and it will not copy any files on your computer)
  • When you are done the Eclipse IDE could look something like (note that the content of the files have been analyzed and that the icon reveals that we have some modules, generic modules, configurations and interface files in the timer folder):

Nxtmote-editor.jpg Nxtmote-editorsyntax.png

  • Side notes
    • The nescdt plugin is < 50 KB
    • If the CVS decorators annoys you, then turn it off from Window->Preferences...->General->Appearance->Label Decorations.
    • Another side note: You can also download the CDT plugin for editing the header files and c files in Eclipse. Enter the http://download.eclipse.org/tools/cdt/releases/europa as a new Remote site in the Eclipse update manager and choose the CDT main plugin:

Nxtmote-cdtdownload.png