...
Create a GOAL EtherNet/IP instance for the given ID and register a callback. This function must be called within the function appl_setup().
Parameter | Description |
---|---|
GOAL_EIP_T **ppEip | [out] EtherNet/IP instance ref |
const uint32_t id | ID of EtherNet/IP instance |
GOAL_EIP_FUNC_CB_T pFunc | GOAL Ethernet/ IP handle application callback |
Table: goal_eipNew parameters
...
Register an application specific CIP class. When the EtherNet/IP stack receives a request for the the registered CIP class it is passed to the handler function.
Parameter | Description |
---|---|
GOAL_EIP_T *pHdlEip | GOAL Ethernet/IP handle |
uint16_t classId | class ID to be registered |
GOAL_EIP_REQ_HANDLER_T pFunc | request handler |
Table: goal_eipCipClassRegister parameters
...
goal_eipCreateAssemblyObject
Adds an CIP instance to the selected ClassCreates an Assembly onto the given Instance. Returns a GOAL_STATUS_T as result.
Info |
---|
On MCTC platforms, the Assembly will be added to the Data Mapper - thus the total size of Assemblies can’t exceed 64 Byte. |
Parameter | Description |
---|---|
GOAL_EIP_T *pHdlEip | GOAL EtherNet/IP handle |
uint32_t instanceId | instance number of the assembly object to create |
uint16_t len | length of the assembly object’s data |
Table: goal_eipCreateAssemblyObject parameters
Code Block | ||
---|---|---|
| ||
res = goal_eipCreateAssemblyObject(pHdlEip, GOAL_APP_ASM_ID_INPUT,
GOAL_APP_ASM_SIZE_INPUT); |
goal_eipCreateAssemblyObjectRpc
Creates an Assembly onto the given Instance on MCTC platforms, the Assembly won’t be added to the Data Mapper. Returns a GOAL_STATUS_T as result.
Info |
---|
Only on MCTC platforms. The Assembly won’t be added to the Data Mapper - therefore no size restriction. |
Parameter | Description |
---|---|
GOAL_EIP_T *pHdlEip | GOAL EtherNet/IP handle |
uint32_t instanceId | instance number of the assembly object to create |
uint16_t len | length of the assembly object’s data |
Table: goal_eipCreateAssemblyObject parameters
Code Block | ||
---|---|---|
| ||
res = goal_eipCreateAssemblyObjecteipCreateAssemblyObjectRpc(pHdlEip, GOAL_APP_ASM_ID_INPUT, GOAL_APP_ASM_SIZE_INPUT); |
...
Get the pointer to the data array of an assembly.
Parameter | Description |
---|---|
GOAL_EIP_T *pHdlEip | GOAL Ethernet/IP handle |
uint32_t instanceId | instance number of the assembly object |
uint8_t **ppData | [out] pointer to assembly data |
uint16_t *pLen | [out] length of assembly data |
Table: goal_eipAssemblyObjectGet parameters
...
Create one Exclusive Owner connection with producing and consuming endpoints.
Parameter | Description |
---|---|
GOAL_EIP_T *pHdlEip | GOAL EtherNet/IP handle |
uint32_t outputAssembly | the O-to-T point to be used for this connection |
uint32_t inputAssembly | the T-to-O point to be used for this connection |
uint32_t configAssembly | the configuration point to be used for this connection |
Table: goal_eipAddExclusiveOwnerConnection parameters
...
goal_eipAddInputOnlyConnection parameters
Parameter | Description |
---|---|
GOAL_EIP_T *pHdlEip | GOAL EtherNet/IP handle |
uint32_t connNum | the number of the input only connection |
uint32_t outputAssembly | the O-to-T point to be used for this connection |
uint32_t inputAssembly | the T-to-O point to be used for this connection |
uint32_t configAssembly | the configuration point to be used for this connection |
Table: goal_eipAddInputOnlyConnection parameters
...
Create multiple Listen Only connections with the same producing and consuming endpoints.
Parameter | Description |
---|---|
GOAL_EIP_T *pHdlEip | GOAL EtherNet/IP handle |
uint32_t connNum | the number of the input only connection. |
uint32_t outputAssembly | the O-to-T point to be used for this connection |
uint32_t inputAssembly | the T-to-O point to be used for this connection |
uint32_t configAssembly | the configuration point to be used for this connection |
Table: goal_eipAddListenOnlyConnection parameters
...
Get the EtherNet/IP version. Returns a GOAL_STATUS_T as result.
Parameter | Description |
---|---|
GOAL_EIP_T *pHdlEip | GOAL EtherNet/IP handle |
char **ppVersion | [out] Ethernet/IP version |
Table: goal_eipGetVersion parameters
...
Set device status bits. The parameter statusBits uses the GOAL_EIP_STATUS_ macros. They can be combined with binary OR.
Parameter | Description |
---|---|
GOAL_EIP_T *pHdlEip | GOAL Ethernet/IP handle |
uint16_t statusBits | status bitmap |
Table: goal_eipDeviceStatusSet parameters
...
Clear device status bits. All bits of statusBits will be cleared. The parameter uses the GOAL_EIP_STATUS_ macros. They can be combined with binary OR.
Parameter | Description |
---|---|
GOAL_EIP_T *pHdlEip | GOAL Ethernet/IP handle |
uint16_t statusBits | status bitmap |
Table: goal_eipDeviceStatusClear parameters
...
Write data to an Assembly Object.
Parameter | Description |
---|---|
GOAL_EIP_T *pHdlEip | GOAL Ethernet/IP handle |
uint32_t instanceId | instance ID oft the Assembly object |
uint8_t *pData | buffer with write data |
uint16_t len | number of bytes to write |
Table: goal_eipAssemblyObjectWrite parameters
...
Read data from an Assembly Object.
Parameter | Description |
---|---|
GOAL_EIP_T *pHdlEip | GOAL Ethernet/IP handle |
uint32_t instanceId | instance ID oft the Assembly object |
uint8_t *pData | buffer for read data |
uint16_t len | number of bytes to read |
Table: goal_eipAssemblyObjectRead parameters
...
Set the serial number of the device. Each device must have a unique serial number. This function updates the Identity instance attribute, i.e. it changes the Serial Number after the EtherNet/IP instance has been created.
Parameter | Description |
---|---|
GOAL_EIP_T *pHdlEip | GOAL Ethernet/IP handle |
uint32_t serialNum | new Serial Number |
Table: goal_eipIdentitySerialNumberSet parameters
...