cancel
Showing results for 
Search instead for 
Did you mean: 

Fail to program External SPI Flash - STM32F429 and W25Q64

hbZhao
Associate III

Hello all,

I am implementing an external loader for STM32F429 and W25Q64. The STM32CubeIDE Version is 1.15.1 and STM32CubeProgrammer is 2.16.0.

I success programming a 64k bin file with the external loader while failed to program a bigger size file (150K). The attachments are the logs of STM32CubeProgrammer .

The Dev_inf is as below:

 

 

struct StorageInfo const StorageInfo = {
    "W25Q64_STM32F429BIT6_SPI", 
    SPI_FLASH,                  
    0x90000000,                 
    0x00800000,          
    0x0100,           //256b
    0xFF,                       

    // Specify Size and Address of Sectors (view example below)
    0x0800,  
    0x1000,           //4kB
    0x00000000,
    0x00000000,
};

 

 

 

May I have any suggestions on this case? Thanks.

1 ACCEPTED SOLUTION

Accepted Solutions

The secondary call to Init() fails.

The first 74KB takes 90970 ms, ie 1.5 minutes, which seems incredibly slow.

You need to write 256-byte pages, but this should be pretty efficient unless you add a lot of delays.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..

View solution in original post

3 REPLIES 3

>>May I have any suggestions on this case?

Thoroughly test your code from applications space.

Instrument your code via an available UART so you can understand how the STM32 Cube Programmer is interacting with it and any errors or issues it encounters. Use it to understand the flow dynamics, and how to test/exercise it better in application space.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..

The secondary call to Init() fails.

The first 74KB takes 90970 ms, ie 1.5 minutes, which seems incredibly slow.

You need to write 256-byte pages, but this should be pretty efficient unless you add a lot of delays.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..

Thanks a lot.