Skip to content
Eric Berryman edited this page Jun 20, 2013 · 11 revisions

SNL Editor

Purpose: Editor for the State Notation Language (SNL)

The State Notation Language is a superset of the C language, used for programming EPICS-based IOCs. The SNL perspective aids in editing through syntax highlighting, display of problems, code completion and outline-based navigation in the source code.

A brief introduction for using the SNL Development perspective follows

SNL Development Perspective

Open the SNL Development perspective. Press the button in the toolbar for selecting perspectives

click Other ... and chose the SNL perspective

If you already have worked with it, it may have a different layout. Reset it then, so your display has a layout similar to this one:

Install Samples

Install the samples via CSS menu:

Then you will find the SNL Demo Project in the Navigator View.

Import existing source files

You may as well import your own source files. If you want to do so, first create an SNL Project with the help of its wizard

and import your files using the Import menu of the navigator

followed by the selection of the Import Wizard

and eventually chosing your files and the newly created project as the destination.

Editing

Now double click a file containing source code from the navigator. The editor will open. Positoning of the cursor is now reflected in the outline. You may navigate using the outline as well.

Code Completion (triggered by Ctrl-Space as usual) helps in editing:

Problem View

Now let us have a look at the problem view. You may want to filter its output to stay focused:

The problem view shows warnings or errors which can be determined through syntactical analysis. Update occurs after saving the source file. Double-clicking an entry in the problem view navigates to the location in the source file.

Editing history

Even though you are not connected to a source code repository, a limited amount of version management is available. Each time you save a file it is stored in the local history maintained by CSS. This is by no means a replacement for backup nor for a repository, just a hint for working in CSS.

The History View will open, giving you access to previous versions. For example, select the versions you want to compare and start a comparison:

Now you can review your changes:

The actual amount of source code which is stored in the local history is a matter of preferences.

Compilation (not yet available)

Finally your source code will be ready to be compiled. However, this is currently not supported (for non-DESY versions).

Documentation

Documentation for the State Notation Language is available from the Argonne National Laboratory at the EPICS Home http://www.aps.anl.gov/epics/

Clone this wiki locally