[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [microblaze-uclinux] Newbie question about external ram executability
Hi Kevin,
Thanks! See my interleaved replies
Hello Wade.
| I've created a flash programmer/ram test/xmodem download
| program in order
| to download the uClinux kernel to the board when it is just
| being brought
| up in production (sometime later this year?!!).
|
| I used mb-objcopy to create a binary image from a small test program.
>Did you set the start address of the code that is to live in ram to the
>correct address? Otherwise, in the crt that is linked in, the program will
>jump to 0 and there will be nothing there except the small code you have
>that "brild r9, r15". You should be able to load your code to 0x80000000
>and then run (con? Can't quite remember, it's been a while) from that
point.
>You set the start address in applications tab, right click your app, and
set
>compiler options.
That 'brild r9, r15' was in the code loaded into BRAM, and it was
telling me through the debugger that it was getting ready to execute at
address 0x80000000. I'm beginning to suspect the mdm does not work with
external ram at all, since the gdb totally blanked the screen when it
should
have been showing me the code.
| I downloaded the program into external static ram at 0x80000000 and
| verified it was there.
|
| I created a small boot program to jump to that address, and used mdm
| assembly language stepping to prove that the "brild r9, r15"
| code was about
| to jump to 0x80000000 (in r15).
|
| As soon as it gets to that address, it shows a blank screen in the
| debugger, and then it reboots at 0 (the bitram). If I just
| let it free
| run, it reboots at zero (which is what caused me to break out the
| debugger.) We are doing this because we can't get uClinux to boot
| properly, and we are now in the simple step by step phase.
>Does your code work if you load it into BRAM? If so, then it sounds like
>the start address is not correct. See above.
Yes, but that was not the point I was after, although I understand what
you mean.
I also tried the relocation trick, and when you do that, mb-objcopy fails
dramatically whe
converting to binary.
It gives 'BFD: Warning: Writing section '.text' to huge (ie negative) file
offset 0x80000000.'
This repeats for every section, then it says 'mb-objcopy: test.bin: File
truncated' and produces
a 40 byte file from a file that is around 1,000 bytes in size.
Needless to say, that does not work either.
I've been googling and reading, and I don't yet see any docs on how to
create a very small binary program that resides
in external ram, at least with the mb tools given. Although, mb-objcopy
did the SREC convertor without complaint. I guess
I'll try writing an SREC loader next, though it feels like a waste of time.
wade
***CONFIDENTIALITY NOTICE***
This communication (and any attachment) is confidential. It should only be
read by the person(s) to whom
it is addressed. If you have received this communication in error, please
notify the sender by reply and delete this communication.
*****************************************
___________________________
microblaze-uclinux mailing list
microblaze-uclinux@xxxxxxxxxxxxxx
Project Home Page : http://www.itee.uq.edu.au/~jwilliams/mblaze-uclinux
Mailing List Archive : http://www.itee.uq.edu.au/~listarch/microblaze-uclinux/