This chapter describes all necessary steps for creating an application for EtherCAT with GOAL.
Files created by the Industrial Communication Creator
The Industrial Communication Creator (ICC) must be used to specify the options for the library and to define the layout of the object dictionary. Please refer to the manual of the ICC for details.
The following source files are created:
File | Description |
---|---|
ecat_conf.h | contains all configuration macros |
ec_od.c | contains the object dictionary tables |
ec_objects.{c|h} | contains all application variables of the object dictionary |
Table: Source code files generated by the ICC
These files are considered to be part of the application. Other files generated by the ICCare ignored for this chapter.
The object dictionary either has managed variables or application variables. Managed variables are only accessible via the OD API of the library. Application variables are declared in ec_objects.{c|h} and can be used directly.
Application modules
The examples delivered with the EtherCAT library provide a good starting point for developing your own application.
Always include the header files goal_includes.h and goal_ecat.h.
The file goal_appl.c demonstrates how to initialize and use the EtherCAT library in a GOAL application.