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

PSoC™ 4 Forum Discussions

mike_austin
Level 1
Level 1
First like received First reply posted First question asked

Hi,

In the past, I have used the method outlined in Application Note AN84858 to program CY8C4127 chips on custom boards, using the PSoc 5LP on CY8CKIT-042-BLE as a host processor.

However, I have now had to move to the larger memory version (the CY8C4128LQI-BL483) and I am having issues getting the HSSP process to work.

Looking at section 14.2.1 of document 001-84858_AN84858, it seems to suggest that its not possible to do an HSSP program as the 256KB for the PSOC4 chip is too much for the PSoC 5LP chip's memory, and it indicates some changes that are needed.

But its not clear if I have to make those changes myself to the B_HSSP_Pioneer files (Heximage.h, Heximage.c and Datafetch.c), or if there is an alternative version of the B_HSSP_Pioneer project that should be used for the 256kB chips.

Has anyone gone down this path and if so, can they explain what I need to do to get things to work?

Thanks and regards,

Mike

0 Likes
3 Replies
Ekta
Moderator
Moderator
Moderator
250 solutions authored 100 likes received 250 sign-ins

Hi @mike_austin 

You need not make the changes manually in the project.
The code example comes with a C# Application. The application has been developed in the Visual Studio development environment that parses the hex file and generates the .c and .h (HexImage.c, HexImage.h) files, which store only the programming data from the hex files. The programming data is stored as an array of constants in the HexImage.c and HexImage.h files.

Nine sets of parser applications are available in the folder ‘C# Application’. Choose the appropriate application
depending on the PSoC 4 family you are using. You can follow the steps provided in section 14 Appendix A: Hex File Parser Application of the Application note to generate the appropriate HexImage files for your device and use them in your project.

Let me know in case of any further clarifications.

Best Regards
Ekta

0 Likes

Hi Ekta,

I don't believe you are correct.

For PSoC 4xx8_BLE devices, the HexFile Parser program generates an array flashData_HexFile of size [1024][256], which effectively consumes all of the available flash memory in the PSoC 5LP device.  If you actually try and build the B_HSSP_Pioneer project in its default format, you will get an error.

If you read section 14.2.1 of the Application note, it mentions this, and outlines, but doesn't really explain very clearly, what needs to be done to the HexImage.c and HexImage.h files to fix this problem.

I did something slightly differently, in that I:

1.  Changed line 33 in HexImage.h to:
#define NUMBER_OF_FLASH_ROWS_HEX_FILE 768
This is because we can't fit all 256KB of the image file onto the PSoC 5LP chip, and still have room for the bootloader
2. In HexImage.c, comment out the last 256 rows in the FlashData_HexFile array. We've removed these from the array declaration, so need to also remove them from the initialisation as well.

What this means is that my Application code can't ever take up more than 75% of the available flash memory of my host IC.  But for me, at the moment at least, that's not a problem.

Making those changes enables me to bootload my custom board PSoC in the same way I have been doing with the PSOc_4xx7_BLE devices I had been using.

However, it seems to detect some sort of error when it does the verification at the end.  Haven't quite got to the bottom of what's going on here.  Seems to program my IC OK, but then detects something that isn't quite right, so doesn't flash the Status LED as I would expect.

Cheers,

Mike

0 Likes
Ekta
Moderator
Moderator
Moderator
250 solutions authored 100 likes received 250 sign-ins

Hello @mike_austin 

Is there any update on this from your end? Please let us know if you are still facing the issue.

Best Regards
Ekta

0 Likes