Open trojanobelix opened 1 year ago
If there are two (different) objects with the same name only one will be created in sCO_OD_RAM Without any error/warning.
Alternitives:
@CANopenNode : What do you think is best?
`/2002 /
#define OD_2002_0_stringTest_maxSubIndex 0 #define OD_2002_1_stringTest_subObject1 1 #define OD_2002_2_stringTest_subObject1 2 #define OD_2002_3_stringTest_subObject1 3 #define OD_2002_4_stringTest_subObject1 4 #define OD_2002_5_stringTest_subObject1 5 #define OD_2002_6_stringTest_subObject1 6 #define OD_2002_7_stringTest_subObject1 7
/ STRUCTURES FOR VARIABLES IN DIFFERENT MEMORY LOCATIONS /
/* Structure for RAM variables ****/ struct sCO_OD_RAM{ UNSIGNED32 FirstWord;
/2000 / VISIBLE_STRING stringTest[2]; /2001 / UNSIGNED32 newObject[5];
UNSIGNED32 LastWord;
};`
It seems it only happens in CANOPENNODE_LEGACY exporter. V4 exporter adds index to the variable name, so there is no problem. Maybe just add error message to LEGACY exporter.
If there are two (different) objects with the same name only one will be created in sCO_OD_RAM Without any error/warning.
Alternitives:
@CANopenNode : What do you think is best?
`/2002 /
define OD_2002_stringTest 0x2002
/ STRUCTURES FOR VARIABLES IN DIFFERENT MEMORY LOCATIONS /
define CO_OD_FIRST_LAST_WORD 0x55 //Any value from 0x01 to 0xFE. If changed, EEPROM will be reinitialized.
/* Structure for RAM variables ****/ struct sCO_OD_RAM{ UNSIGNED32 FirstWord;
/2000 / VISIBLE_STRING stringTest[2]; /2001 / UNSIGNED32 newObject[5];
};`