cancel
Showing results for 
Search instead for 
Did you mean: 

what is HAL_OSPI_AutoPolling() ? how to fix it ?

MNapi
Senior III

After trying the sample code from STM32Cube_FW_L4_V1.18.0

for octo spi

I getting stuck on

HAL_OSPI_AutoPolling(hospi, &sConfig, HAL_OSPI_TIMEOUT_DEFAULT_VALUE);

it is not working, after reading posts and

STM32L4Rxxx and STM32L4Sxxx device errata

I found information that:

"Auto-polling mode not functional with new octal memories"

any idea how to work around it or fix ?

the sample code does not work, I cannot test OSPI.

28 REPLIES 28

Seem to recall the Micron vs Macronix relates to DTR/DDR modes

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

> I found information that:"Auto-polling mode not functional with new octal memories"

>any idea how to work around it or fix ?

Poll "manually"?

 

Yes, covered earlier.

The forum makes it very hard to navigate longer threads, hiding / masking content

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

thanks again for the redesigned external loader for OCTOSPI for

STM32H7A3IIT6Q
MX25LM51245GMI00

I got this working finally but I had to create the BIN file in CubeIDE. You need BIN file, it does not load the external loader without it.

And again this OCTOSPI did not want to work in CubeIDE despite copy all the code from working Keil. But I have it working in Keil

So I loaded the external loader and BIN using CubeProgrammer, then I could read from 0x90000000

then I went to  Keil, I could not find a place to show me the loader , Keil shows that it is loading at 0x80000000 but I guess it must go to 0x90000000;

1.png

but it loads now more data I can see for the first time full screen 1024x600 (before I could load smaller pictures only )

IMG_4348.JPG

it is really fast the picture is on instantaneous after turning the power on.

Keil enumerates the .FLM it finds in C:\KEIL\ARM\FLASH and perhaps others pathed to the Packs per the device / board instance. 

C:\Keil5xx\Arm\Packs\Keil\STM32U5xx_DFP\2.2.0\CMSIS\Flash\MX25LM51245G_STM32U599J-DK.FLM

Names shorter than 31 characters, and fit in the allocated RAM.

You can contribute to my work / effort via  https://paypal.me/cliveone

keil_flm_add.jpg

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

I guess I would need to create the FLM file to show there.

I looked at PAYPAL I would not mind to use your help with some projects to have it right away. Instead of spending weeks trying do it myself.

But the problem is when I started to sell my old garage junk on eBay my paypal account was limited with no explanation.

I just gave up.

 

From the Keil H7 pack, The H7B3I-EVAL rebuilt with your pin options

https://github.com/cturvey/stm32extldr/blob/main/h7_mx25lm51245g/MX25LM51245G_STM32H7A3I-MNAPI.flm

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

thanks I am still working on this I try to follow the AN333 from Keil.

do first QSPI and then try the same way OSPI

I know that it is easy few lines code here and there, it takes time.You need to link, map it.

People who do it for living do it in 5 minutes. They spend a few years at collage / university to learn it.

If I could I would to the old Z80A + ROM+ DRAM it was so easy, I can still do it straight from my head.

but they you need interface for TFT, SD card etc.

 

there are ready projects but in EWARM only

https://github.com/STMicroelectronics/stm32-external-loader

I am surprised that they did it only one platform. It would be easy to follow working project. I do have those discovery boards with QSPI and OSPI.

 

 

 

I cannot get it working in Keil, it keeps saying , it cannot erase flash. I tried to follow all the setting from AN333.

Maybe I am missing few lines of code in main.c but I do not think I missed anything after reading AN333 from Arms/Keil

 

Also trying to make my own external flash loader in Keil does not work, I am getting error trying to build the project.

But I am getting more luck with you loader for CubeProgrammer. After loading I can actually read from 0x90000000

I will try to move my project to CubeIDE and see if it works.