/
CC-Link IE Field Basic Feature

CC-Link IE Field Basic Feature

This chapter explains the usage of the CC-Link IE Field Basic specific features of the Communication Creator.

 

Introduction

To start using port CC-Link IE Field Basic stack with own application one has to:

  • Define Software Model;

  • Create Application Code;

  • Create Device Description (CSPP file);

To assist its customers with getting started quickly, port provides Communication Creator utility application. Industrial Communication Creator for CC-Link IE Field Basic comes with easy to use forms and wizards, which make it easier to configure CC-Link IE Field Basic stack to user needs.

Functionality provided by the tool include

  • Generation of stack configuration files;

  • Generation of software model definition file;

  • Generation of device description CSPP file;

  • Generation of various documentations

  • User assistance for each configuration setting;

  • Detection of common configuration errors;

  • Step by step configuration guide in form of task list.

CC-Link IE Field Basic Projects

port CC-Link IE Field Basic stack configuration, together with software model, is defined as a single Communication Creator project. Using this project, the tool can generate appropriate code files. Working with CC-Link IE Field Basic projects is analogous to working with other Industrial Communication Creator projects. If some aspects are not clear, please check help pages for common functionality: Industrial Communication Creator User Guide.

Project Type

User will be able to create and edit CC-Link IE Field Basic projects if he has support for this protocol installed into Industrial Communication Creator application. One can check if that is the case, by opening About Dialog from Help main menu and checking if section Supported project types contains line " CC-Link IE Field Basic (full version)".

In Package Explorer View, CC-Link IE Field Basic projects are shown with blue CC icon ( ). Project node contains up to three project contents, as shown on Figure 254. Meaning of these sub-nodes will be explained in Code Generation chapter.

 

Figure 254: Example CC-Link IE Field Basic project entry in Package Explorer view

Creating New CC-Link IE Field Basic project

The creation of new CC-Link IE Field Basic project is straightforward. From File main menu, select New option. In case the Communication Creator product supports more project types, the user will be asked to choose what kind of project to create. Select entry CC-Link IE Field Basic Project () - see Figure 255 and click OK.

 

Figure 255: Contents of Select Wizard dialog with CC-Link IE Field Basic entry

Specify project file location and version

On the first page of wizard, user is asked to specify location of project file and the version of the project. Wizard window looks similar to that presented on Figure 256. To proceed, click Browse button to display your OS-specific select-file dialog. Project file name has extension .iccproj.

Tip: You can organize project files on disk however you want, but consider creating a new folder for each new project. This way it will be easier to know which code file belongs to which project.

 

 

Figure 256: First page of New Project wizard

It is possible to select already existing project file. User must be careful though, as it will result in losing all information saved to this file and replacing it with clean new project. This will happen as soon as Wizard finishes. Wizard warns about overwriting existing files with message shown on Figure 257.

 

Figure 257: Warning that specified file already exists

After location of project file is specified, proceed to next page by clicking Next button.

Specify location for generated code

Second wizard page asks user to specify location of seven files that will be generated based on project configuration.

  • Stack configuration file goal_appl.c, goal_config.h;

  • Device description file CSPP.cspp;

The page is presented on Figure 258.

 

Figure 258: Second page of New Project wizard

You may change location where each of these files is to be saved by using Browse button. Be careful to not overwrite some previously created files. Wizard will warn user if one or more files already exist in location specified – see Figure 259.

 

Figure 259: Warning that a target file already exists

Finish project creation

After all locations are set, click Finish button to create the project. If you do not want to continue with new project creation, click Cancel.

It may be possible that one of selected locations will be inaccessible for the tool. For example, user running application may not have write rights to selected directory. In this case wizard will not finish, but display error message - Figure 260. In this case user has to change specified path and try again.

 

Figure 260: Error message when projects files can not be created

During wizard finish, user will be once again warned about every overwrite risk that was detected and asked for confirmation - Figure 261. In case of any doubts, click Cancel to postpone project creation. Otherwise, click OK to continue.

 

