Skip to end of banner
Go to start of banner

ECS SimpleConfig Example

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 8 Current »

1 Example project

The location for the ECS SimepleConfig Example is in our Knowledge Base

KB → Software → LFW Host Examples → EtherCAT Slave

For netX90:

2 ECS Sources

Take the netXStudion to open the projcet. The ECS Sources in the ECS SimepleConfig Example are in the folder:

netXStudio_ECSV5_simpleConfig_V2.1.0.0\netX 90 - EtherCAT Slave - simpleConfig V2.1.0.0\Components\cifXApplicationDemoECS\Sources

3 Configuration packet

The ECS Configuration packet is in the file AppECS_DemoApplicationFuction.c

ECSConfigPacket.c

4 Values from ESI file

DeviceInfo values:

#define ECS_PRODUCTCODE_NXEB51_FEATURES                               0x00000038

#define ECS_SECONDARY_VENDORID_HILSCHER                               0xE0000044

#define ECS_REVISIONNUMBER_CIFXMODIFIERMASK                           0x00080004

#define DEV_GROUP_TYPE_INFO                                           "netX"

#define DEV_TYPE_INFO                                                 "NETX ECS Host Example"

#define DEV_NAME_INFO                                                 "NETX ECS Host Example"

need to be same like in ESI file:

Process Data Values:

Choose the number of Input and Output Bytes and tell this the stack in the configuration packet with

  ptConfigReq->tData.tBasicCfg.ulProcessDataOutputSize = sizeof(APP_PROCESS_DATA_INPUT_T); /**< Process Data Output Size from master view */

  ptConfigReq->tData.tBasicCfg.ulProcessDataInputSize = sizeof(APP_PROCESS_DATA_OUTPUT_T); /**< Process Data Input Size from master view */


Change the number of Bytes for RxPdo (Output) and TxPdo (Input) in the ESI file, like in the configuration packet


<RxPdo Sm="2">

          <Index>#x1600</Index>

          <Name>1. RxPDO</Name>

          <Entry>

            <Index>#x2000</Index>

            <SubIndex>1</SubIndex>

            <BitLen>8</BitLen>

            <Name>1 Byte Out (0)</Name>

            <DataType>BYTE</DataType>

          </Entry>

          <Entry>

            <Index>#x2000</Index>

            <SubIndex>2</SubIndex>

            <BitLen>8</BitLen>

            <Name>1 Byte Out (1)</Name>

            <DataType>BYTE</DataType>

          </Entry>

          ........

<TxPdo Sm="3">

          <Index>#x1A00</Index>

          <Name>1. TxPDO</Name>

          <Entry>

            <Index>#x3000</Index>

            <SubIndex>1</SubIndex>

            <BitLen>8</BitLen>

            <Name>1 Byte In (0)</Name>

            <DataType>BYTE</DataType>

          </Entry>

          <Entry>

            <Index>#x3000</Index>

            <SubIndex>2</SubIndex>

            <BitLen>8</BitLen>

            <Name>1 Byte In (1)</Name>

            <DataType>BYTE</DataType>

          </Entry>

          ........


Example ESI file:

10 Byte Output

6 Byte Input

Hilscher NETX90 RE ECS V5.0.X.xml

5 Start Sequenz

  1. Config Stack
  2. Init Config
  3. Start
  4. Stack is in Init State

6 ECM Master

As soon as the ECS Stack is successfully configured and the “Start Communication Request” / “Bus On” is done, the EtherCAT Slave goes in Init State.

The EtherCAT Master now needs to bring the EtherCAT Slave from Init State to Operational State (OP).”








  • No labels