Page 1 of 1

Flowcode v9 does not create an .eep file for "Arduino UNO R3 SMD"

Posted: Thu Oct 14, 2021 12:36 pm
by OlegKRS
In my project I use the EEPROM component . I want to create a file .eep with data to fill in the EEPROM AVR. To do this, I wrote such a line for the compiler in the avrb.bat file:
"%~dp0..\bin\avr-objcopy" -O ihex -j .eeprom --set-section-flags .eeprom=alloc,load --change-section-lma .eeprom=0 --no-change-warnings %1 %4.
The compiler creates a file .eep, but there is no data in it that is written in the property of the EEPROM component "InitialValues".
I assume that the compiler does not see these lines:
#ifdef MX_CAL_AVR
char EEMEM NonVolatileData[] = {0,1,0x2,0x03,'A','b','H','e','l','l','o'};
#endif
which are written in the .c file of the project.
What should I do to create an .eep file?

The chip in the project is selected: "Arduino UNO R3 SMD"

Re: Flowcode v9 does not create an .eep file for "Arduino UNO R3 SMD"

Posted: Thu Oct 14, 2021 2:47 pm
by Steve-Matrix
I'm unfamiliar with generating a .EEP file, but I think your batch file line looks wrong and it should maybe be something like the following:

Code: Select all

"%~dp0..\bin\avr-objcopy" -O ihex -R .eeprom  %1 %2
"%~dp0..\bin\avr-objcopy" -j .eeprom --set-section-flags=.eeprom="alloc,load" --change-section-lma .eeprom=0 -O ihex %1 "%~dp2%~n2.eep"

Re: Flowcode v9 does not create an .eep file for "Arduino UNO R3 SMD"

Posted: Thu Oct 14, 2021 5:40 pm
by OlegKRS
Hello,

Thanks for the answer Steve. But I figured out how to solve my problem.
It is necessary to write in Project Options -> Supplemental Code:
char EEMEM NonVolatileData[] = {0,1,0x2,0x03,'A','b','H','e','l','l','o'};.
In this case , the file .an eep is being created.