ethercatcoe.h
Go to the documentation of this file.
1 /*
2  * Licensed under the GNU General Public License version 2 with exceptions. See
3  * LICENSE file in the project root for full license information
4  */
5 
11 #ifndef _ethercatcoe_
12 #define _ethercatcoe_
13 
14 #ifdef __cplusplus
15 extern "C"
16 {
17 #endif
18 
20 #define EC_MAXODLIST 1024
21 
23 #define EC_MAXOELIST 256
24 
25 /* Storage for object description list */
26 typedef struct
27 {
35  uint16 DataType[EC_MAXODLIST];
37  uint8 ObjectCode[EC_MAXODLIST];
41  char Name[EC_MAXODLIST][EC_MAXNAME+1];
42 } ec_ODlistt;
43 
44 /* storage for object list entry information */
45 typedef struct
46 {
50  uint8 ValueInfo[EC_MAXOELIST];
52  uint16 DataType[EC_MAXOELIST];
54  uint16 BitLength[EC_MAXOELIST];
56  uint16 ObjAccess[EC_MAXOELIST];
58  char Name[EC_MAXOELIST][EC_MAXNAME+1];
59 } ec_OElistt;
60 
61 #ifdef EC_VER1
62 void ec_SDOerror(uint16 Slave, uint16 Index, uint8 SubIdx, int32 AbortCode);
63 int ec_SDOread(uint16 slave, uint16 index, uint8 subindex,
64  boolean CA, int *psize, void *p, int timeout);
65 int ec_SDOwrite(uint16 Slave, uint16 Index, uint8 SubIndex,
66  boolean CA, int psize, void *p, int Timeout);
67 int ec_RxPDO(uint16 Slave, uint16 RxPDOnumber , int psize, void *p);
68 int ec_TxPDO(uint16 slave, uint16 TxPDOnumber , int *psize, void *p, int timeout);
69 int ec_readPDOmap(uint16 Slave, int *Osize, int *Isize);
70 int ec_readPDOmapCA(uint16 Slave, int Thread_n, int *Osize, int *Isize);
71 int ec_readODlist(uint16 Slave, ec_ODlistt *pODlist);
72 int ec_readODdescription(uint16 Item, ec_ODlistt *pODlist);
73 int ec_readOEsingle(uint16 Item, uint8 SubI, ec_ODlistt *pODlist, ec_OElistt *pOElist);
74 int ec_readOE(uint16 Item, ec_ODlistt *pODlist, ec_OElistt *pOElist);
75 #endif
76 
77 void ecx_SDOerror(ecx_contextt *context, uint16 Slave, uint16 Index, uint8 SubIdx, int32 AbortCode);
78 int ecx_SDOread(ecx_contextt *context, uint16 slave, uint16 index, uint8 subindex,
79  boolean CA, int *psize, void *p, int timeout);
80 int ecx_SDOwrite(ecx_contextt *context, uint16 Slave, uint16 Index, uint8 SubIndex,
81  boolean CA, int psize, void *p, int Timeout);
82 int ecx_RxPDO(ecx_contextt *context, uint16 Slave, uint16 RxPDOnumber , int psize, void *p);
83 int ecx_TxPDO(ecx_contextt *context, uint16 slave, uint16 TxPDOnumber , int *psize, void *p, int timeout);
84 int ecx_readPDOmap(ecx_contextt *context, uint16 Slave, int *Osize, int *Isize);
85 int ecx_readPDOmapCA(ecx_contextt *context, uint16 Slave, int Thread_n, int *Osize, int *Isize);
86 int ecx_readODlist(ecx_contextt *context, uint16 Slave, ec_ODlistt *pODlist);
87 int ecx_readODdescription(ecx_contextt *context, uint16 Item, ec_ODlistt *pODlist);
88 int ecx_readOEsingle(ecx_contextt *context, uint16 Item, uint8 SubI, ec_ODlistt *pODlist, ec_OElistt *pOElist);
89 int ecx_readOE(ecx_contextt *context, uint16 Item, ec_ODlistt *pODlist, ec_OElistt *pOElist);
90 
91 #ifdef __cplusplus
92 }
93 #endif
94 
95 #endif
int ecx_RxPDO(ecx_contextt *context, uint16 Slave, uint16 RxPDOnumber, int psize, void *p)
Definition: ethercatcoe.c:552
int ecx_SDOwrite(ecx_contextt *context, uint16 Slave, uint16 Index, uint8 SubIndex, boolean CA, int psize, void *p, int Timeout)
Definition: ethercatcoe.c:330
void ec_SDOerror(uint16 Slave, uint16 Index, uint8 SubIdx, int32 AbortCode)
Definition: ethercatcoe.c:1322
uint8_t uint8
Definition: osal.h:28
int ec_readPDOmapCA(uint16 Slave, int Thread_n, int *Osize, int *Isize)
Definition: ethercatcoe.c:1459
int ecx_SDOread(ecx_contextt *context, uint16 slave, uint16 index, uint8 subindex, boolean CA, int *psize, void *p, int timeout)
Definition: ethercatcoe.c:120
uint16_t uint16
Definition: osal.h:29
int ecx_TxPDO(ecx_contextt *context, uint16 slave, uint16 TxPDOnumber, int *psize, void *p, int timeout)
Definition: ethercatcoe.c:599
int ec_readODlist(uint16 Slave, ec_ODlistt *pODlist)
Definition: ethercatcoe.c:1471
int ec_TxPDO(uint16 slave, uint16 TxPDOnumber, int *psize, void *p, int timeout)
Definition: ethercatcoe.c:1401
int ec_readPDOmap(uint16 Slave, int *Osize, int *Isize)
Definition: ethercatcoe.c:1441
int ec_readOE(uint16 Item, ec_ODlistt *pODlist, ec_OElistt *pOElist)
Definition: ethercatcoe.c:1501
#define EC_MAXOELIST
Definition: ethercatcoe.h:23
int ec_readODdescription(uint16 Item, ec_ODlistt *pODlist)
Definition: ethercatcoe.c:1483
uint16 Slave
Definition: ethercatcoe.h:29
int slave
Definition: aliastool.c:44
int ecx_readPDOmap(ecx_contextt *context, uint16 Slave, int *Osize, int *Isize)
Definition: ethercatcoe.c:810
int32_t int32
Definition: osal.h:27
int ec_RxPDO(uint16 Slave, uint16 RxPDOnumber, int psize, void *p)
Definition: ethercatcoe.c:1384
int ecx_readOE(ecx_contextt *context, uint16 Item, ec_ODlistt *pODlist, ec_OElistt *pOElist)
Definition: ethercatcoe.c:1294
#define EC_MAXNAME
Definition: ethercatmain.h:23
uint16 Entries
Definition: ethercatcoe.h:31
uint16 Entries
Definition: ethercatcoe.h:48
#define EC_MAXODLIST
Definition: ethercatcoe.h:20
int ecx_readOEsingle(ecx_contextt *context, uint16 Item, uint8 SubI, ec_ODlistt *pODlist, ec_OElistt *pOElist)
Definition: ethercatcoe.c:1203
int ec_SDOread(uint16 slave, uint16 index, uint8 subindex, boolean CA, int *psize, void *p, int timeout)
Definition: ethercatcoe.c:1344
void ecx_SDOerror(ecx_contextt *context, uint16 Slave, uint16 Index, uint8 SubIdx, int32 AbortCode)
Definition: ethercatcoe.c:66
int ec_readOEsingle(uint16 Item, uint8 SubI, ec_ODlistt *pODlist, ec_OElistt *pOElist)
Definition: ethercatcoe.c:1488
int ec_SDOwrite(uint16 Slave, uint16 Index, uint8 SubIndex, boolean CA, int psize, void *p, int Timeout)
Definition: ethercatcoe.c:1367
int ecx_readODdescription(ecx_contextt *context, uint16 Item, ec_ODlistt *pODlist)
Definition: ethercatcoe.c:1117
int ecx_readODlist(ecx_contextt *context, uint16 Slave, ec_ODlistt *pODlist)
Definition: ethercatcoe.c:998
int ecx_readPDOmapCA(ecx_contextt *context, uint16 Slave, int Thread_n, int *Osize, int *Isize)
Definition: ethercatcoe.c:910


soem
Author(s): Arthur Ketels and M.J.G. van den Molengraft
autogenerated on Sat Jun 27 2020 03:48:20