[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [microblaze-uclinux] Newbie question about external ram executability





Hi Kevin,

  THanks for the reply.

Hello Wade.

|   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.

>The mdm does work with external ram, I've used it.  I have not however
used
>gdb that I can remember so I'm not much help there.

  OK. I'll keep looking.

| |   I downloaded the program into external static ram at
| 0x80000000 and
| | verified it was there.

>This should prove that mdm works with external ram.

  Sorry, I was not clear. I proved it was there with another
download of a small monitor program in bitram.
It printed the contents of the memory to the serial port.

|   I also tried the relocation trick, and when you do that,
| mb-objcopy fails
| dramatically whe
| converting to binary.

>It's not a trick, the code must know where it is.  You have to set the
start
>address. Anyone please correct me here if I'm wrong, but I'm pretty sure
>that's the deal.

  I used the gui in 8.1 to set the start address.  After I did that, the
following happened:


|  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.

>I've done exactly what you are doing (though 18 months or more ago) and it
>sort of just worked.  I don't remember having to do mb-objcopy.  I could
>swear I just dow'ed an elf file.  If I had time, I'd throw something
>togethher and test it, but it certainly won't happen this week.  Sorry.

Yes, as a matter of fact, with Xilinx 6.3, I tried similar things 18 months
ago.
Someone else had set the hardware up, all I had to do was get the software
downloaded onto a development board (mbvanilla type).  It worked at that
time,
and I had no real exposure to the Xilinx environment, just the "load"
button.
Something has dramatically
changed with Xilinx 8.1, and I don't yet know what it is. I'm also a raw
newbie
with Xilinx.

I was unable to get mb-objcopy to create a binary image when the GUI had it
located
at 0x80000000.  However, it seemed to generate an SREC image with no
problems.  That
may be my main clue.

>But to back up a bit.
>1. You can read and write 1-byte, 2-byte, and 4-byte data from and to your
>external memory.

  2 bytes and 4 bytes yes. I'll test 1 byte today.

>2. You can download your program to your memory and view it.
>    - Did you look through the disassembled downloaded instructions to
>verify they are targetting the correct address range (life at the
>0x80000000)?

  Using Xmodem I can download to external memory.

  However, I have not been able to view disassembled instructions in
external memory
using gdb and mdm.  I can see and disassemble memory based on my symbols in
bitram.
Is there a section in the manual that I can read?  I've used the search
tool
but have not located the info yet. I'm sure I'm searching for wrong terms.
I'll keep
looking.

  My monitor program proves the data is there.  We placed the external data
chips there ourselves and have proven the external memory works using logic
analyzers
and scopes.

>3. Can you 'con' a small program in external memory (blink an led or
>something)?
>    - Unless you can do this, jumping to your code won't help.

  That is what I'm trying to do.  I'm still fighting it.  It will take me a
while
longer, I expect.  Basically you are saying "it just works."  As soon as I
find out
what I'm doing wrong, I'll post so others can have the magic formula.

   We were using Xilinx 7.1 last year and things worked fairly well.  We
made
the decision to move to 8.1.  I'm beginning to suspect 8.1 is not yet
ready for prime time in a few invisible areas.

Good luck,
./ks

Thanks!

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/