| Wireshark 4.7.3 The Wireshark network protocol analyzer

Loading...
Searching...
No Matches
packet-ams.h
1/* packet-ams.h
2 *
3 * Copyright (c) 2007 by Beckhoff Automation GmbH
4 *
5 * Wireshark - Network traffic analyzer
6 * By Gerald Combs <gerald@wireshark.org>
7 * Copyright 1998 Gerald Combs
8 *
9 * SPDX-License-Identifier: GPL-2.0-or-later
10 */
11
12#ifndef __PACKET_AMS_H__
13#define __PACKET_AMS_H__
14
15/* FIXED PORTS */
16
17#define AMSPORT_ROUTER 1
18#define AMSPORT_DEBUGGER 2
19
20#define AMSPORT_LOGGER 100
21#define AMSPORT_EVENTLOG 110
22#define AMSPORT_R0_RTIME 200
23#define AMSPORT_R0_TRACE (AMSPORT_R0_RTIME+90)
24#define AMSPORT_R0_IO 300
25#define AMSPORT_R0_SPS 400
26#define AMSPORT_R0_NC 500
27#define AMSPORT_R0_NCSAF 501
28#define AMSPORT_R0_NCSVB 511
29#define AMSPORT_R0_ISG 550
30#define AMSPORT_R0_CNC 600
31#define AMSPORT_R0_LINE 700
32#define AMSPORT_R0_PLC 800
33#define AMSPORT_R0_CAM 900
34#define AMSPORT_R0_CAMTOOL 950
35
36#define AMSPORT_R0_IOPORTBEGIN 1000
37#define AMSPORT_R0_IOPORTEND 1199
38
39#define AMSPORT_R0_USER 2000
40
41#define AMSPORT_R3_SYSSERV 10000
42#define AMSPORT_R3_CTRLPROG 10000
43#define AMSPORT_R3_SYSCTRL 10001
44#define AMSPORT_R3_SYSSAMPLER 10100
45#define AMSPORT_R3_TCPRAWCONN 10200
46#define AMSPORT_R3_TCPIPSERVER 10201
47#define AMSPORT_R3_SYSMANAGER 10300
48#define AMSPORT_R3_SMSSERVER 10400
49#define AMSPORT_R3_MODBUSSERVER 10500
50#define AMSPORT_R3_PLCCONTROL 10800
51#define AMSPORT_R3_NCCTRL 11000
52#define AMSPORT_R3_NCINTERPRETER 11500
53#define AMSPORT_R3_STRECKECTRL 12000
54#define AMSPORT_R3_CAMCTRL 13000
55#define AMSPORT_R3_SCOPE 14000
56#define AMSPORT_R3_SINECH1 15000
57#define AMSPORT_R3_CONTROLNET 16000
58#define AMSPORT_R3_OPCSERVER 17000
59#define AMSPORT_R3_OPCCLIENT 17500
60
61#define AMSPORT_R3_CUSTOMER_FIRST 25000
62#define AMSPORT_R3_CUSTOMER_LAST 25999
63
64#define AMSPORT_FIRST 1
65#define AMSPORT_LAST 0xFFFE
66
67#define AMSPORT_UNFIXEDPORT 0
68#define AMSPORT_USEDEFAULT 0xFFFF
69
70#define AMSPORT_IOBOXBEGIN_USB 0x6E00
71#define AMSPORT_IOBOXEND_USB 0x6EFF
72#define AMSPORT_IODEVBEGIN 0x7000
73#define AMSPORT_IODEVEND 0x70FF
74#define AMSPORT_IOBOXBEGIN 0x7100
75#define AMSPORT_IOBOXEND 0x7FFF
76
77#define AMSPORT_FREEBEGIN 0x8000
78#define AMSPORT_FREEEND 0xBFFF
79
80
81#define AMSPORT_NAMESIZE 31
82
86 typedef enum
87{
88 PORTTYPE_INVALID = -1,
89 PORTTYPE_ROUTER = 0x00,
90 PORTTYPE_R3PORT = 0x01,
91 PORTTYPE_R0CTRLPORT = 0x02,
92 PORTTYPE_R0TASKPORT = 0x03,
93 PORTTYPE_R0IOPORT = 0x04,
94 PORTTYPE_TPPORT = 0x05,
95 PORTTYPE_MAXVAL = 0xFF
96} AMSPORT_TYPE;
97
98/* Command IDs */
99
100#define AMSCMD_LOGMESSAGE 0x0001
101#define AMSCMD_ROUTERSHUTDOWN 0x0002
102#define AMSCMD_ROUTERACTIVATED 0x0003
103#define AMSCMD_SYSTEMREMOVED 0x0004
104#define AMSCMD_CLOSECONNECTION 0x0005
105#define AMSCMD_SIGNALSTART 0x00FB
106#define AMSCMD_SIGNALSTOP 0x00FC
107#define AMSCMD_HANDLERETAINDATA 0x00FD
108#define AMSCMD_DEVICECONFIGID 0x00FE
109#define AMSCMD_DOWNLOADSYMBOLS 0x00FF
110
111#define AMS_ERRLOGCMDS 0x100
112
113#define AMS_TASKCMDS 0x500
114#define AMS_CTRLCMDS 0x600
115
116#define AMS_ROUTERCMDS 0x900
117#define AMS_RTIMECMDS 0x1000
118#define AMS_TRACECMDS (AMS_RTIMECMDS+0x900)
119#define AMS_IOCMDS 0x2000
120#define AMS_C1220CMDS (AMS_IOCMDS+0x100)
121#define AMS_FCxxxxCMDS (AMS_IOCMDS+0x200)
122#define AMS_SPSCMDS 0x3000
123#define AMS_NCCMDS 0x4000
124#define AMS_PLCCMDS 0x5000
125#define AMS_LINECMDS 0x6000
126#define AMS_CAMCMDS 0x7000
127
128#define AMS_CMDSPECIFIC 0x8000
129
130
131#define AMSERRCODEISWARNING 0x80000000
132
133/* Error Arrays */
134
135#define ERR_ROUTERERRS 0x0500
136#define ERR_TASKERRS 0x0600
137#define ERR_ADSERRS 0x0700
138#define ERR_SYSSMPLERRS 0x0800
139#define ERR_RTIMEERRS 0x1000
140#define ERR_TRACEERRS (ERR_RTIMEERRS+0x900)
141#define ERR_IOERRS 0x2000
142#define ERR_DPSLAVE (ERR_IOERRS+0x900)
143#define ERR_CP5412A2 (ERR_IOERRS+0xA00)
144#define ERR_ASP (ERR_IOERRS+0xB00)
145#define ERR_CANSLAVE (ERR_IOERRS+0xC00)
146#define ERR_CIF30 (ERR_IOERRS+0xD00)
147#define ERR_IBSSLAVE (ERR_IOERRS+0xE00)
148#define ERR_SPSERRS 0x3000
149#define ERR_NCERRS 0x4000
150#define ERR_PLCERRS 0x6000
151#define ERR_STRKERRS 0x7000
152
153#define ERR_PRJSPECIFIC 0x7800
154
155#define ERR_DRIVEERRS_C3D 0xD000
156#define ERR_DRIVEERRS_C2D 0xE000
157#define ERR_DRIVEERRS_C1D 0xF000
158
159
160/* Global Error codes */
161#define ERR_NOERROR 0
162#define ERR_INTERNAL 1
163#define ERR_NORTIME 2
164#define ERR_ALLOCLOCKEDMEM 3
165#define ERR_INSERTMAILBOX 4
166#define ERR_WRONGRECEIVEHMSG 5
167#define ERR_TARGETPORTNOTFOUND 6
168#define ERR_TARGETMACHINENOTFOUND 7
169#define ERR_UNKNOWNCMDID 8
170#define ERR_BADTASKID 9
171#define ERR_NOIO 10
172#define ERR_UNKNOWNAMSCMD 11
173#define ERR_WIN32ERROR 12
174#define ERR_PORTNOTCONNECTED 13
175#define ERR_INVALIDAMSLENGTH 14
176#define ERR_INVALIDAMSNETID 15
177#define ERR_LOWINSTLEVEL 16
178#define ERR_NODEBUGINTAVAILABLE 17
179#define ERR_PORTDISABLED 18
180#define ERR_PORTALREADYCONNECTED 19
181#define ERR_AMSSYNC_W32ERROR 20
182#define ERR_AMSSYNC_TIMEOUT 21
183#define ERR_AMSSYNC_AMSERROR 22
184#define ERR_AMSSYNC_NOINDEXINMAP 23
185#define ERR_INVALIDAMSPORT 24
186#define ERR_NOMEMORY 25
187#define ERR_TCPSEND 26
188#define ERR_HOSTUNREACHABLE 27
189#define ERR_INVALIDAMSFRAGMENT 28
190
191
192/* ROUTER */
193#define ROUTERERR_NOLOCKEDMEMORY 0 + ERR_ROUTERERRS
194#define ROUTERERR_RESIZEMEMORY 1 + ERR_ROUTERERRS
195#define ROUTERERR_MAILBOXFULL 2 + ERR_ROUTERERRS
196#define ROUTERERR_DEBUGBOXFULL 3 + ERR_ROUTERERRS
197#define ROUTERERR_UNKNOWNPORTTYPE 4 + ERR_ROUTERERRS
198#define ROUTERERR_NOTINITIALIZED 5 + ERR_ROUTERERRS
199#define ROUTERERR_PORTALREADYINUSE 6 + ERR_ROUTERERRS
200#define ROUTERERR_NOTREGISTERED 7 + ERR_ROUTERERRS
201#define ROUTERERR_NOMOREQUEUES 8 + ERR_ROUTERERRS
202#define ROUTERERR_INVALIDPORT 9 + ERR_ROUTERERRS
203#define ROUTERERR_NOTACTIVATED 10 + ERR_ROUTERERRS
204#define ROUTERERR_FRAGMENTBOXFULL 11 + ERR_ROUTERERRS
205#define ROUTERERR_FRAGMENTTIMEOUT 12 + ERR_ROUTERERRS
206#define ROUTERERR_TOBEREMOVED 13 + ERR_ROUTERERRS
207
208#define TASKERR_UNKNOWNTASKTYPE 0 + ERR_TASKERRS
209#define TASKERR_TASKTERMINATED 1 + ERR_TASKERRS
210#define TASKERR_EVENTTIMEOUT 2 + ERR_TASKERRS
211
212
213/* System Sampler */
214#define SMPLERR_INTERNAL 0 + ERR_SYSSMPLERRS
215#define SMPLERR_INVALIDTYPE 1 + ERR_SYSSMPLERRS
216
217
218/* RTIME */
219#define RTERR_INTERNAL 0 + ERR_RTIMEERRS
220#define RTERR_BADTIMERPERIODS 1 + ERR_RTIMEERRS
221#define RTERR_INVALIDTASKPTR 2 + ERR_RTIMEERRS
222#define RTERR_INVALIDSTACKPTR 3 + ERR_RTIMEERRS
223#define RTERR_PRIOEXISTS 4 + ERR_RTIMEERRS
224#define RTERR_NOMORETCB 5 + ERR_RTIMEERRS
225#define RTERR_NOMORESEMAS 6 + ERR_RTIMEERRS
226#define RTERR_NOMOREQUEUES 7 + ERR_RTIMEERRS
227#define RTERR_SHUTDOWNTIMEOUT 8 + ERR_RTIMEERRS
228#define RTERR_CHECKHOSTOSNOPCR 9 + ERR_RTIMEERRS
229#define RTERR_CHECKHOSTOSNOIDT 10 + ERR_RTIMEERRS
230#define RTERR_CHECKHOSTOSNOPHYSMEM 11 + ERR_RTIMEERRS
231#define RTERR_CHECKHOSTOSMAPERR 12 + ERR_RTIMEERRS
232#define RTERR_EXTIRQALREADYDEF 13 + ERR_RTIMEERRS
233#define RTERR_EXTIRQNOTDEF 14 + ERR_RTIMEERRS
234#define RTERR_EXTIRQINSTALLFAILED 15 + ERR_RTIMEERRS
235#define RTERR_IRQLNOTLESSOREQUAL 16 + ERR_RTIMEERRS
236#define RTERR_SYSCLOCKFAILURE 17 + ERR_RTIMEERRS
237
238
239/* TRACE */
240#define TRACEERR_REGISTRY 0 + ERR_TRACEERRS
241#define TRACEERR_MEMMAP 1 + ERR_TRACEERRS
242#define TRACEERR_NOTAVAIL 2 + ERR_TRACEERRS
243
244
245/* IO */
246#define IOERR_INTERNAL (0 + ERR_IOERRS)
247#define IOERR_BADCARDNO (1 + ERR_IOERRS)
248#define IOERR_INVALIDCARDADDR (2 + ERR_IOERRS)
249#define IOERR_CDLLISTFULL (3 + ERR_IOERRS)
250#define IOERR_BADCDLPARAM (4 + ERR_IOERRS)
251#define IOERR_OPENIOFAILED (5 + ERR_IOERRS)
252#define IOERR_RESETIOFAILED (6 + ERR_IOERRS)
253#define IOERR_UNKNOWNDEVICE (7 + ERR_IOERRS)
254#define IOERR_UNKNOWNDEVICEID (8 + ERR_IOERRS)
255#define IOERR_UNKNOWNIMAGEID (9 + ERR_IOERRS)
256#define IOERR_GETIOSTATE (10 + ERR_IOERRS)
257#define IOERR_BADIMAGEID (11 + ERR_IOERRS)
258#define IOERR_NOMORECLIENTSPACE (12 + ERR_IOERRS)
259#define IOERR_CLIENTINFONOTFOUND (13 + ERR_IOERRS)
260#define IOERR_CDLNOTINUSE (14 + ERR_IOERRS)
261#define IOERR_TIMEOUTWITHDEVICE (15 + ERR_IOERRS)
262#define IOERR_C1220FUNC_1 (16 + ERR_IOERRS)
263#define IOERR_C1220FUNC_9 (17 + ERR_IOERRS)
264#define IOERR_C1220FUNC_C (18 + ERR_IOERRS)
265#define IOERR_C1220FUNC_10 (19 + ERR_IOERRS)
266#define IOERR_C1220FUNC_1_MAXSEND (20 + ERR_IOERRS)
267#define IOERR_C1220FUNC_1_ADDRSET (21 + ERR_IOERRS)
268#define IOERR_C1220FUNC_1_BREAK (22 + ERR_IOERRS)
269#define IOERR_C1220FUNC_1_BREAK0 (23 + ERR_IOERRS)
270#define IOERR_C1220FUNC_1_BREAK1 (24 + ERR_IOERRS)
271#define IOERR_C1220FUNC_1_BREAK2 (25 + ERR_IOERRS)
272#define IOERR_C1220FUNC_1_BREAK3 (26 + ERR_IOERRS)
273#define IOERR_C1220FUNC_1_BREAK4 (27 + ERR_IOERRS)
274#define IOERR_C1220FUNC_1_BREAK5 (28 + ERR_IOERRS)
275#define IOERR_C1220FUNC_1_BREAK6 (29 + ERR_IOERRS)
276#define IOERR_C1220FUNC_1_BREAK7 (30 + ERR_IOERRS)
277#define IOERR_C1220FUNC_1_BREAK8 (31 + ERR_IOERRS)
278#define IOERR_C1220FUNC_1_BREAK9 (32 + ERR_IOERRS)
279#define IOERR_C1220FUNC_1_BREAK10 (33 + ERR_IOERRS)
280#define IOERR_C1220FUNC_1_BREAK11 (34 + ERR_IOERRS)
281#define IOERR_C1220FUNC_1_BREAK12 (35 + ERR_IOERRS)
282#define IOERR_C1220FUNC_1_BREAK13 (36 + ERR_IOERRS)
283#define IOERR_C1220FUNC_1_BREAK14 (37 + ERR_IOERRS)
284#define IOERR_C1220FUNC_1_BREAK15 (38 + ERR_IOERRS)
285#define IOERR_C1220FUNC_1_BREAK16 (39 + ERR_IOERRS)
286#define IOERR_SPC3DEVINITDP (40 + ERR_IOERRS)
287#define IOERR_SPC3UPDATEOUTPUT (41 + ERR_IOERRS)
288#define IOERR_CIF30READDIAG (42 + ERR_IOERRS)
289#define IOERR_CIF30COMMNOTSTARTED (43 + ERR_IOERRS)
290#define IOERR_CIF30SLAVEPARASIZE (44 + ERR_IOERRS)
291#define IOERR_CIF30NOPARAS (45 + ERR_IOERRS)
292#define IOERR_CIF30SLAVEERROR (46 + ERR_IOERRS)
293#define IOERR_CIF30WATCHDOGEXPIRED (47 + ERR_IOERRS)
294#define IOERR_UNKNOWNDEVICECMD (48 + ERR_IOERRS)
295#define IOERR_CIF40MESSAGEHANDLING (49 + ERR_IOERRS)
296#define IOERR_CIF40PARAERROR (50 + ERR_IOERRS)
297#define IOERR_CIF40WATCHDOGEXPIRED (51 + ERR_IOERRS)
298#define IOERR_CIF40FLAGERROR (52 + ERR_IOERRS)
299#define IOERR_CIF40COMMNOTSTARTED (53 + ERR_IOERRS)
300#define IOERR_CIF40READDIAG (54 + ERR_IOERRS)
301#define IOERR_CIF40SLAVEERROR (55 + ERR_IOERRS)
302#define IOERR_CIF40GLOBALERROR (56 + ERR_IOERRS)
303#define IOERR_CIF40CONFIGLIST (57 + ERR_IOERRS)
304#define IOERR_CP5412A2SLAVEPARASIZE (58 + ERR_IOERRS)
305#define IOERR_CP5412A2NOPARAS (59 + ERR_IOERRS)
306#define IOERR_CP5412A2SLAVEERROR (60 + ERR_IOERRS)
307#define IOERR_CP5412A2FATAL (61 + ERR_IOERRS)
308#define IOERR_CP5412A2MAILBOXUSED (62 + ERR_IOERRS)
309#define IOERR_BEGINCONFIGWHILETICKER (63 + ERR_IOERRS)
310#define IOERR_UNEXPECTEDBOXCOUNT (64 + ERR_IOERRS)
311#define IOERR_C1200CHECKADDR (65 + ERR_IOERRS)
312#define IOERR_C1200INTENSITYTEST (66 + ERR_IOERRS)
313#define IOERR_NOIMAGE (67 + ERR_IOERRS)
314#define IOERR_INVALIDIMAGEOFFSSIZE (68 + ERR_IOERRS)
315#define IOERR_FORCESCOUNTEXCEEDEDMAXIMUM (69 + ERR_IOERRS)
316#define IOERR_SERCOSLIFECOUNTERERR (70 + ERR_IOERRS)
317#define IOERR_C1220NOTFOUND (71 + ERR_IOERRS)
318#define IOERR_AMSDEVICENOAMSINTF (72 + ERR_IOERRS)
319#define IOERR_AMSDEVICEAMSCMDIDNOTSUPP (73 + ERR_IOERRS)
320#define IOERR_AMSDEVICEAMSSERVICERUNNING (74 + ERR_IOERRS)
321#define IOERR_PLCINTERFACE_BUSY (75 + ERR_IOERRS)
322#define IOERR_PLCINTERFACE_FAULT (76 + ERR_IOERRS)
323#define IOERR_PLCINTERFACE_TIMEOUT (77 + ERR_IOERRS)
324#define IOERR_PLCINTERFACE_RESETTIMEOUT (78 + ERR_IOERRS)
325#define IOERR_PLCINTERFACE_NODATAEXCH (79 + ERR_IOERRS)
326#define IOERR_PLCINTERFACE_RESET (80 + ERR_IOERRS)
327#define IOERR_CP5412A2INVALIDADDR (81 + ERR_IOERRS)
328#define IOERR_CP5412A2INVALIDPORT (82 + ERR_IOERRS)
329#define IOERR_AMSDEVICEBADBOXNO (83 + ERR_IOERRS)
330#define IOERR_AMSDEVICEBADTYPE (84 + ERR_IOERRS)
331#define IOERR_AMSDEVICEILLEGALADDRESS (85 + ERR_IOERRS)
332#define IOERR_CP5412A2INVALIDBOX (86 + ERR_IOERRS)
333#define IOERR_AMSDEVICEFIFOOVERFLOW (87 + ERR_IOERRS)
334#define IOERR_AMSDEVICEAMSSEQUENCEERROR (88 + ERR_IOERRS)
335#define IOERR_CP5412A2DPV1SYNTAXERROR (89 + ERR_IOERRS)
336#define IOERR_CP5412A2DEVICENOTRUNNING (90 + ERR_IOERRS)
337#define IOERR_AMSDEVICENOTRUNNING (91 + ERR_IOERRS)
338#define IOERR_AMSDEVICEBOXNOTDEFINED (92 + ERR_IOERRS)
339#define IOERR_CP5412A2BADSERVICEPARA (93 + ERR_IOERRS)
340#define IOERR_CP5412A2FIFOOVERFLOW (94 + ERR_IOERRS)
341#define IOERR_COMPORTOPENFAILED (95 + ERR_IOERRS)
342#define IOERR_CIF30BADMESSAGERESPONSE (96 + ERR_IOERRS)
343#define IOERR_CIF30DELETEDATABASE (97 + ERR_IOERRS)
344#define IOERR_CIF30STARTSEQFAILED (98 + ERR_IOERRS)
345#define IOERR_CIF30DOWNLOADFAILED (99 + ERR_IOERRS)
346#define IOERR_CIF30ENDSEQFAILED (100 + ERR_IOERRS)
347#define IOERR_CIF30BUSLOADFAILED (101 + ERR_IOERRS)
348#define IOERR_PLCINTERFACE_RESETREQ (102 + ERR_IOERRS)
349#define IOERR_CP5412A2INVALIDCYCLETICKS (103 + ERR_IOERRS)
350#define IOERR_CP5412A2DPBUSFAULT (104 + ERR_IOERRS)
351#define IOERR_INVALIDTERMCONFIG (105 + ERR_IOERRS)
352#define IOERR_SERCANSBREAK (106 + ERR_IOERRS)
353#define IOERR_SERCANSPHASE0 (107 + ERR_IOERRS)
354#define IOERR_SERCANSPHASE1 (108 + ERR_IOERRS)
355#define IOERR_SERCANSPHASE2 (109 + ERR_IOERRS)
356#define IOERR_SERCANSPHASE3 (110 + ERR_IOERRS)
357#define IOERR_SERCANSPHASE4 (111 + ERR_IOERRS)
358#define IOERR_SERCANSNCSERVICECHNFAILED (112 + ERR_IOERRS)
359#define IOERR_RESOURCECONFICT (113 + ERR_IOERRS)
360#define IOERR_C1220INITSTRINGCOMM (114 + ERR_IOERRS)
361#define IOERR_C1220REGSTRINGSLAVE (115 + ERR_IOERRS)
362#define IOERR_C1220STRREGFAULT (116 + ERR_IOERRS)
363#define IOERR_IOSTATEBUSY (117 + ERR_IOERRS)
364#define IOERR_IBSSCITWATCHDOGEXPIRED (118 + ERR_IOERRS)
365#define IOERR_IBSSCITSYNCMAILBOXERROR (119 + ERR_IOERRS)
366#define IOERR_IBSSCITCONFIRMDIAGERROR (120 + ERR_IOERRS)
367#define IOERR_IBSSCITCREATECFGERROR (121 + ERR_IOERRS)
368#define IOERR_IBSSCITCOMPLETEREADCFGERROR (122 + ERR_IOERRS)
369#define IOERR_IBSSCITSTARTDATATRANSFERERROR (123 + ERR_IOERRS)
370#define IOERR_IBSSCITSETFAULTINDICATION (124 + ERR_IOERRS)
371#define IOERR_IBSSCITSETDEVICESTATEINDICATION (125 + ERR_IOERRS)
372#define IOERR_IBSSCITSETBUSERRORINDICATION (126 + ERR_IOERRS)
373#define IOERR_IBSSCITSTOPDATATRANSFERERROR (127 + ERR_IOERRS)
374#define IOERR_IBSSCITSETVALUEINDICATION (128 + ERR_IOERRS)
375#define IOERR_IBSSCITINITIATEREQ (129 + ERR_IOERRS)
376#define IOERR_IBSSCITACTIVATECFGERROR (130 + ERR_IOERRS)
377#define IOERR_IBSSCITCOMPACTLOADPDRLERROR (131 + ERR_IOERRS)
378#define IOERR_IBSSCITCONTROLPARAMERROR (132 + ERR_IOERRS)
379#define IOERR_IBSSCITDEACTIVATECFGERROR (133 + ERR_IOERRS)
380#define IOERR_IBSSCITINVALIDPORT (134 + ERR_IOERRS)
381#define IOERR_C1220FUNC_7_ADDRESSTEST (135 + ERR_IOERRS)
382#define IOERR_FCXXXXMAILBOXUSED (136 + ERR_IOERRS)
383#define IOERR_FCXXXXDPRAMTOOSMALL (137 + ERR_IOERRS)
384#define IOERR_COMUPS_PORTINUSE (138 + ERR_IOERRS)
385#define IOERR_COMUPS_NOUPSORNOPOWER (139 + ERR_IOERRS)
386#define IOERR_COMUPS_LOWBATTERY (140 + ERR_IOERRS)
387#define IOERR_UPS_ALREADY_EXISTS (141 + ERR_IOERRS)
388#define IOERR_FCXXXXSTARTUPFAILED (142 + ERR_IOERRS)
389#define IOERR_C1220GETSTRINGCOMMTXSTATEFAILED (143 + ERR_IOERRS)
390#define IOERR_C1220SENDSTRINGTOSLAVEFAILED (144 + ERR_IOERRS)
391#define IOERR_CP5613FIRMWARELOADFAILED (145 + ERR_IOERRS)
392#define IOERR_CP5613DPOPENFAILED (146 + ERR_IOERRS)
393#define IOERR_CP5613FATALERROR (147 + ERR_IOERRS)
394#define IOERR_CP5613DPUSEROPENFAILED (148 + ERR_IOERRS)
395#define IOERR_CP5613DPSETMODESTOPFAILED (149 + ERR_IOERRS)
396#define IOERR_CP5613DPSETMODECLEARFAILED (150 + ERR_IOERRS)
397#define IOERR_CP5613DPSETMODEOPERATEFAILED (151 + ERR_IOERRS)
398#define IOERR_CP5613NODATAAVAILABLE (152 + ERR_IOERRS)
399#define IOERR_CP5613DPSERVICEFAILED (153 + ERR_IOERRS)
400#define IOERR_CP5613DPSETMODEOFFLINEFAILED (154 + ERR_IOERRS)
401#define IOERR_CP5613DPUSERCLOSEFAILED (155 + ERR_IOERRS)
402#define IOERR_CP5613DPCLOSEFAILED (156 + ERR_IOERRS)
403#define IOERR_CP5613OTHERSERVICERETURNED (157 + ERR_IOERRS)
404#define IOERR_CP5613DPOKASYNC (158 + ERR_IOERRS)
405#define IOERR_CP5613DPERROREVENT (159 + ERR_IOERRS)
406#define IOERR_CP5613DPERROREVENTNET (160 + ERR_IOERRS)
407#define IOERR_CP5613DPERRORREQPAR (161 + ERR_IOERRS)
408#define IOERR_CP5613DPERRORCI (162 + ERR_IOERRS)
409#define IOERR_CP5613DPERRORRES (163 + ERR_IOERRS)
410#define IOERR_CP5613DPERRORUSRABORT (164 + ERR_IOERRS)
411#define IOERR_PKWSYNTAXERROR (165 + ERR_IOERRS)
412#define IOERR_CP5412A2CDLCFGFAULT (166 + ERR_IOERRS)
413#define IOERR_IBSSCITINITLOADCFGERROR (168 + ERR_IOERRS)
414#define IOERR_IBSSCITLOADCFGERROR (169 + ERR_IOERRS)
415#define IOERR_IBSSCITTERMLOADCFGERROR (170 + ERR_IOERRS)
416#define IOERR_IBSSCITINITLOADPDRLERROR (171 + ERR_IOERRS)
417#define IOERR_IBSSCITLOADPDRLERROR (172 + ERR_IOERRS)
418#define IOERR_IBSSCITTERMLOADPDRLERROR (173 + ERR_IOERRS)
419#define IOERR_IBSSCITDELETEOBJECTERROR (174 + ERR_IOERRS)
420#define IOERR_IBSSCITCONTROLACTIVECFGGERROR (175 + ERR_IOERRS)
421#define IOERR_IBSSCITINITLOADPDDLERROR (176 + ERR_IOERRS)
422#define IOERR_IBSSCITLOADPDDLERROR (177 + ERR_IOERRS)
423#define IOERR_IBSSCITTERMLOADPDDLERROR (178 + ERR_IOERRS)
424#define IOERR_NOMOREMAPSINIMAGE (179 + ERR_IOERRS)
425#define IOERR_IBSSCITSETSLAVEINFOERROR (180 + ERR_IOERRS)
426#define IOERR_CIF40NOTREADY (190 + ERR_IOERRS)
427#define IOERR_C1220SETAMSNETIDFAILED (191 + ERR_IOERRS)
428#define IOERR_AMSDEVICEIORESETACTIVE (192 + ERR_IOERRS)
429#define IOERR_C1220INITPROGRAMMABLECDL (193 + ERR_IOERRS)
430#define IOERR_FCXXXXINVALIDBOXNODOWNLOADED (194 + ERR_IOERRS)
431
432
433#define IOERR_CP5412A2_RESET (4 + ERR_CP5412A2)
434#define IOERR_CP5412A2_LOADBUSPARA (5 + ERR_CP5412A2)
435#define IOERR_CP5412A2_LOADSLAVE (6 + ERR_CP5412A2)
436#define IOERR_CP5412A2_LOADPRMDATA (7 + ERR_CP5412A2)
437#define IOERR_CP5412A2_LOADCFGDATA (8 + ERR_CP5412A2)
438#define IOERR_CP5412A2_LOADSLAVECDL (9 + ERR_CP5412A2)
439#define IOERR_CP5412A2_ACTIVATESLAVE (10 + ERR_CP5412A2)
440#define IOERR_CP5412A2_ADDSLAVE (11 + ERR_CP5412A2)
441#define IOERR_CP5412A2_DELETESLAVE (12 + ERR_CP5412A2)
442#define IOERR_CP5412A2_STARTDATAEXCH (13 + ERR_CP5412A2)
443#define IOERR_CP5412A2_STOPDATAEXCH (14 + ERR_CP5412A2)
444#define IOERR_CP5412A2_DEBUGDPM (15 + ERR_CP5412A2)
445
446
447/* FC Box - stamndadisiert */
448
449#define FCERR_FMNOERROR 0
450#define FCERR_FMDEACTIVATED 1
451#define FCERR_FMNOANSWER 2
452#define FCERR_FMMASTERLOCK 3
453#define FCERR_FMINVALIDRESPONSE 4
454#define FCERR_FMPRMFAULT 5
455#define FCERR_FMFEATURENOTSUPPORTED 6
456#define FCERR_FMCFGFAULT 7
457#define FCERR_FMSTATIONNOTREADY 8
458#define FCERR_FMSTATDIAG 9
459#define FCERR_FMDIAGOVERFLOW 10
460#define FCERR_FMPHYSICALFAULT 11
461#define FCERR_FMDATATRANSFERLEFT 12
462#define FCERR_FMSYNIFAULT 13
463#define FCERR_FMTELEGRAMFAULT 14
464#define FCERR_FMNORESSOURCES 15
465#define FCERR_FMSERVICENOTACTIVATED 16
466#define FCERR_FMUNEXPECTEDTELEGRAM 17
467#define FCERR_FMSTATIONREADY 18
468#define FCERR_FMADSSTARTUP 19
469#define FCERR_FMINVALIDINDICATION 20
470#define FCERR_FMSTATIONINFAULT 21
471#define FCERR_FMINDICATIONMISSED 22
472#define FCERR_FMWAITFORINDICATIONS 23
473
474#define FCERR_FMFBUSSPECIFIC_1 40
475#define FCERR_FMFBUSSPECIFIC_2 41
476#define FCERR_FMFBUSSPECIFIC_3 42
477#define FCERR_FMFBUSSPECIFIC_4 43
478#define FCERR_FMFBUSSPECIFIC_5 44
479#define FCERR_FMFBUSSPECIFIC_6 45
480#define FCERR_FMFBUSSPECIFIC_7 46
481#define FCERR_FMFBUSSPECIFIC_8 47
482#define FCERR_FMFBUSSPECIFIC_9 48
483
484
485/* FC520x */
486
487#define FCERR_FMFC520XHEARTBEATFAULT 40
488#define FCERR_FMFC520XSHUTDOWNRECEIVED 41
489#define FCERR_FMFC520XEKEYERROR_VENDOR 42
490#define FCERR_FMFC520XEKEYERROR_DEVTYPE 43
491#define FCERR_FMFC520XEKEYERROR_PRODCODE 44
492#define FCERR_FMFC520XEKEYERROR_REVISION 45
493#define FCERR_FMFC520XSTARTUPATTR 46
494#define FCERR_FMFC520XIOLENGTH_PROD 47
495#define FCERR_FMFC520XIOLENGTH_CONS 48
496
497#define FCERR_FMFC520XDEVICEOPERATE_RUN 0
498#define FCERR_FMFC520XDEVICEOPERATE_IDLE 1
499#define FCERR_FMFC520XDEVICEDUPMAC 2
500#define FCERR_FMFC520XDEVICESELFTEST 3
501#define FCERR_FMFC520XDEVICESTANDBY 4
502#define FCERR_FMFC520XDEVICEMAJORFAULT 5
503#define FCERR_FMFC520XDEVICEMINORFAULT 6
504#define FCERR_FMFC520XDEVICEBUSSENSEFAIL 7
505
506#define FCERR_FMFC520XCANBUSON 0x01
507#define FCERR_FMFC520XCANBUSOFF 0x02
508#define FCERR_FMFC520XCANWARNINGLIMIT 0x04
509#define FCERR_FMFC520XCANOVERRUN 0x08
510
511
512/* DP-Slave-Errors */
513
514#define DPSLAVEERROR_NOERROR (FCERR_FMNOERROR + ERR_DPSLAVE)
515#define DPSLAVEERROR_STATIONDEACTIVATED (FCERR_FMDEACTIVATED + ERR_DPSLAVE)
516#define DPSLAVEERROR_STATIONNONEXISTENT (FCERR_FMNOANSWER + ERR_DPSLAVE)
517#define DPSLAVEERROR_MASTERLOCK (FCERR_FMMASTERLOCK + ERR_DPSLAVE)
518#define DPSLAVEERROR_INVALIDSLAVERESPONSE (FCERR_FMINVALIDRESPONSE + ERR_DPSLAVE)
519#define DPSLAVEERROR_PRMFAULT (FCERR_FMPRMFAULT + ERR_DPSLAVE)
520#define DPSLAVEERROR_NOTSUPPORTED (FCERR_FMFEATURENOTSUPPORTED + ERR_DPSLAVE)
521#define DPSLAVEERROR_CFGFAULT (FCERR_FMCFGFAULT + ERR_DPSLAVE)
522#define DPSLAVEERROR_STATIONNOTREADY (FCERR_FMSTATIONNOTREADY + ERR_DPSLAVE)
523#define DPSLAVEERROR_STATDIAG (FCERR_FMSTATDIAG + ERR_DPSLAVE)
524#define DPSLAVEERROR_DIAGOVERFLOW (FCERR_FMDIAGOVERFLOW + ERR_DPSLAVE)
525#define DPSLAVEERROR_PHYSICALFAULT (FCERR_FMPHYSICALFAULT + ERR_DPSLAVE)
526#define DPSLAVEERROR_TELEGRAMFAULT (FCERR_FMTELEGRAMFAULT + ERR_DPSLAVE)
527#define DPSLAVEERROR_NORESSOURCES (FCERR_FMNORESSOURCES + ERR_DPSLAVE)
528#define DPSLAVEERROR_SERVICENOTACTIVATED (FCERR_FMSERVICENOTACTIVATED + ERR_DPSLAVE)
529#define DPSLAVEERROR_UNEXPECTEDTELEGRAM (FCERR_FMUNEXPECTEDTELEGRAM + ERR_DPSLAVE)
530#define DPSLAVEERROR_STATIONREADY (FCERR_FMSTATIONREADY + ERR_DPSLAVE)
531#define DPSLAVEERROR_ADSSTARTUP (FCERR_FMADSSTARTUP + ERR_DPSLAVE)
532
533
534/* CAN-Node-Errors */
535
536#define CANNODEERROR_NOERROR (0 + ERR_CANSLAVE)
537#define CANNODEERROR_STATIONNONEXISTENT (1 + ERR_CANSLAVE)
538#define CANNODEERROR_PRMFAULT (4 + ERR_CANSLAVE)
539#define CANNODEERROR_CFGFAULT (6 + ERR_CANSLAVE)
540#define CANNODEERROR_DEACTIVATED (8 + ERR_CANSLAVE)
541#define CANNODEERROR_PREOPERATIONAL (12 + ERR_CANSLAVE)
542#define CANNODEERROR_NOT_OPERATIONAL (13 + ERR_CANSLAVE)
543
544
545/* IBS-Device-Errors */
546
547#define IBSDEVICEERROR_NOERROR (0 + ERR_IBSSLAVE)
548#define IBSDEVICEERROR_STATIONDEACTIVATED (1 + ERR_IBSSLAVE)
549#define IBSDEVICEERROR_STATIONNONEXISTENT (2 + ERR_IBSSLAVE)
550#define IBSDEVICEERROR_CFGFAULT (6 + ERR_IBSSLAVE)
551#define IBSDEVICEERROR_DIAGOVERFLOW (10 + ERR_IBSSLAVE)
552#define IBSDEVICEERROR_PHYSICALFAULT (11 + ERR_IBSSLAVE)
553
554
555/* PLC */
556#define PLCWRN_LOADINGBOOTPRJ ((0 + ERR_PLCERRS) | AMSERRCODEISWARNING)
557#define PLCWRN_LOADINGRETAINDATA ((1 + ERR_PLCERRS) | AMSERRCODEISWARNING)
558
559
560/* NC */
561#define ERR_NCR0MANERRS (ERR_NCERRS+0x0000)
562#define ERR_NCCHNERRS (ERR_NCERRS+0x0100)
563
564
565/* NC: R0-Manager Error Codes */
566#define NCERR_INTERNAL (0x0000 + ERR_NCR0MANERRS)
567#define NCERR_NOMEMORY (0x0001 + ERR_NCR0MANERRS)
568
569#define NCERR_UNKNOWNCHANNELID (0x0010 + ERR_NCR0MANERRS)
570#define NCERR_UNKNOWNGROUPID (0x0011 + ERR_NCR0MANERRS)
571#define NCERR_UNKNOWNAXISID (0x0012 + ERR_NCR0MANERRS)
572#define NCERR_UNKNOWNENCODERID (0x0013 + ERR_NCR0MANERRS)
573#define NCERR_UNKNOWNCONTROLLERID (0x0014 + ERR_NCR0MANERRS)
574#define NCERR_UNKNOWNDRIVEID (0x0015 + ERR_NCR0MANERRS)
575#define NCERR_UNKNOWNTABULARID (0x0016 + ERR_NCR0MANERRS)
576
577#define NCERR_UNKNOWNPLCTONCADDR (0x0020 + ERR_NCR0MANERRS)
578#define NCERR_UNKNOWNNCTOPLCADDR (0x0021 + ERR_NCR0MANERRS)
579#define NCERR_UNKNOWNENCINADDR (0x0022 + ERR_NCR0MANERRS)
580#define NCERR_UNKNOWNENCOUTADDR (0x0023 + ERR_NCR0MANERRS)
581#define NCERR_UNKNOWNDRIVEINADDR (0x0024 + ERR_NCR0MANERRS)
582#define NCERR_UNKNOWNDRIVEOUTADDR (0x0025 + ERR_NCR0MANERRS)
583
584#define NCERR_UNKNOWNDSLAVETYPE (0x0030 + ERR_NCR0MANERRS)
585#define NCERR_UNKNOWNAXISTYPE (0x0031 + ERR_NCR0MANERRS)
586#define NCERR_UNKNOWNCHNTYPE (0x0032 + ERR_NCR0MANERRS)
587
588#define NCERR_AXISINCOMPATIBLE (0x0040 + ERR_NCR0MANERRS)
589
590#define NCERR_CHANNELINCOMPLETE (0x0050 + ERR_NCR0MANERRS)
591#define NCERR_GROUPINCOMPLETE (0x0051 + ERR_NCR0MANERRS)
592#define NCERR_AXISINCOMPLETE (0x0052 + ERR_NCR0MANERRS)
593
594#define NCERR_CHANNELEXISTS (0x0060 + ERR_NCR0MANERRS)
595#define NCERR_GROUPEXISTS (0x0061 + ERR_NCR0MANERRS)
596#define NCERR_AXISEXISTS (0x0062 + ERR_NCR0MANERRS)
597#define NCERR_TABULAREXISTS (0x0063 + ERR_NCR0MANERRS)
598
599#define NCERR_WRONGCHANNELINDEX (0x0070 + ERR_NCR0MANERRS)
600#define NCERR_WRONGGROUPINDEX (0x0071 + ERR_NCR0MANERRS)
601
602
603/* Channel Error Codes */
604#define NCCHNERR_GROUPINDEX (0x0001 + ERR_NCCHNERRS)
605#define NCCHNERR_ADDR_GROUP (0x0002 + ERR_NCCHNERRS)
606#define NCCHNERR_NO_PLCINTERFACE (0x0003 + ERR_NCCHNERRS)
607#define NCCHNERR_ILLEGALMFUNCNR (0x0004 + ERR_NCCHNERRS)
608#define NCCHNERR_NOMEMORY (0x0005 + ERR_NCCHNERRS)
609#define NCCHNERR_ISBUSY (0x0006 + ERR_NCCHNERRS)
610#define NCCHNERR_NOTSUPPORTED (0x0007 + ERR_NCCHNERRS)
611#define NCCHNERR_ILLEGALSETTING (0x0008 + ERR_NCCHNERRS)
612
613#define NCCHNERR_NOFILE (0x0010 + ERR_NCCHNERRS)
614#define NCCHNERR_ITPSYNTAXLT (0x0011 + ERR_NCCHNERRS)
615#define NCCHNERR_ITPSYNTAXRT (0x0012 + ERR_NCCHNERRS)
616#define NCCHNERR_SUBNOTFOUND (0x0013 + ERR_NCCHNERRS)
617#define NCCHNERR_LOADBUFFERFULL (0x0014 + ERR_NCCHNERRS)
618#define NCCHNERR_INVALIDIDENTIFIER (0x0015 + ERR_NCCHNERRS)
619#define NCCHNERR_UNKNOWNIDENTIFIER (0x0016 + ERR_NCCHNERRS)
620#define NCCHNERR_SUBINCOMPLETE (0x0017 + ERR_NCCHNERRS)
621
622#define NCCHNERR_ZERODIVIDE (0x0020 + ERR_NCCHNERRS)
623#define NCCHNERR_BADCIRCLE (0x0021 + ERR_NCCHNERRS)
624#define NCCHNERR_INVALIDOPERATION (0x0022 + ERR_NCCHNERRS)
625
626#define NCCHNERR_CALLSTACKOVR (0x0030 + ERR_NCCHNERRS)
627#define NCCHNERR_CALLSTACKUDR (0x0031 + ERR_NCCHNERRS)
628#define NCCHNERR_CALCSTACKOVR (0x0032 + ERR_NCCHNERRS)
629#define NCCHNERR_CALCSTACKUDR (0x0033 + ERR_NCCHNERRS)
630
631#define NCCHNERR_REGINDEX (0x0040 + ERR_NCCHNERRS)
632#define NCCHNERR_GFUNCINDEX (0x0041 + ERR_NCCHNERRS)
633#define NCCHNERR_MFUNCINDEX (0x0042 + ERR_NCCHNERRS)
634#define NCCHNERR_EXTENDEDADDR (0x0043 + ERR_NCCHNERRS)
635#define NCCHNERR_INTERNALINDEXH (0x0044 + ERR_NCCHNERRS)
636#define NCCHNERR_MDBACCESSINDEX (0x0045 + ERR_NCCHNERRS)
637
638#define NCTRAFOERR_CANNOTCHANGE (0x0050 + ERR_NCCHNERRS)
639#define NCTRAFOERR_CANNOTCORRECT (0x0051 + ERR_NCCHNERRS)
640#define NCTRAFOERR_PLANE (0x0052 + ERR_NCCHNERRS)
641#define NCTRAFOERR_DPARAMINVALID (0x0053 + ERR_NCCHNERRS)
642#define NCTRAFOERR_TOOLRADIUSINV (0x0054 + ERR_NCCHNERRS)
643#define NCTRAFOERR_CHANGETOOLRAD (0x0055 + ERR_NCCHNERRS)
644#define NCTRAFOERR_CDOVERFLOW (0x0056 + ERR_NCCHNERRS)
645#define NCTRAFOERR_CDON (0x0057 + ERR_NCCHNERRS)
646#define NCTRAFOERR_CDCHECK (0x0058 + ERR_NCCHNERRS)
647#define NCTRAFOERR_CDUNEXPECTED (0x0059 + ERR_NCCHNERRS)
648#define NCTRAFOERR_CDNEGRADIUS (0x005A + ERR_NCCHNERRS)
649#define NCTRAFOERR_CDOCCURED (0x005B + ERR_NCCHNERRS)
650#define NCTRAFOERR_COOKEDTBLFULL (0x005C + ERR_NCCHNERRS)
651#define NCTRAFOERR_TFTBLFULL (0x005D + ERR_NCCHNERRS)
652#define NCTRAFOERR_EXECTFTBLFULL (0x005E + ERR_NCCHNERRS)
653#define NCTRAFOERR_EXECTFT (0x005F + ERR_NCCHNERRS)
654
655#define NCBACKUPERR_WRITEDATA (0x0060 + ERR_NCCHNERRS)
656#define NCBACKUPERR_TARGETENTRY (0x0061 + ERR_NCCHNERRS)
657
658
659#define MACHINEIDENTRYDONTCARE 0xFF
660#define AMS_NETIDLEN 23
661
665 typedef struct AmsNetId_
666{
667 uint8_t b[6];
668} AmsNetId;
669
671#define AmsNetId_Len (int)sizeof(AmsNetId)
672
673
677 typedef struct AmsAddr_
678{
679 AmsNetId netId;
680 uint16_t port;
681} AmsAddr;
682
683
687 typedef union ErrCodeUnion
688{
689 int32_t errCode;
690 int32_t hRcv;
691} ErrCodeUnion;
692
693
697 typedef union tUserUnion
698{
699 int32_t hUser;
700 struct
701 {
702 uint16_t fragmentNo;
703 uint16_t packetNo;
704 } a;
705} UserUnion;
706
707
711 typedef struct
712{
713 AmsAddr target;
714 AmsAddr sender;
715 uint16_t cmdId;
716 uint16_t stateFlags;
717 uint32_t cbData;
718 ErrCodeUnion anErrCodeUnion;
719 UserUnion aUserUnion;
720} AmsHead;
721
723#define AmsHead_Len (int)sizeof(AmsHead)
724
725
726/* State flags */
727
728#define AMSCMDSF_RESPONSE 0x0001
729#define AMSCMDSF_NORETURN 0x0002
730#define AMSCMDSF_ADSCMD 0x0004
731#define AMSCMDSF_SYSCMD 0x0008
732#define AMSCMDSF_HIGHPRIO 0x0010
733#define AMSCMDSF_TIMESTAMPADDED 0x0020
734#define AMSCMDSF_UDP 0x0040
735#define AMSCMDSF_INITCMD 0x0080
736#define AMSCMDSF_BROADCAST 0x8000
737
738
739/* AmsCmd */
740
744 typedef struct
745{
746 AmsHead head;
747} AmsCmd, *PAmsCmd;
748
749
750/* ADS */
751
752#define ADS_FIXEDNAMESIZE 16
753
754
755/* ADS Service Ids */
756#define ADSSRVID_INVALID 0x00
757#define ADSSRVID_READDEVICEINFO 0x01
758#define ADSSRVID_READ 0x02
759#define ADSSRVID_WRITE 0x03
760#define ADSSRVID_READSTATE 0x04
761#define ADSSRVID_WRITECTRL 0x05
762#define ADSSRVID_ADDDEVICENOTE 0x06
763#define ADSSRVID_DELDEVICENOTE 0x07
764#define ADSSRVID_DEVICENOTE 0x08
765#define ADSSRVID_READWRITE 0x09
766
767/* ADS reserved index groups */
768#define ADSIGRP_SYMTAB 0xF000
769#define ADSIGRP_SYMNAME 0xF001
770#define ADSIGRP_SYMVAL 0xF002
771
772#define ADSIGRP_SYM_HNDBYNAME 0xF003
773#define ADSIGRP_SYM_VALBYNAME 0xF004
774#define ADSIGRP_SYM_VALBYHND 0xF005
775#define ADSIGRP_SYM_RELEASEHND 0xF006
776#define ADSIGRP_SYM_INFOBYNAME 0xF007
777#define ADSIGRP_SYM_VERSION 0xF008
778#define ADSIGRP_SYM_INFOBYNAMEEX 0xF009
779
780#define ADSIGRP_SYM_DOWNLOAD 0xF00A
781#define ADSIGRP_SYM_UPLOAD 0xF00B
782#define ADSIGRP_SYM_UPLOADINFO 0xF00C
783#define ADSIGRP_SYM_DOWNLOAD2 0xF00D
784#define ADSIGRP_SYM_DT_UPLOAD 0xF00E
785#define ADSIGRP_SYM_UPLOADINFO2 0xF00F
786
787#define ADSIGRP_SYMNOTE 0xF010
788
789#define ADSIGRP_SYM_DT_INFOBYNAMEEX 0xF011
790#define ADSIGRP_SYM_ADDRBYHND 0xF012
791
792
793#define ADSIGRP_IOIMAGE_RWIB 0xF020
794#define ADSIGRP_IOIMAGE_RWIX 0xF021
795#define ADSIGRP_IOIMAGE_RISIZE 0xF025
796
797#define ADSIGRP_IOIMAGE_RWOB 0xF030
798#define ADSIGRP_IOIMAGE_RWOX 0xF031
799#define ADSIGRP_IOIMAGE_ROSIZE 0xF035
800#define ADSIGRP_IOIMAGE_CLEARI 0xF040
801#define ADSIGRP_IOIMAGE_CLEARO 0xF050
802
803#define ADSIGRP_IOIMAGE_RWIOB 0xF060
804
805#define ADSIGRP_IOIMAGE_CREATE 0xF068
806
807#define ADSIGRP_SUMUP_READ 0xF080
808
809#define ADSIGRP_SUMUP_WRITE 0xF081
810#define ADS_SUMUP_IGRP(p, i) (((uint32_t*)p)[(i)*3+0])
811#define ADS_SUMUP_IOFFS(p, i) (((uint32_t*)p)[(i)*3+1])
812#define ADS_SUMUP_LENGTH(p, i) (((uint32_t*)p)[(i)*3+2])
813
814#define ADSIGRP_DEVICE_DATA 0xF100
815 #define ADSIOFFS_DEVDATA_ADSSTATE 0x0000
816 #define ADSIOFFS_DEVDATA_DEVSTATE 0x0002
817 #define ADSIOFFS_DEVDATA_CONFIGID 0x0004
818 #define ADSIOFFS_DEVDATA_ADSVERSIONCHECK 0x0005
819
820#define ADSIGRP_TASK_DATA 0xF200
821/* ADSIGRP_TASK_DATA reserved until 0xF2FF*/
822
823#define ADSIGRP_CANOPEN_BEGIN 0xF300
824#define ADSIGRP_CANOPEN_SDO 0xF302
825#define ADSIGRP_CANOPEN_SDO_INFO_LIST 0xF3FC
826#define ADSIGRP_CANOPEN_SDO_INFO_OBJ 0xF3FD
827#define ADSIGRP_CANOPEN_SDO_INFO_ENTRY 0xF3FE
828#define ADSIGRP_CANOPEN_END 0xF3FF
829
830#define ADSIGRP_ECAT_FOE_BEGIN 0xF400
831#define ADSIGRP_ECAT_FOE_FOPENREAD 0xF401
832#define ADSIGRP_ECAT_FOE_FOPENWRITE 0xF402
833#define ADSIGRP_ECAT_FOE_FCLOSE 0xF403
834#define ADSIGRP_ECAT_FOE_FREAD 0xF404
835#define ADSIGRP_ECAT_FOE_FWRITE 0xF405
836#define ADSIGRP_ECAT_FOE_PROGRESSINFO 0xF406
837#define ADSIGRP_ECAT_FOE_END 0xF41F
838
839#define ADSIGRP_ECAT_SOE 0xF420
840 #define ADSIOFFS_ECAT_SOE_ELEMENT_MASK 0x00FF0000
841 #define ADSIOFFS_ECAT_SOE_DATASTATE 0x00010000
842 #define ADSIOFFS_ECAT_SOE_NAME 0x00020000
843 #define ADSIOFFS_ECAT_SOE_ATTRIBUTE 0x00040000
844 #define ADSIOFFS_ECAT_SOE_UNIT 0x00080000
845 #define ADSIOFFS_ECAT_SOE_MIN 0x00100000
846 #define ADSIOFFS_ECAT_SOE_MAX 0x00200000
847 #define ADSIOFFS_ECAT_SOE_VALUE 0x00400000
848 #define ADSIOFFS_ECAT_SOE_DEFAULT 0x00800000
849 #define ADSIOFFS_ECAT_SOE_DRIVENO_MASK 0x07000000
850 #define ADSIOFFS_ECAT_SOE_COMMAND 0x08000000
851
852#define ADSIGRP_ECAT_VOE 0xF430
853
854
858 typedef enum nAdsState
859{
860 ADSSTATE_INVALID = 0,
861 ADSSTATE_IDLE = 1,
862 ADSSTATE_RESET = 2,
863 ADSSTATE_INIT = 3,
864 ADSSTATE_START = 4,
865 ADSSTATE_RUN = 5,
866 ADSSTATE_STOP = 6,
867 ADSSTATE_SAVECFG = 7,
868 ADSSTATE_LOADCFG = 8,
869 ADSSTATE_POWERFAILURE = 9,
870 ADSSTATE_POWERGOOD = 10,
871 ADSSTATE_ERROR = 11,
872 ADSSTATE_SHUTDOWN = 12,
873 ADSSTATE_SUSPEND = 13,
874 ADSSTATE_RESUME = 14,
875 ADSSTATE_CONFIG = 15,
876 ADSSTATE_RECONFIG = 16,
877 ADSSTATE_MAXSTATES
878} ADSSTATE;
879
883 typedef enum nAdsTransMode
884{
885 ADSTRANS_NOTRANS = 0,
886 ADSTRANS_CLIENTCYCLE = 1,
887 ADSTRANS_CLIENTONCHA = 2,
888 ADSTRANS_SERVERCYCLE = 3,
889 ADSTRANS_SERVERONCHA = 4,
890 ADSTRANS_CLIENT1REQ = 10,
891 ADSTRANS_MAXMODES
892} ADSTRANSMODE;
893
894
895/* ADS error codes */
896#define ADSERR_NOERR 0x00
897
898#define ADSERR_DEVICE_ERROR (0x700)
899#define ADSERR_DEVICE_SRVNOTSUPP (0x701)
900#define ADSERR_DEVICE_INVALIDGRP (0x702)
901#define ADSERR_DEVICE_INVALIDOFFSET (0x703)
902#define ADSERR_DEVICE_INVALIDACCESS (0x704)
903#define ADSERR_DEVICE_INVALIDSIZE (0x705)
904#define ADSERR_DEVICE_INVALIDDATA (0x706)
905#define ADSERR_DEVICE_NOTREADY (0x707)
906#define ADSERR_DEVICE_BUSY (0x708)
907#define ADSERR_DEVICE_INVALIDCONTEXT (0x709)
908#define ADSERR_DEVICE_NOMEMORY (0x70A)
909#define ADSERR_DEVICE_INVALIDPARM (0x70B)
910#define ADSERR_DEVICE_NOTFOUND (0x70C)
911#define ADSERR_DEVICE_SYNTAX (0x70D)
912#define ADSERR_DEVICE_INCOMPATIBLE (0x70E)
913#define ADSERR_DEVICE_EXISTS (0x70F)
914#define ADSERR_DEVICE_SYMBOLNOTFOUND (0x710)
915#define ADSERR_DEVICE_SYMBOLVERSIONINVALID (0x711)
916#define ADSERR_DEVICE_INVALIDSTATE (0x712)
917#define ADSERR_DEVICE_TRANSMODENOTSUPP (0x713)
918#define ADSERR_DEVICE_NOTIFYHNDINVALID (0x714)
919#define ADSERR_DEVICE_CLIENTUNKNOWN (0x715)
920#define ADSERR_DEVICE_NOMOREHDLS (0x716)
921#define ADSERR_DEVICE_INVALIDWATCHSIZE (0x717)
922#define ADSERR_DEVICE_NOTINIT (0x718)
923#define ADSERR_DEVICE_TIMEOUT (0x719)
924#define ADSERR_DEVICE_NOINTERFACE (0x71A)
925#define ADSERR_DEVICE_INVALIDINTERFACE (0x71B)
926#define ADSERR_DEVICE_INVALIDCLSID (0x71C)
927#define ADSERR_DEVICE_INVALIDOBJID (0x71D)
928#define ADSERR_DEVICE_PENDING (0x71E)
929#define ADSERR_DEVICE_ABORTED (0x71F)
930#define ADSERR_DEVICE_WARNING (0x720)
931#define ADSERR_DEVICE_INVALIDARRAYIDX (0x721)
932#define ADSERR_DEVICE_SYMBOLNOTACTIVE (0x722)
933#define ADSERR_DEVICE_ACCESSDENIED (0x723)
934
935#define ADSERR_CLIENT_ERROR (0x740)
936#define ADSERR_CLIENT_INVALIDPARM (0x741)
937#define ADSERR_CLIENT_LISTEMPTY (0x742)
938#define ADSERR_CLIENT_VARUSED (0x743)
939#define ADSERR_CLIENT_DUPLINVOKEID (0x744)
940#define ADSERR_CLIENT_SYNCTIMEOUT (0x745)
941#define ADSERR_CLIENT_W32ERROR (0x746)
942#define ADSERR_CLIENT_TIMEOUTINVALID (0x747)
943#define ADSERR_CLIENT_PORTNOTOPEN (0x748)
944#define ADSERR_CLIENT_NOAMSADDR (0x749)
945#define ADSERR_CLIENT_SYNCINTERNAL (0x750)
946#define ADSERR_CLIENT_ADDHASH (0x751)
947#define ADSERR_CLIENT_REMOVEHASH (0x752)
948#define ADSERR_CLIENT_NOMORESYM (0x753)
949#define ADSERR_CLIENT_SYNCRESINVALID (0x754)
950#define ADSERR_CLIENT_SYNCPORTLOCKED (0x755)
951
952
953#define FACILITY_TC_ADS 0x1811
954#define FACILITY_TC_CNC 0x1821
955#define FACILITY_TC_IO 0x1831
956
957
958#if 0 /* Unused ?? */
959#define ADS_E_ERROR (0x98110000L + ADSERR_DEVICE_ERROR)
960#define ADS_E_SRVNOTSUPP (0x98110000L + ADSERR_DEVICE_SRVNOTSUPP)
961#define ADS_E_INVALIDGRP (0x98110000L + ADSERR_DEVICE_INVALIDGRP)
962#define ADS_E_INVALIDOFFSET (0x98110000L + ADSERR_DEVICE_INVALIDOFFSET)
963#define ADS_E_INVALIDACCESS (0x98110000L + ADSERR_DEVICE_INVALIDACCESS)
964#define ADS_E_INVALIDSIZE (0x98110000L + ADSERR_DEVICE_INVALIDSIZE)
965#define ADS_E_INVALIDDATA (0x98110000L + ADSERR_DEVICE_INVALIDDATA)
966#define ADS_E_NOTREADY (0x98110000L + ADSERR_DEVICE_NOTREADY)
967#define ADS_E_BUSY (0x98110000L + ADSERR_DEVICE_BUSY)
968#define ADS_E_INVALIDCONTEXT (0x98110000L + ADSERR_DEVICE_INVALIDCONTEXT)
969#define ADS_E_NOMEMORY (0x98110000L + ADSERR_DEVICE_NOMEMORY)
970#define ADS_E_INVALIDPARM (0x98110000L + ADSERR_DEVICE_INVALIDPARM)
971#define ADS_E_NOTFOUND (0x98110000L + ADSERR_DEVICE_NOTFOUND)
972#define ADS_E_SYNTAX (0x98110000L + ADSERR_DEVICE_SYNTAX)
973#define ADS_E_INCOMPATIBLE (0x98110000L + ADSERR_DEVICE_INCOMPATIBLE)
974#define ADS_E_EXISTS (0x98110000L + ADSERR_DEVICE_EXISTS)
975#define ADS_E_SYMBOLNOTFOUND (0x98110000L + ADSERR_DEVICE_SYMBOLNOTFOUND)
976#define ADS_E_SYMBOLVERSIONINVALID (0x98110000L + ADSERR_DEVICE_SYMBOLVERSIONINVALID)
977#define ADS_E_INVALIDSTATE (0x98110000L + ADSERR_DEVICE_INVALIDSTATE)
978#define ADS_E_TRANSMODENOTSUPP (0x98110000L + ADSERR_DEVICE_TRANSMODENOTSUPP)
979#define ADS_E_NOTIFYHNDINVALID (0x98110000L + ADSERR_DEVICE_NOTIFYHNDINVALID)
980#define ADS_E_CLIENTUNKNOWN (0x98110000L + ADSERR_DEVICE_CLIENTUNKNOWN)
981#define ADS_E_NOMOREHDLS (0x98110000L + ADSERR_DEVICE_NOMOREHDLS)
982#define ADS_E_INVALIDWATCHSIZE (0x98110000L + ADSERR_DEVICE_INVALIDWATCHSIZE)
983#define ADS_E_NOTINIT (0x98110000L + ADSERR_DEVICE_NOTINIT)
984#define ADS_E_TIMEOUT (0x98110000L + ADSERR_DEVICE_TIMEOUT)
985#define ADS_E_NOINTERFACE (0x98110000L + ADSERR_DEVICE_NOINTERFACE)
986#define ADS_E_INVALIDINTERFACE (0x98110000L + ADSERR_DEVICE_INVALIDINTERFACE)
987#define ADS_E_INVALIDCLSID (0x98110000L + ADSERR_DEVICE_INVALIDCLSID)
988#define ADS_E_INVALIDOBJID (0x98110000L + ADSERR_DEVICE_INVALIDOBJID)
989#define ADS_E_PENDING (0x98110000L + ADSERR_DEVICE_PENDING)
990#define ADS_E_ABORTED (0x98110000L + ADSERR_DEVICE_ABORTED)
991#define ADS_E_WARNING (0x98110000L + ADSERR_DEVICE_WARNING)
992#define ADS_E_INVALIDARRAYIDX (0x98110000L + ADSERR_DEVICE_INVALIDARRAYIDX)
993#define ADS_E_SYMBOLNOTACTIVE (0x98110000L + ADSERR_DEVICE_SYMBOLNOTACTIVE)
994#define ADS_E_ACCESSDENIED (0x98110000L + ADSERR_DEVICE_ACCESSDENIED)
995#endif
996
997#ifndef ANYSIZE_ARRAY
998 #define ANYSIZE_ARRAY 1
999#endif
1000
1001/* ADS AMS command */
1002/*typedef struct
1003{
1004 uint32_t hNotification;
1005 uint32_t cbSampleSize;
1006 uint8_t data[ANYSIZE_ARRAY];
1007} AdsNotificationSample, *PAdsNotificationSample;*/
1008#define AdsNotificationSample_Min_Len 4
1009
1013 typedef struct
1014{
1015 uint32_t invokeId;
1016} TAdsReadDeviceInfoReq;
1017
1018#define TAdsReadDeviceInfoReq_Len (int)sizeof(TAdsReadDeviceInfoReq)
1019
1020
1021/* TAdsWriteControlReq/TAdsWriteControlInd — struct definition omitted; use wire length macro instead.
1022 Fields: adsState (uint16), deviceState (uint16), cbLength (uint32), firstDataWord (uint16). */
1023#define TAdsWriteControlReq_Len 10
1024
1025
1029 typedef struct
1030{
1031 uint32_t invokeId;
1032} TAdsReadStateReq;
1033
1034#define TAdsReadStateReq_Len (int)sizeof(TAdsReadStateReq)
1035
1036
1040 typedef struct
1041{
1042 uint32_t indexGroup;
1043 uint32_t indexOffset;
1044 uint32_t cbLength;
1045} TAdsReadReq;
1046
1047#define TAdsReadReq_Len (int)sizeof(TAdsReadReq)
1048
1049
1050/* TAdsWriteReq — struct definition omitted; use wire length macro instead.
1051 Fields: indexGroup (uint32), indexOffset (uint32), cbLength (uint32), firstDataWord (uint16). */
1052#define TAdsWriteReq_Len 14
1053
1054
1055/* TAdsReadWriteReq — struct definition omitted; use wire length macro instead.
1056 Fields: indexGroup (uint32), indexOffset (uint32), cbReadLength (uint32), cbWriteLength (uint32), firstDataWord (uint16). */
1057#define TAdsReadWriteReq_Len 18
1058
1059
1063 typedef struct
1064{
1065 uint32_t cbLength;
1066 uint32_t nTransMode;
1067 uint32_t nMaxDelay;
1068 uint32_t nCycleTime;
1069 uint8_t nCmpMax[sizeof(double)];
1070 uint8_t nCmpMin[sizeof(double)];
1071} AdsNotificationAttrib;
1072
1073
1077 typedef struct
1078{
1079 uint32_t indexGroup;
1080 uint32_t indexOffset;
1081 AdsNotificationAttrib noteAttrib;
1082} TAdsAddDeviceNotificationReq;
1083
1084#define TAdsAddDeviceNotificationReq_Len (int)sizeof(TAdsAddDeviceNotificationReq)
1085
1086
1090 typedef struct
1091{
1092 uint32_t hNotification;
1093} TAdsDelDeviceNotificationReq;
1094
1095#define TAdsDelDeviceNotificationReq_Len (int)sizeof(TAdsDelDeviceNotificationReq)
1096
1097
1101 typedef struct
1102{
1103 uint32_t cbLength;
1104 uint32_t nStamps;
1105} TAdsDeviceNotificationReq;
1106
1107#define TAdsDeviceNotificationReq_Len (int)sizeof(TAdsDeviceNotificationReq)
1108
1109
1113 typedef struct
1114{
1115 uint32_t result;
1116} TAdsRes;
1117
1118#define TAdsRes_Len (int)sizeof(TAdsRes)
1119
1120
1124 typedef struct
1125{
1126 uint8_t version;
1127 uint8_t revision;
1128 uint16_t build;
1129} AdsVersion, *PAdsVersion;
1130
1131
1135 typedef struct
1136{
1137 uint32_t result;
1138 AdsVersion version;
1139 char sName[ADS_FIXEDNAMESIZE];
1140} TAdsReadDeviceInfoRes;
1141#define TAdsReadDeviceInfoRes_Len (int)sizeof(TAdsReadDeviceInfoRes)
1142
1146 typedef struct
1147{
1148 uint32_t result;
1149} TAdsWriteControlRes;
1150#define TAdsWriteControlRes_Len (int)sizeof(TAdsWriteControlRes)
1151
1155 typedef struct
1156{
1157 uint32_t result;
1158 uint16_t adsState;
1159 uint16_t deviceState;
1160} TAdsReadStateRes;
1161#define TAdsReadStateRes_Len (int)sizeof(TAdsReadStateRes)
1162
1166 typedef struct
1167{
1168 uint32_t result;
1169 uint32_t cbLength;
1170 uint16_t firstDataWord;
1171} TAdsReadRes;
1172
1173#define TAdsReadRes_Len (int)sizeof(TAdsReadRes)
1174
1178 typedef struct
1179{
1180 uint32_t result;
1181 uint32_t cbLength;
1182 uint16_t firstDataWord;
1183} TAdsReadWriteRes;
1184#define TAdsReadWriteRes_Len (int)sizeof(TAdsReadWriteRes)
1185
1189 typedef struct
1190{
1191 uint32_t result;
1192} TAdsWriteRes;
1193#define TAdsWriteRes_Len (int)sizeof(TAdsWriteRes)
1194
1198 typedef struct
1199{
1200 uint32_t result;
1201 uint32_t handle;
1202} TAdsAddDeviceNotificationRes;
1203#define TAdsAddDeviceNotificationRes_Len (int)sizeof(TAdsAddDeviceNotificationRes)
1204
1208 typedef struct
1209{
1210 uint32_t result;
1211} TAdsDelDeviceNotificationRes;
1212#define TAdsDelDeviceNotificationRes_Len (int)sizeof(TAdsDelDeviceNotificationRes)
1213
1214
1215/* structure for decoding the header -----------------------------------------*/
1216/*typedef struct
1217{
1218 uint16_t reserved;
1219 uint32_t cbLength;
1220} TcpAdsParserHDR;
1221 typedef TcpAdsParserHDR;*/
1222#define TcpAdsParserHDR_Len 6
1223
1224
1225#endif
1226
1227
1228/*
1229 * Editor modelines
1230 *
1231 * Local Variables:
1232 * c-basic-offset: 3
1233 * tab-width: 8
1234 * indent-tabs-mode: nil
1235 * End:
1236 *
1237 * ex: set shiftwidth=3 tabstop=8 expandtab:
1238 * :indentSize=3:tabSize=8:noTabs=true:
1239 */
AdsNotificationAttrib
Describes the notification attributes controlling how and when an ADS device notification fires.
Definition packet-ams.h:1064
AdsNotificationAttrib::nTransMode
uint32_t nTransMode
Definition packet-ams.h:1066
AdsNotificationAttrib::nCmpMin
uint8_t nCmpMin[sizeof(double)]
Definition packet-ams.h:1070
AdsNotificationAttrib::nCmpMax
uint8_t nCmpMax[sizeof(double)]
Definition packet-ams.h:1069
AdsNotificationAttrib::nCycleTime
uint32_t nCycleTime
Definition packet-ams.h:1068
AdsNotificationAttrib::cbLength
uint32_t cbLength
Definition packet-ams.h:1065
AdsNotificationAttrib::nMaxDelay
uint32_t nMaxDelay
Definition packet-ams.h:1067
AdsVersion
Represents an ADS device version number.
Definition packet-ams.h:1125
AdsVersion::version
uint8_t version
Definition packet-ams.h:1126
AdsVersion::build
uint16_t build
Definition packet-ams.h:1128
AdsVersion::revision
uint8_t revision
Definition packet-ams.h:1127
AmsAddr_
Full AMS address consisting of a Net ID and a port number.
Definition packet-ams.h:678
AmsAddr_::port
uint16_t port
Definition packet-ams.h:680
AmsAddr_::netId
AmsNetId netId
Definition packet-ams.h:679
AmsCmd
Represents a minimal AMS command message consisting solely of a standard AMS header.
Definition packet-ams.h:745
AmsCmd::head
AmsHead head
Definition packet-ams.h:746
AmsHead
AMS protocol header, common to all AMS commands.
Definition packet-ams.h:712
AmsHead::target
AmsAddr target
Definition packet-ams.h:713
AmsHead::cbData
uint32_t cbData
Definition packet-ams.h:717
AmsHead::sender
AmsAddr sender
Definition packet-ams.h:714
AmsHead::anErrCodeUnion
ErrCodeUnion anErrCodeUnion
Definition packet-ams.h:718
AmsHead::cmdId
uint16_t cmdId
Definition packet-ams.h:715
AmsHead::stateFlags
uint16_t stateFlags
Definition packet-ams.h:716
AmsHead::aUserUnion
UserUnion aUserUnion
Definition packet-ams.h:719
AmsNetId_
AMS (Automation Message Specification) network identifier (6-byte address).
Definition packet-ams.h:666
AmsNetId_::b
uint8_t b[6]
Definition packet-ams.h:667
TAdsAddDeviceNotificationReq
Request structure for the ADS AddDeviceNotification command.
Definition packet-ams.h:1078
TAdsAddDeviceNotificationReq::indexOffset
uint32_t indexOffset
Definition packet-ams.h:1080
TAdsAddDeviceNotificationReq::indexGroup
uint32_t indexGroup
Definition packet-ams.h:1079
TAdsAddDeviceNotificationReq::noteAttrib
AdsNotificationAttrib noteAttrib
Definition packet-ams.h:1081
TAdsAddDeviceNotificationRes
Response structure for the ADS AddDeviceNotification command.
Definition packet-ams.h:1199
TAdsAddDeviceNotificationRes::result
uint32_t result
Definition packet-ams.h:1200
TAdsAddDeviceNotificationRes::handle
uint32_t handle
Definition packet-ams.h:1201
TAdsDelDeviceNotificationReq
Request structure for the ADS DeleteDeviceNotification command.
Definition packet-ams.h:1091
TAdsDelDeviceNotificationReq::hNotification
uint32_t hNotification
Definition packet-ams.h:1092
TAdsDelDeviceNotificationRes
Response structure for the ADS DeleteDeviceNotification command.
Definition packet-ams.h:1209
TAdsDelDeviceNotificationRes::result
uint32_t result
Definition packet-ams.h:1210
TAdsDeviceNotificationReq
Header structure for an ADS DeviceNotification request, preceding one or more AdsStampHeader entries.
Definition packet-ams.h:1102
TAdsDeviceNotificationReq::nStamps
uint32_t nStamps
Definition packet-ams.h:1104
TAdsDeviceNotificationReq::cbLength
uint32_t cbLength
Definition packet-ams.h:1103
TAdsReadDeviceInfoReq
Request structure for the ADS ReadDeviceInfo command.
Definition packet-ams.h:1014
TAdsReadDeviceInfoReq::invokeId
uint32_t invokeId
Definition packet-ams.h:1015
TAdsReadDeviceInfoRes
Response structure for the ADS ReadDeviceInfo command.
Definition packet-ams.h:1136
TAdsReadDeviceInfoRes::sName
char sName[16]
Definition packet-ams.h:1139
TAdsReadDeviceInfoRes::result
uint32_t result
Definition packet-ams.h:1137
TAdsReadDeviceInfoRes::version
AdsVersion version
Definition packet-ams.h:1138
TAdsReadReq
Request structure for the ADS Read command.
Definition packet-ams.h:1041
TAdsReadReq::cbLength
uint32_t cbLength
Definition packet-ams.h:1044
TAdsReadReq::indexOffset
uint32_t indexOffset
Definition packet-ams.h:1043
TAdsReadReq::indexGroup
uint32_t indexGroup
Definition packet-ams.h:1042
TAdsReadRes
Response structure for the ADS Read command.
Definition packet-ams.h:1167
TAdsReadRes::firstDataWord
uint16_t firstDataWord
Definition packet-ams.h:1170
TAdsReadRes::result
uint32_t result
Definition packet-ams.h:1168
TAdsReadRes::cbLength
uint32_t cbLength
Definition packet-ams.h:1169
TAdsReadStateReq
Request structure for the ADS ReadState command.
Definition packet-ams.h:1030
TAdsReadStateReq::invokeId
uint32_t invokeId
Definition packet-ams.h:1031
TAdsReadStateRes
Response structure for the ADS ReadState command.
Definition packet-ams.h:1156
TAdsReadStateRes::adsState
uint16_t adsState
Definition packet-ams.h:1158
TAdsReadStateRes::deviceState
uint16_t deviceState
Definition packet-ams.h:1159
TAdsReadStateRes::result
uint32_t result
Definition packet-ams.h:1157
TAdsReadWriteRes
Response structure for the ADS ReadWrite command.
Definition packet-ams.h:1179
TAdsReadWriteRes::result
uint32_t result
Definition packet-ams.h:1180
TAdsReadWriteRes::cbLength
uint32_t cbLength
Definition packet-ams.h:1181
TAdsReadWriteRes::firstDataWord
uint16_t firstDataWord
Definition packet-ams.h:1182
TAdsRes
Generic ADS response structure carrying only a result code; used as the base for simple command respo...
Definition packet-ams.h:1114
TAdsRes::result
uint32_t result
Definition packet-ams.h:1115
TAdsWriteControlRes
Response structure for the ADS WriteControl command.
Definition packet-ams.h:1147
TAdsWriteControlRes::result
uint32_t result
Definition packet-ams.h:1148
TAdsWriteRes
Response structure for the ADS Write command.
Definition packet-ams.h:1190
TAdsWriteRes::result
uint32_t result
Definition packet-ams.h:1191
ErrCodeUnion
Union providing dual interpretation of an AMS error or receive code.
Definition packet-ams.h:688
ErrCodeUnion::hRcv
int32_t hRcv
Definition packet-ams.h:690
ErrCodeUnion::errCode
int32_t errCode
Definition packet-ams.h:689
tUserUnion
Union providing dual interpretation of the AMS user/invoke ID field.
Definition packet-ams.h:698
tUserUnion::a
struct tUserUnion::@126062044267366366363131377162122244200074225314 a
tUserUnion::fragmentNo
uint16_t fragmentNo
Definition packet-ams.h:702
tUserUnion::packetNo
uint16_t packetNo
Definition packet-ams.h:703
tUserUnion::hUser
int32_t hUser
Definition packet-ams.h:699