cancel
Showing results for 
Search instead for 
Did you mean: 

str912 bootloader with KEIL tools - one more time

mikhailm
Associate II
Posted on July 02, 2008 at 09:23

str912 bootloader with KEIL tools - one more time

18 REPLIES 18
vatman
Associate II
Posted on May 17, 2011 at 09:51

Hello everyone,

I have been working about iap, but could not success yet.I modified the IAR source for my project in KEIL (on MCBSTR9 board). I used a button instead of joystick to jump the menu. Then I hit ''1'' for sending the .bin file. And I take ''verification failed''. I attach my project. Can anyone help me ?

Thanks.

vatman
Associate II
Posted on May 17, 2011 at 09:51

Hi again, i changed something and i can upload the .bin file now. The changes

* options -> target -> code generation -> thumb mode (I was trying in ARM-Mode before)

* Disable the PLL and change the PLL_PDIV from 2 to 3.

I attach the working code.

But I had a new problem. The .bin file which i upload by bootloader is not working. I think i had a mistake when switching bank.

I use uVision, and the code i have changed is done in IAR (the application AN2475 in ST's website). The IAR code use __ramfunc to work the code in RAM when switching, but i could not find equivalent of this command.

vatman
Associate II
Posted on May 17, 2011 at 09:51

i read the keil's ram usage and changed my iap code...

http://keil.com/support/docs/3228.htm

the uploaded prog. has not worked yet. but i did not consider the config of the prog. which i want to upload ?

now, i dont know if iap works correct or may be the config of the upload prog wrong ???

anybody give me an advise ???

mikhailm
Associate II
Posted on May 17, 2011 at 09:51

First step would be to verify if you are burning code into the flash correctly.

Read it back and verify that it is burned correctly. You can also use debugger to look at the flash context.

vatman
Associate II
Posted on May 17, 2011 at 09:51

mikhailm, thanks your reply. You are exactly right. But i am using the limited (free) version of uVision. So i did not read in flash. And when booting bank1 i can not use debugger.

vatman
Associate II
Posted on May 17, 2011 at 09:51

mikhailm, i follow the KEIL's instruction:

http://www.keil.com/support/docs/3347.htm

Then i can boot from bank1. My iap application is working from bank1 now.

(i attached it before in this title.)

I also have to ask KEIL support about limitations.

Thanks.

mikhailm
Associate II
Posted on May 17, 2011 at 09:51

I think that is exactly what your problem is..... I don't remember exactly what the issue with ''free'' version of uVision is, but I couldn't make anything to run from Bank1.

even the LED blink demo.......

EDIT:

and I remember that I even received an email from Keil confurming such limitation on limited version

[ This message was edited by: mikhailm on 02-07-2008 08:18 ]

mikhailm
Associate II
Posted on May 17, 2011 at 09:51

Well.... I looked into you project

if nothing else you still have no files loaded into RAM.

other note:

you still using .h files from standard library location. Since you have to modify 91x_fmi.h for bootloader one way and for ''real'' program other way this isn't a good idea.

You want to copy all ''modifiable'' .h files into the corresponding project folders.

I also don't see BOOT_BANK1 defined for assembly files...

I suggest you reread everything that was posted in this thread. I was following the advice and managed to make it work...... through ENET, not serial port.

vatman
Associate II
Posted on May 17, 2011 at 09:51

I changed my code following the KEIL's instruction before, but i could not attached at that time. Now, i attached it.

The .h files are in standart libarary location, it is correct. But when i want to compile ''real'' program, i uncomment #define Remap_Bank_1. So, i understood your advice but i think the problem is not about that.

Can you give me some advice about the real program config ? Or may be a sample project.