cancel
Showing results for 
Search instead for 
Did you mean: 

code execution from external Flash

virtualfight
Associate II
Posted on August 04, 2009 at 10:15

code execution from external Flash

11 REPLIES 11
virtualfight
Associate II
Posted on May 17, 2011 at 12:45

Hi,

i've played around with the extern NOR-Flash code execution example from the STM3210E Eval Board. I've found out that code execution from external flash is more than 11 times slower than from internal Flash. Could this be correct?

I planed to use the external Flash to execute some code. But if the perfomance is so slow it would be unusable for me. Is there a way to speed the performance up?

jj
Associate II
Posted on May 17, 2011 at 12:45

Thanks for your observation.

Does your test exercise a variety of functions - so that a particularly good or ''bad'' one does not skew your results?

Suppose that you could always copy/move code from external to internal flash. May enable you to use a smaller ST32 - but with cost/size penalties.

I don't have an ''E'' board yet - perhaps others could repeat your test and report...

virtualfight
Associate II
Posted on May 17, 2011 at 12:45

Yes, my test exercises a variety of functions.

The detailed results: a function which contains only ''simple'' instructions like add is up to 15 times slower. Other operations like multiplikations, branches, RAM access and mixed functions are about 11 times slower.

For the tests I've set DataSetupTime to 0x06 and AddressHoldTime/ AddressSetupTime to 0x00 as described in AN2784.

It would be nice if somebody could confirm my results.

stm322
Associate II
Posted on May 17, 2011 at 12:45

Hello,

I ve got a STM3210E eval board. And I m running my code from the external NOR flash.

I don t mind to do a quick test. But you have to explain me how to check the speed comparaison between internal flash and external flash.

jj
Associate II
Posted on May 17, 2011 at 12:45

stm321-

Hi & thanks - have an ''E'' on order - not in yet.

One simple way to do this is to set a port bit

just upon entry to the test code. Clear this

bit upon exit. A scope or simple timer then

monitors the duration of this bit. I'd repeat

the measurement several times to insure consistency.

Interested in your findings...

virtualfight
Associate II
Posted on May 17, 2011 at 12:45

Hi,

are there any new experiences?

jj
Associate II
Posted on May 17, 2011 at 12:45

I'm still waiting for an Eval-E with a Rev Y STM32. STM321...

16-32micros
Associate III
Posted on May 17, 2011 at 12:45

Hi jj.sprague,

Please note that High Density devices (having FSMC and up to 512K of Flash) are rev Z and no other revisions are available.

Rev Y silicon is only for medium density devices : Please have a look at our Data sheets and erratas.

Cheers,

STOne-32.

jj
Associate II
Posted on May 17, 2011 at 12:45

Hi STOne-32,

Thank you - of course you are correct - please understand the upset and confusion this Rev ''Y'' has caused.

Contributing to my confusion was the earlier ''hint'' in which we IAR 5.20 users were encouraged to ''exchange'' non-Rev ''Y'' devices in their EVAL Kits. So I may not be ''alone'' in my Rev ''Y'' ineptness. (I must tell you that Avnet and my local ST Sales Office ''both'' have assured me that my EVAL-E board(S) will include Rev ''Y'')

Many do hope you will address Rev ''Y'' in your pending ''Rev Compatibility'' posting. (this rev issue must be a special nightmare for ST - it has caused great upset to my firm/clients)