Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Table 1‑1: Directory structure of the Master SDK

Writing an Application for the Master SDK

Overview

 An application for the Master SDK is a GOAL application. It consists of three functions that are called by GOAL: appl_init, appl_setup, appl_loop.

...

Table 1‑2: Configuration Functions of the CC-Link IE TSN protocol stack

Creating a new instance of the CC-Link IE TSN protocol stack

 After the stack has been configured the function goal_cclIeTsnNew must be invoked to create a new instance of the protocol stack. It is also used to register a callback handler for processing events from the stack. The callback handler will be explained in detail in a later chapter.

...

The functions in this chapter influence the runtime behaviour of the CC-Link IE TSN Master Station. The functions must be called after goal_cclIeTsnNew returned successfully and before goal_cclIeTsnStart is called. These functions can be directly called within appl_setup or at a later point in time. These functions represent settings that usually come from an Engineering Tool. Therefore, the settings can be applied after receiving the current configuration from the tool.

Tabelle fehlt

Remote Station Configuration

 

For each Remote Station station in the network a Remote Station handle must be added. Each Remote Station is represented by an Id. The functions must be called after goal_cclIeTsnNew returned successfully and before goal_cclIeTsnStart is called. These functions can be directly called within appl_setup or at a later point in time, i.e. after the expected Remote Station configuration has been received from the Engineering Tool.

Tabelle fehlt

Starting the CC-Link IE TSN Master Stack

 

After finishing all settings of the runtime behavior and the expected Remote Station configuration the stack must be started by calling goal_cclIeTsnStart.

...

If this function succeeds the stack CC-Link IE TSN Master stack has been started and tries to detect all configured Remote Stations. All functions described in previous chapters cannot be used anymore.

Functions used during Run phase

 

After sucessfulling starting the stack. The application can use the following functions to access cyclic data and to influence the stack’s behaviour.

...

Table 1‑5: Functions used during Run phase

Application Callback

 

During initialization, the application can register a callback handler with the function goal_cclIeTsnNew.

...

Figure 1.3: Sample implementation of the application callback

Configuration of CANopen Remote Stations

 CANopen Remote Stations are configured with the same functions as Link Device Remote Stations. Additionally, there is the function goal_cclIeTsnSlaveCanOpenConfigSet to set CANopen specific properties of the Remote Station.

...

Table 1‑8: Members of callback data of CANopen data callback

1.1        Supported Platforms

 

Since the CC-Link IE TSN Protocol stack runs on GOAL, it can run on any platform supported by GOAL. However, to fullfill the requirements of a Class B device special hardware support is needed.

...

Table 1‑9: Confirmed Supported Hardware for the Master SDK

NXP LS1028A

 The NXP LS1028A is a SoC that fullfills the hardware requirements for a Class B device.

There is an evaluation board called LS1028ARDB.

Building the firmware

The LS1028ARDB uses OpenIL, a Linux distribution for industrial automation with Realtime support. The distribution can be built with Buildroot.

...

rm /etc/init.d/S91netopeer2-server

Building the CC-Link IE TSN Master Application

The application can be built with aarch64-linux-gnu-gcc.

...

<IFACE> is the ethernet interface that GOAL should use. This is either the bridge device “switch” or a standalone port, e.g. “swp0”.

Start CC-Link IE TSN Master application automatically

 

In order to start the Master SDK automatically after boot up, a script must be created in the directory /etc/init.d, e.g. S99GOAL.

...

chmod +x /etc/init.d/S99GOAL

Conformance Test

 

In order to perform the conformance test, several configurations must be tested.

...