Lely core libraries
2.2.5
sdo.h
Go to the documentation of this file.
1
24
#ifndef LELY_CO_INTERN_SDO_H_
25
#define LELY_CO_INTERN_SDO_H_
26
27
#include "
co.h
"
28
#include <
lely/co/sdo.h
>
29
31
#define CO_SDO_CS_MASK 0xe0
32
34
#define CO_SDO_CS_ABORT 0x80
35
37
#define CO_SDO_SCS_DN_INI_RES 0x60
38
40
#define CO_SDO_SCS_DN_SEG_RES 0x20
41
43
#define CO_SDO_SCS_UP_INI_RES 0x40
44
46
#define CO_SDO_SCS_UP_SEG_RES 0x00
47
49
#define CO_SDO_SCS_BLK_DN_RES 0xa0
50
52
#define CO_SDO_SCS_BLK_UP_RES 0xc0
53
55
#define CO_SDO_CCS_DN_INI_REQ 0x20
56
58
#define CO_SDO_CCS_DN_SEG_REQ 0x00
59
61
#define CO_SDO_CCS_UP_INI_REQ 0x40
62
64
#define CO_SDO_CCS_UP_SEG_REQ 0x60
65
67
#define CO_SDO_CCS_BLK_DN_REQ 0xc0
68
70
#define CO_SDO_CCS_BLK_UP_REQ 0xa0
71
73
#define CO_SDO_SC_MASK 0x03
74
76
#define CO_SDO_SC_INI_BLK 0x00
77
79
#define CO_SDO_SC_END_BLK 0x01
80
82
#define CO_SDO_SC_BLK_RES 0x02
83
85
#define CO_SDO_SC_START_UP 0x03
86
91
#define CO_SDO_INI_SIZE_MASK 0x0f
92
94
#define CO_SDO_INI_SIZE_IND 0x01
95
97
#define CO_SDO_INI_SIZE_EXP 0x02
98
105
#define CO_SDO_INI_SIZE_EXP_GET(cs) (4 - (((cs)&CO_SDO_INI_SIZE_MASK) >> 2))
106
113
#define CO_SDO_INI_SIZE_EXP_SET(n) \
114
((((4 - (n)) << 2) | 0x03) & CO_SDO_INI_SIZE_MASK)
115
117
#define CO_SDO_SEG_TOGGLE 0x10
118
123
#define CO_SDO_SEG_SIZE_MASK 0x0e
124
131
#define CO_SDO_SEG_SIZE_GET(cs) (7 - (((cs)&CO_SDO_SEG_SIZE_MASK) >> 1))
132
139
#define CO_SDO_SEG_SIZE_SET(n) (((7 - (n)) << 1) & CO_SDO_SEG_SIZE_MASK)
140
142
#define CO_SDO_SEG_LAST 0x01
143
145
#define CO_SDO_BLK_SIZE_IND 0x02
146
148
#define CO_SDO_BLK_CRC 0x04
149
151
#define CO_SDO_SEQ_LAST 0x80
152
157
#define CO_SDO_BLK_SIZE_MASK 0x1c
158
165
#define CO_SDO_BLK_SIZE_GET(cs) (7 - (((cs)&CO_SDO_BLK_SIZE_MASK) >> 2))
166
173
#define CO_SDO_BLK_SIZE_SET(n) (((7 - (n)) << 2) & CO_SDO_BLK_SIZE_MASK)
174
176
#define CO_SDO_MAX_SEQNO 127
177
178
#endif
// !LELY_CO_INTERN_SDO_H_
sdo.h
This header file is part of the CANopen library; it contains the Service Data Object (SDO) declaratio...
co.h
This is the internal header file of the CANopen library.
src
co
sdo.h
Generated by
1.9.1