2011-08-09 09:31 AM
Anyone know how to use the @eeprom on the cosmic compiler
Does it suppot @eeprom vu32 EE_Total; The above passed the complier but if I try to use it I get errors I've also tried char and int but none seem to work. I want to read and write u23 u16 and u8 to EEPROM without having to worry about pointer etc there also seems to be a 4 byte structure.2011-08-09 12:34 PM
2011-08-11 05:45 AM
This is the error I get below but only whan I try to use it in function that is in another file that's included into main.c
So I assume I have to declare it as external somewhere? Running Linkerclnk -l''C:\Program Files\COSMIC\CXSTM8_32K\Lib'' -o Debug\light_sensor.sm8 -mDebug\light_sensor.map -eDebug\light_sensor.err -p Debug\light_sensor.lkf
errors reported in Debug\light_sensor.err
The command: ''clnk -l''C:\Program Files\COSMIC\CXSTM8_32K\Lib'' -o Debug\light_sensor.sm8 -mDebug\light_sensor.map -eDebug\light_sensor.err -p Debug\light_sensor.lkf '' has failed, the returned value is: 1
exit code=1.
2011-08-11 06:11 AM
2011-08-11 08:18 AM
FLASH_Unlock(FLASH_MEMTYPE_DATA);
ee_test = 0x12;
EE_totalPowerAcc = totalPowerAcc.l; FLASH_Lock(FLASH_MEMTYPE_DATA); totalPowerAcc.l is a structure for a u322011-08-12 07:45 AM
2011-08-31 10:28 AM
Look like the header is not seen
error clnk Debug\light_sensor.lkf:1 symbol _FLASH_CR2 not defined ((C:\Program Files\COSMIC\CXSTM8_32K\Lib\libm0.sm8)eepwrl.o (C:\Program Files\COSMIC\CXSTM8_32K\Lib\libm0.sm8)eeprom.o ) error clnk Debug\light_sensor.lkf:1 symbol _FLASH_NCR2 not defined ((C:\Program Files\COSMIC\CXSTM8_32K\Lib\libm0.sm8)eepwrl.o (C:\Program Files\COSMIC\CXSTM8_32K\Lib\libm0.sm8)eeprom.o ) error clnk Debug\light_sensor.lkf:1 symbol _FLASH_IAPSR not defined ((C:\Program Files\COSMIC\CXSTM8_32K\Lib\libm0.sm8)eepwrl.o (C:\Program Files\COSMIC\CXSTM8_32K\Lib\libm0.sm8)eeprom.o ) It seems that linker can not find the eeprom.i file also I'm having problems with the any of the lib file that use the assert_param() the compiler can't fimd the prototype and when I add it to my config file it give many ramdom error. My experiance of this compiler and the ST part has been very poor thinking of droping the Cosmic compiler for sure I don't think I'll be purchasing it./* Exported types ------------------------------------------------------------*/
/* Exported constants --------------------------------------------------------*/ /* Uncomment the line below to expanse the ''assert_param'' macro in the Standard Peripheral Library drivers code */ #define USE_FULL_ASSERT (1)/* Exported macro ------------------------------------------------------------*/
#ifdef USE_FULL_ASSERT/**
* @brief The assert_param macro is used for function's parameters check. * @param expr: If expr is false, it calls assert_failed function * which reports the name of the source file and the source * line number of the call that failed. * If expr is true, it returns no value. * @retval : None */ #define assert_param(expr) ((expr) ? (void)0 : assert_failed((uint8_t *)__FILE__, __LINE__)) /* Exported functions ------------------------------------------------------- */ void assert_failed(uint8_t* file, uint32_t line); #else #define assert_param(expr) ((void)0) #endif /* USE_FULL_ASSERT */2011-09-06 10:50 AM
Stll not working anyone any ideas why the linker doesn't see the eeprom.i file?
2012-09-03 03:10 AM
Hi,
I am having the same problem. Has this issue been resolved?