Figure 261: The user has to confirm file overwrite

After project creation wizard finishes successfully, project file will be created and filled with empty project configuration. Other files (goal_appl.c, goal_config.h, CSPP.cspp) will be created later. The new project will be opened in new editor tab that appears on top of application window.

Validation

CC-Link IE Field Basic projects are subject to correctness checks as every other Industrial Communication Creator project:

  • After project is opened;

  • Before project is saved;

  • At user request.

You can request project validation using Package Explorer. Right click on project entry in Package Explorer View and select Validate menu option. Validation may take a few seconds. After it finishes, dialog with results appears. If no problems are found, the message will simply say "OK". Otherwise, quick overview of detected problems will be displayed in dialog similar to presented on Figure 262.

 

Figure 262: Dialog with results of explicitly request project validation

See Common Problems chapter for list of common issues that may be reported during validation, and how they may be resolved.

CC-Link IE Field Basic projects share editing tools with other Industrial Communication Creator project types. To learn about basic editor elements such as toolbar or input forms, see help pages for common functionality: Industrial Communication Creator User Guide.

Editor Extensions

Top Page

After project is loaded, editor will display graphical top page for it. User can always return to this editor page by using Go Home tool ( ). Sonderzeichen fehlt

Top page for CC-Link IE Field Basic project is presented on Figure 263. Each burgundy-red block is a click-able link to editor page with configuration elements. You can also hover mouse cursor over the figure to display longer description of block contents as tool-tip.

Blocks are organized into three groups:

Project Settings

General Settings of CC-Link IE Field Basic stack configuration.

Project Preferences

Settings for C Code generation and extended interface settings.

Device Description

Settings related to creation of CSP+ file.

CSP+ File description

Settings related to creation of CSP+ file structure.

Editor Extensions

Top Page

After project is loaded, editor will display graphical top page for it. User can always return to this editor page by using Go Home tool ( ).

Top page for CC-Link IE Field Basic project is presented on Figure 263. Each burgundy-red block is a click-able link to editor page with configuration elements. You can also hover mouse cursor over the figure to display longer description of block contents as tool-tip.

Blocks are organized into three groups:

Project Settings

General Settings of CC-Link IE Field Basic stack configuration.

Project Preferences

Settings for C Code generation and extended interface settings.

Device Description

Settings related to creation of CSP+ file.

CSP+ File description

Settings related to creation of CSP+ file structure.

 

 

Figure 263: Top Page for CC-Link IE Field Basic project

Code Preview

Editor for CC-Link IE Field Basic projects has three additional tabs beside main Design Tab. All of these are used for preview of generated code.

 

Figure 264: Tabs for CC-Link IE Field Basic editor

  goal_config.h

Preview of C header file for CC-Link IE Field Basic stack configuration.

  goal_appl.c

Preview of C code file where software model is defined for use in CC-Link IE Field Basic stack.

  CSPP.cspp

Preview of CSP+ file displayed using HTML style.

 

Each time code preview tab is opened, its contents are refreshed to match current project configuration. If project contains errors or inaccuracies previewed code may be incorrect or code will fail to generate altogether. In any case, project validation provides clues about nature of the problem.

Code Generation

 

The CC-Link IE Field Basic Communication Creator generates several files to be used within the port CC-Link IE Field Basic Stack. This chapter shows how to generate the files via the command line, gives a short overview over the meaning of the different generated files and how to view them.

 

CMD generation

 

It is possible to generate files through CMD commands. The CMD Communication Creator is started via commands with following structure:

 

 

a) iccCmd <singleOption>

 

b)  iccCmd <option 0> ... <option n> <iccProjectFile>

 

 

Case a) can only have one option (see Table 38).

 

Case b) can consist of multiple options (see Table 38) but the end of the command has to be always the full path of the project file. Options are separated by whitespaces and start with a double minus (--). The steps done by the commands are documented in the errorProtocol.txt file and after every command the project file will be saved. See chapter 25 for usage of options in commands.

 

