cancel
Showing results for 
Search instead for 
Did you mean: 

STM32L162RE EEprom programming using STLink utility

sivaprasad
Associate II
Posted on April 07, 2016 at 07:44

I have been working with STM32L162RE MCU. For programming I am using STM32 ST-Link Utility as well as ST-LINK_CLI. From the data sheets I understand that it supports 16KB of Data Eeprom and 512KB of flash memory. I  am able to use 256KB flash in both the banks without any issues. But when I try to program the EE prom using link uitlity, it gives error when I try to program beyond 6KB in bank 2.

I would like to know about  the base address of both the data memory banks. And also need to know how to program the complete 16 KB of data memory available. Any help in this regard is highly appreciated.
8 REPLIES 8
Amel NASRI
ST Employee
Posted on April 07, 2016 at 12:06

Hi r.sivaprasad,

Please refer to 

http://www.st.com/st-web-ui/static/active/en/resource/technical/document/reference_manual/CD00240193.pdf

 to know about the base addresses of the banks.

What kind of error do you get when trying to program beyond 6Kb in Bank2? Please share the error message.

You shouldn't have an issue as STM32L162RE is CAT5 and you have 8Kb in each bank (referring to table 11 of the reference manual).

-Mayla-

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

sivaprasad
Associate II
Posted on April 13, 2016 at 12:38

Thank you Mayla for your reply.

I am getting an error pop up saying ''Error occurred during memory writing''.Writing to any address 0x08083001-0x08083FFF throws the same error.Also the EEprom information is displayed as 6KB. I am attaching the screenshots for your reference.

________________

Attachments :

Data_EEprom_bank.png : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006I0AZ&d=%2Fa%2F0X0000000bcQ%2FMcsNymggutaXNRLYrgcpInat2SXphCBDN5LbI3n5Tw0&asPdf=false

Error_Screenshot.png : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006I07v&d=%2Fa%2F0X0000000bcO%2FDWeOelYw0MJl9Ogbd6.bqpwiwOiNvtCZFYNS5jF1s7Q&asPdf=false
sivaprasad
Associate II
Posted on April 18, 2016 at 07:49

version of STM32 ST_Link Utility used is v3.8.0 

sivaprasad
Associate II
Posted on May 06, 2016 at 08:11

Any help in this regard is highly appreciated. Thanks in advance.

Posted on May 06, 2016 at 10:05

Suggest you validate the EEPROM functionlity from your own code

Tips, buy me a coffee, or three.. PayPal Venmo Up vote any posts that you find helpful, it shows what's working..
sivaprasad
Associate II
Posted on May 18, 2016 at 14:47

Yes.. It works fine writing the EEPROM from the code.. I suspect the issue is with STM Link Utility/CLI  application. Please advise

Posted on May 18, 2016 at 20:46

ST-LINK V3.9.0 was released the other day.

Really not much I can do to elevate this issue, or remediate it. I suspect you will need to solve the problem using a different approach.

Suggest you push into ST via sales/distribution channels.

Tips, buy me a coffee, or three.. PayPal Venmo Up vote any posts that you find helpful, it shows what's working..
Posted on May 18, 2016 at 20:50

I am getting an error pop up saying ''Error occurred during memory writing''.Writing to any address 0x08083001- 0x08083FFF throws the same error. Also the EEprom information is displayed as 6KB. I am attaching the screenshots for your reference.

I wouldn't write to odd addresses, and would probably shrink the write length to it doesn't exceed capacity.

I will push to moderation again.

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