PSOC 63 Emulated EEPROM problem ---No use Emulated

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
jali_3846906
Level 3
Level 3
10 replies posted 5 replies posted 10 questions asked

      Hi All.

      I ues PSOC 63 Emulated EEPROM with no use Emulated and set the startAddress = 0x100C0000.when i Init this componment,system will reset.Can you give me some suggestion?Thank you.

1.png

0 Likes
1 Solution
lock attach
Attachments are accessible only for community members.

Theoretically you can allocate user flash as emulated eeprom with custom size, but please note there is limitation of size and it's more likely there is no ehough free flash space for your use.

Your application code occupies certain size of flash, therefore you can only use the rest part.

As for the issue you are facing to, please try to reduce the flash size allocated for emulated eeprom as much as possible and put the start address of section .my_emulated_eeprom near the upper limit (max address) of the flash allocated for the target core to check if it can work under disirable conditions. If it works, then increase the allocated flash size and down the section start address to explore the max free flash size.

A smiple "No Use Emulated EEPROM" demo based on ce195313​ is attached for your reference. Do not clean the project as a fresh build will override what I modified.

View solution in original post

0 Likes
6 Replies
ShipingW_81
Moderator
Moderator
Moderator
500 replies posted 250 solutions authored 250 replies posted

It looks not clear enough about your issue just from the description. Can you show more details?

Which is the "startAddress"? possible to attach your project?

0 Likes

the startAddress is part of config.thankyou.

2.png

and why 0x100C0000?Bacause is this image:

3.png

0 Likes

Emulated EEPROM component for a data size of 160256 bytes consumes 320512 bytes. Please refer to the Emulated EEPROM component configuration window for actual EEPROM size.

pastedImage_0.png

PSoC 63 application flash range is from 0x1000 0000 to 0x100F FFFF. If you start the Emulated EEPROM component at 0x100C 0000, the available application flash will not be enough (0x100F FFFF - 0x100C 0000 = 0x3 FFFF < 320512). So, please start the Emulated EEPROM data storage from 0x100B 1C00 or lesser.

Follow these steps while placing the component in Application flash (configure Use Emulated EEPROM as No). This will throw a build error incase of resource limitation.

  • Allocate the memory for Emulated EEPROM storage in memory section .my_emulated_eeprom

/* EEPROM storage in work flash, this is defined in Em_EEPROM.c*/

const uint8 Em_EEPROM_em_EepromStorage[Em_EEPROM_PHYSICAL_SIZE] CY_SECTION(".my_emulated_eeprom") __ALIGNED(CY_FLASH_SIZEOF_ROW) = {0u};

  • Add following lines of code after etext = . ; in the linker file corresponding to the core using Emulated EEPROM component. Suppose, the component is used in CM4, add following lines in cy8c6xx7_cm4_dual.ld line.

‭    EM_EEPROM_START_ADDRESS = 0x100B1C00‬;

    .my_emulated_eeprom EM_EEPROM_START_ADDRESS :

    {

        KEEP(*(.my_emulated_eeprom))

    } > flash

pastedImage_2.png

0 Likes

     Thank you.But when I modify the code according to your method, download the program to the board. Found that the entire program can not run.

0 Likes
lock attach
Attachments are accessible only for community members.

Theoretically you can allocate user flash as emulated eeprom with custom size, but please note there is limitation of size and it's more likely there is no ehough free flash space for your use.

Your application code occupies certain size of flash, therefore you can only use the rest part.

As for the issue you are facing to, please try to reduce the flash size allocated for emulated eeprom as much as possible and put the start address of section .my_emulated_eeprom near the upper limit (max address) of the flash allocated for the target core to check if it can work under disirable conditions. If it works, then increase the allocated flash size and down the section start address to explore the max free flash size.

A smiple "No Use Emulated EEPROM" demo based on ce195313​ is attached for your reference. Do not clean the project as a fresh build will override what I modified.

0 Likes

     Right,Thank you

0 Likes