Pre-/Post-Generation

 

It is possible to execute application-specific programs before and after generation. The commands can be entered about the Generation-block in the editor view > Pre-/Post-Generation Commands. The commands can be a shell-script or a batch file, or you can call an executable file. The output of the command is written into the information file "errorProtocol.txt".

 

Generated files

 

goal_appl.c

goal_appl.c file is a C code file which contains structure definitions of application software model.

Code can be displayed for inspection using appropriate editor tab. Location where goal_appl.c file is saved is specified when project is created. The path can be seen on top of code-preview tab. User can change this location using Browse button ( ) in code-preview tab toolbar.

If auto-save check box is selected, the code file will be rewritten, each time project changes are saved to disk. User can also save file manually using Save toolbar button.

goal_config.h

goal_config.h file is a C header file which contains defines needed for GOAL stack configuration.

Code can be displayed for inspection using appropriate editor tab. Location where goal_config.h file is saved is specified when project is created. The path can be seen on top of code-preview tab. User can change this location using Browse button ( ) in code-preview tab toolbar.

If auto-save check box is selected, the code file will be rewritten, each time project changes are saved to disk. User can also save file manually using Save toolbar button.

 

CSPP.cspp

A CSP+ file is a .xml file which contains descriptive and communication information of the hardware device.

Code can be displayed for inspection using appropriate editor tab. Location where CSPP file is saved is specified when project is created. The path can be seen on top of code-preview tab. User can change this location using Browse button ( ) in code-preview tab toolbar.

If auto-save check box is selected, the code file will be rewritten, each time project changes are saved to disk. User can also save file manually using Save toolbar button.

Common CC-Link IE Field Basic problems

During Project Validation problems can be detected in user project. These are collected by Problems View application part, for the user to browse.

In chapter 24 the list of common problem reports concerning CC-Link IE Field Basic projects, their meanings and solutions can be found.

Settings reference

A detailed reference of all available settings for port CC-Link IE Field Basic stack can be found in the online help of the Communication Creator. Please open the help system via menu “Help” à “Help contents”. Then select “port CC-Link IE Field Basic Tool User Guide” à “Settings Reference”.

Project editing

This chapter describes the working flow for creating and editing projects. The order of the flow is not mandatory, but very useful. Basic parameter like the number of CC-Link IE Field Basic lines and the kind of the device (Slave or Master) shall be clear at the beginning of the development. The necessary steps are the following:

  • configuration of global parameter

  • configuration of Device Identity settings (Device-Section of CSPP parameter)

  • configuration of occupied Station Sections (CommIf-Section of CSPP parameter)

  • generation of outputs

Beginning a project

A project is created by the menu File > New.

Existing projects are opened by the menu File > Open… .

Occupied Station Sections and CSP+ file

Next to mandatory and optional device identity settings Occupied Station Sections can be configured at the “Device Description” section of the editor’s top page.

They can be created using the “Add new Occupied Station Section”-button or deleted via the “remove”-button (see Figure 265). Via the “details”-button more settings of the Occupied Station Section can be specified.

 

Figure 265: Overview of all Occupied Station Sections

 

For every created Occupied Station Section one COMM_IF section will be created in the CSP+ file structure. Every COMM_IF section has one COMM_IF_INFO part which contains all necessary elements of the device identity and Occupied Station Section settings.

 

 

 

Figure 266: CSP+ file structure

 

User can add more COMM_IF parts if needed. They can be added/removed at the Sections-view by clicking on a COMM_IF section. The part type and the position can be selected via combo-box and spinner before adding the part with the “Add Part of type”-button.

 

 

 

Figure 267: Add/remove COMM_IF parts

 

Generation of source code

About the “save”-button next to saving the project file all files listed in chapter 14.4.3 are generated if no validation errors occur.

This method guarantees that all C code and documentation files are consistent to each other.

The Problems-view contains warnings and errors which are generated into the errorProtocol.txt file, too. It is recommended to check the Problems-view or this file after each generation.