29#define CO_CONFIG_LSS (CO_CONFIG_LSS_SLAVE | CO_CONFIG_GLOBAL_FLAG_CALLBACK_PRE)
32#if (((CO_CONFIG_LSS) & (CO_CONFIG_LSS_SLAVE | CO_CONFIG_LSS_MASTER)) != 0) || defined CO_DOXYGEN
76#define CO_LSS_SWITCH_STATE_GLOBAL 0x04U
77#define CO_LSS_SWITCH_STATE_SEL_VENDOR 0x40U
78#define CO_LSS_SWITCH_STATE_SEL_PRODUCT 0x41U
79#define CO_LSS_SWITCH_STATE_SEL_REV 0x42U
80#define CO_LSS_SWITCH_STATE_SEL_SERIAL 0x43U
81#define CO_LSS_SWITCH_STATE_SEL 0x44U
82#define CO_LSS_CFG_NODE_ID 0x11U
83#define CO_LSS_CFG_BIT_TIMING 0x13U
84#define CO_LSS_CFG_ACTIVATE_BIT_TIMING 0x15U
85#define CO_LSS_CFG_STORE 0x17U
86#define CO_LSS_IDENT_SLAVE 0x4FU
87#define CO_LSS_IDENT_FASTSCAN 0x51U
88#define CO_LSS_INQUIRE_VENDOR 0x5AU
89#define CO_LSS_INQUIRE_PRODUCT 0x5BU
90#define CO_LSS_INQUIRE_REV 0x5CU
91#define CO_LSS_INQUIRE_SERIAL 0x5DU
92#define CO_LSS_INQUIRE_NODE_ID 0x5EU
100#define CO_LSS_CFG_NODE_ID_OK 0x00U
101#define CO_LSS_CFG_NODE_ID_OUT_OF_RANGE 0x01U
102#define CO_LSS_CFG_NODE_ID_MANUFACTURER 0xFFU
110#define CO_LSS_CFG_BIT_TIMING_OK 0x00U
111#define CO_LSS_CFG_BIT_TIMING_OUT_OF_RANGE 0x01U
112#define CO_LSS_CFG_BIT_TIMING_MANUFACTURER 0xFFU
120#define CO_LSS_CFG_STORE_OK 0x00U
121#define CO_LSS_CFG_STORE_NOT_SUPPORTED 0x01U
122#define CO_LSS_CFG_STORE_FAILED 0x02U
123#define CO_LSS_CFG_STORE_MANUFACTURER 0xFFU
131#define CO_LSS_FASTSCAN_BIT0 0x00U
133#define CO_LSS_FASTSCAN_BIT31 0x1FU
134#define CO_LSS_FASTSCAN_CONFIRM 0x80U
141#define CO_LSS_FASTSCAN_VENDOR_ID 0x00U
142#define CO_LSS_FASTSCAN_PRODUCT 0x01U
143#define CO_LSS_FASTSCAN_REV 0x02U
144#define CO_LSS_FASTSCAN_SERIAL 0x03U
171#define CO_LSS_STATE_WAITING 0x00U
172#define CO_LSS_STATE_CONFIGURATION 0x01U
180#define CO_LSS_BIT_TIMING_1000 0U
181#define CO_LSS_BIT_TIMING_800 1U
182#define CO_LSS_BIT_TIMING_500 2U
183#define CO_LSS_BIT_TIMING_250 3U
184#define CO_LSS_BIT_TIMING_125 4U
186#define CO_LSS_BIT_TIMING_50 6U
187#define CO_LSS_BIT_TIMING_20 7U
188#define CO_LSS_BIT_TIMING_10 8U
189#define CO_LSS_BIT_TIMING_AUTO 9U
200#define CO_LSS_NODE_ID_ASSIGNMENT 0xFFU
205#define CO_LSS_NODE_ID_VALID(nid) (((nid >= 1U) && (nid <= 0x7FU)) || (nid == CO_LSS_NODE_ID_ASSIGNMENT))
210#define CO_LSS_ADDRESS_EQUAL( a1, a2) \
211 ((a1.identity.productCode == a2.identity.productCode) \
212 && (a1.identity.revisionNumber == a2.identity.revisionNumber) \
213 && (a1.identity.serialNumber == a2.identity.serialNumber) && (a1.identity.vendorID == a2.identity.vendorID))
Interface between CAN hardware and CANopenNode.
static const uint16_t CO_LSS_bitTimingTableLookup[]
Lookup table for conversion between bit timing table and numerical bit rate.
Definition CO_LSS.h:195
unsigned int uint16_t
UNSIGNED16 in CANopen (0006h), 16-bit unsigned integer.
Definition CO_driver.h:132
unsigned long int uint32_t
UNSIGNED32 in CANopen (0007h), 32-bit unsigned integer.
Definition CO_driver.h:133
The LSS address is a 128 bit number, uniquely identifying each node.
Definition CO_LSS.h:150