S-Flash User area APIs are not created ?

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

cross mob
shrac_2642471
Level 4
Level 4
5 likes given First like received First like given

Hi Team

I am using Cypress PSoC 4200 for CY8C4248LQI-BL483 for my project. I see that for some reason, the PSoC is not generating the following #defines

#if (CY_SFLASH_XTRA_ROWS)

    #define CY_SFLASH_USERBASE  (CYREG_SFLASH_MACRO_0_FREE_SFLASH0) /**< The base pointer of the user SFlash memory. */

    #define CY_SFLASH_SIZE      (CYDEV_SFLASH_SIZE)                 /**< The size of the SFlash memory. */

    #define CY_SFLASH_SIZEOF_USERROW        (CYDEV_FLS_ROW_SIZE)    /**< The size of the SFlash row. */

    #define CY_SFLASH_NUMBER_USERROWS       (4u)                    /**< The number of SFlash row. */

#endif /* (CY_SFLASH_XTRA_ROWS) */

How do I generate it? Is there a setting which needs to be enabled in the PSoC creator ?

0 Likes
1 Solution

GeonaM_26
I did some more investigation and figured out what the problem was. And once I figured out what the problem was, it was easy to fix this.

In the figure below you can see CyFlash.h which says that the component version is 5.20. I also had a look at my other projects where I see the component version was 5.40. Which means there is a new component which had to be used for S-Flash

pastedImage_0.png

So this is what I did,

pastedImage_1.png

In the cy_boot I updated the module to 5.40 and as soon as I did that all the APIs which were missing became available. By the way thanks so much for creating a cypress ticket for me to officially debug my environment. I don't think that would be needed anymore. I guess the problem was more because of the component version.

Thanks for a wonderful support.!

Regards,

Shrey

View solution in original post

0 Likes
6 Replies
GeonaP_26
Moderator
Moderator
Moderator
250 solutions authored 100 solutions authored 50 solutions authored

Please right click on the project > 'Device Selector' and change the device to CY8C4248LQI-BL483. Later 'Clean and Build' the project.

pastedImage_0.png

0 Likes

Hi GeonaM_26
Well I see what the problem is. Even If I select the device as CY8C4248LQI-BL483, PSoC Creator automatically selects the device as BL493, which is super weird. That is why the correct MACROs aren't being selected.
See in my project it is correctly selected as follows

tempsnip.png
Now lets see what the code generation is doing. I see that all Cortex M0 files which are generated is is 493

pastedImage_1.png
You see it is automatically selecting 493 and obviously it is not generating the right data. Do you know why it happens ?

Regards,
Shrey

0 Likes
  • ARM_GCC_493 stands for the toolchain used for building the project. I assume you are using PSoC Creator 4.0 or 3.3 which has the GCC ARM Embedded toolchain GCC 4.9-2015-q1 by default. You can confirm the build settings by, right click on the project > Build Settings.

  • Please confirm whether the Skip Code Generation is set as False. Skipping code generation effectively locks the design such that any changes to the schematic, design-wide resources, and so on are not incorporated into the build output. Please set it as 'False' and 'Clean and Build' the project.

pastedImage_1.png

0 Likes

Hi GeonaM_26
I have the same configuration as you have mentioned, yet the APIs aren't being generated. Since I am part of a research team here I cannot really zip the code and send it across.

However I can give you a background.

So the connectivity team at my office has a proprietary project using Cypress CY8C4248LQI-BL493. My project which uses the connectivity code has to migrate to code base of 493 but use CY8C4248LQI-BL483. So I am using their project and porting my application code on it. However I changed the device to BL483. But when I do this, the code for 483 S-Flash is not being generated. I have cleaned and deleted all the files and tried as well still didn't help.

When I create a fresh project, then it is creating the correct file. However, that's not really that helpful for me now.

Regards,

Shrey

0 Likes

GeonaM_26
I did some more investigation and figured out what the problem was. And once I figured out what the problem was, it was easy to fix this.

In the figure below you can see CyFlash.h which says that the component version is 5.20. I also had a look at my other projects where I see the component version was 5.40. Which means there is a new component which had to be used for S-Flash

pastedImage_0.png

So this is what I did,

pastedImage_1.png

In the cy_boot I updated the module to 5.40 and as soon as I did that all the APIs which were missing became available. By the way thanks so much for creating a cypress ticket for me to officially debug my environment. I don't think that would be needed anymore. I guess the problem was more because of the component version.

Thanks for a wonderful support.!

Regards,

Shrey

0 Likes
mato_4121196
Level 1
Level 1

Here you will know more about the complete process of using popups and you can use it if you required.

0 Likes