NNP STM Generic Remote Module git-main
Loading...
Searching...
No Matches
objacces.h
Go to the documentation of this file.
1
8#ifndef INC_OBJACCES_H_
9#define INC_OBJACCES_H_
10
11#include <applicfg.h>
12
13typedef UNS32 (*valueRangeTest_t)(UNS8 typeValue, void *Value);
14typedef void (* storeODSubIndex_t)(CO_Data* d, UNS16 wIndex, UNS8 bSubindex);
15void _storeODSubIndex (CO_Data* d, UNS16 wIndex, UNS8 bSubindex);
16
17UNS8 accessDictionaryError(UNS16 index, UNS8 subIndex,
18 UNS32 sizeDataDict, UNS32 sizeDataGiven, UNS32 code);
19
20
21
23 UNS16 wIndex,
24 UNS8 bSubindex,
25 void * pDestData,
26 UNS32 * pExpectedSize,
27 UNS8 * pDataType,
28 UNS8 checkAccess,
29 UNS8 endianize);
30
31
32#define getODentry( OD, wIndex, bSubindex, pDestData, pExpectedSize, \
33 pDataType, checkAccess) \
34 _getODentry( OD, wIndex, bSubindex, pDestData, pExpectedSize, \
35 pDataType, checkAccess, 1)
36
37#define readLocalDict( OD, wIndex, bSubindex, pDestData, pExpectedSize, \
38 pDataType, checkAccess) \
39 _getODentry( OD, wIndex, bSubindex, pDestData, pExpectedSize, \
40 pDataType, checkAccess, 0)
41
42
44 UNS16 wIndex,
45 UNS8 bSubindex,
46 void * pSourceData,
47 UNS32 * pExpectedSize,
48 UNS8 checkAccess,
49 UNS8 endianize);
50
51
52#define setODentry( d, wIndex, bSubindex, pSourceData, pExpectedSize, \
53 checkAccess) \
54 _setODentry( d, wIndex, bSubindex, pSourceData, pExpectedSize, \
55 checkAccess, 1)
56
57#define writeLocalDict( d, wIndex, bSubindex, pSourceData, pExpectedSize, checkAccess) \
58 _setODentry( d, wIndex, bSubindex, pSourceData, pExpectedSize, checkAccess, 0)
59
60
61
62
63 const indextable * scanIndexOD (CO_Data* d, UNS16 wIndex, UNS32 *errorCode, ODCallback_t **Callback);
64
65UNS32 RegisterSetODentryCallBack(CO_Data* d, UNS16 wIndex, UNS8 bSubindex, ODCallback_t Callback);
66
67#endif /* INC_OBJACCES_H_ */
#define UNS8
Unsigned int8 representation in CANFest.
Definition applicfg.h:25
#define UNS16
Unsigned int16 representation in CANFest.
Definition applicfg.h:26
#define UNS32
Unsigned int32 representation in CANFest.
Definition applicfg.h:27
void _storeODSubIndex(CO_Data *d, UNS16 wIndex, UNS8 bSubindex)
<BRIEF>
Definition objacces.c:376
UNS32 RegisterSetODentryCallBack(CO_Data *d, UNS16 wIndex, UNS8 bSubindex, ODCallback_t Callback)
<BRIEF>
Definition objacces.c:357
#define accessDictionaryError(index, subIndex, sizeDataDict, sizeDataGiven, code)
Print MSG_WAR (s) if error to the access to the object dictionary occurs.
Definition objacces.c:68
const indextable * scanIndexOD(CO_Data *d, UNS16 wIndex, UNS32 *errorCode, ODCallback_t **Callback)
Scan the index of object dictionary. Used only by setODentry and getODentry.
Definition objacces.c:343
UNS32 _setODentry(CO_Data *d, UNS16 wIndex, UNS8 bSubindex, void *pSourceData, UNS32 *pExpectedSize, UNS8 checkAccess, UNS8 endianize)
By this function you can write an entry into the object dictionary.
Definition objacces.c:235
UNS32 _getODentry(CO_Data *d, UNS16 wIndex, UNS8 bSubindex, void *pDestData, UNS32 *pExpectedSize, UNS8 *pDataType, UNS8 checkAccess, UNS8 endianize)
_getODentry() Reads an entry from the object dictionary.
Definition objacces.c:111
This structure contains all necessary informations to define a CANOpen node.
Definition data.h:44