DSPRelated.com
Forums

Booting program from flash

Started by ron_zach October 28, 2003
Hi,

I am trying to boot up my program through flash. I have been able to
flash the board before using simple programs such as modified
versions of the POST program.
Now I want to flash a more complicated program which is run from
sdram. I am a bit confused at how to approach flashing this
program. I was thinking I would burn the contents of my current out
file to 0x90000400 in flash and then I must right a 1k bootloader
that will load the coff file from 0x90000400 in the same way as CSS
loads programs in the DSP.
Is there any examples of how to go about doing this? How do I read
the coff file and place the sections in there appropriate places? Is
there some better way to do this?

Thanks

Ron



Hello Ron,
 
There are a few ways to 'skin that cat' [sorry if you are a cat lover].
 
One is a utility from TI called 'flashburn' [if you are a registered CCS user, you can download it - registration may not be required].
 
I prefer the 'manual way' [an overview is listed-research TI docs for more details]
Your COFF file is meant to be processed by a loader.  The first step is to use a TI utility called hex6x.exe - this converts from COFF to a simple ASCII readable format [something like "add-data-data-data-csum"].
You can then run flash.exe
[\ti\examples\dsk6711\board_util\flash\Host\Debug\flash.exe].
 
A troubleshooting tip -
Plug an embedded breakpoint near the beginning of your code, select debug->reset CPU.  The DSP will reset, the flash will start booting and then halt at the BP and give control to CCS.
You can use the following as an embedded breakpoint in non-optimized C code-
asm(BP_LABEL: .word 0x10000000);
 
As far as the 'code layout' is concerned, it is up to you [and maybe 'how many bits that you need']
 
mikedunn

ron_zach <r...@yahoo.com> wrote:
Hi,

I am trying to boot up my program through flash. I have been able to
flash the board before using simple programs such as modified
versions of the POST program.
Now I want to flash a more complicated program which is run from
sdram. I am a bit confused at how to approach flashing this
program. I was thinking I would burn the contents of my current out
file to 0x90000400 in flash and then I must right a 1k bootloader
that will load the coff file from 0x90000400 in the same way as CSS
loads programs in the DSP.
Is there any examples of how to go about doing this? How do I read
the coff file and place the sections in there appropriate places? Is
there some better way to do this?

Thanks

Ron
_____________________________________
Note: If you do a simple "reply" with your email client, only the author of this message will receive your answer. You need to do a "reply all" if you want your answer to be distributed to the entire group.

_____________________________________
About this discussion group:

To Join: Send an email to c...@yahoogroups.com

To Post: Send an email to c...@yahoogroups.com

To Leave: Send an email to c...@yahoogroups.com

Archives: http://www.yahoogroups.com/group/c6x

Other Groups: http://www.dsprelated.com



Hi,

If you have more than one DSP chained you can not use Flashburn(it is only for one dsp). Hex6x is the tool that convert COFF format file into formats that programmer can use. I think spend some time to understand COFF format is valued. You can parse the binary stream you need from COFF and translate it into a big array and write your own program in CCS to burn the Flash.

Tao Wang

ShangHai

----- Original Message -----
From:
Date: Tue, 28 Oct 2003 19:30:41 -0800 (PST)
To: ron_zach , c...@yahoogroups.com
Subject: Re: [c6x] Booting program from flash

Hello Ron,
 
There are a few ways to 'skin that cat' [sorry if you are a cat lover].
 
One is a utility from TI called 'flashburn' [if you are a registered CCS user, you can download it - registration may not be required].
 
I prefer the 'manual way' [an overview is listed-research TI docs for more details]
Your COFF file is meant to be processed by a loader.  The first step is to use a TI utility called hex6x.exe - this converts from COFF to a simple ASCII readable format [something like "add-data-data-data-csum"].
You can then run flash.exe
[\ti\examples\dsk6711\board_util\flash\Host\Debug\flash.exe].
 
A troubleshooting tip -
Plug an embedded breakpoint near the beginning of your code, select debug->reset CPU.  The DSP will reset, the flash will start booting and then halt at the BP and give control to CCS.
You can use the following as an embedded breakpoint in non-optimized C code-
asm(BP_LABEL: .word 0x10000000);
 
As far as the 'code layout' is concerned, it is up to you [and maybe 'how many bits that you need']
 
mikedunn

ron_zach <r...@yahoo.com> wrote:
Hi,

I am trying to boot up my program through flash. I have been able to
flash the board before using simple programs such as modified
versions of the POST program.
Now I want to flash a more complicated program which is run from
sdram. I am a bit confused at how to approach flashing this
program. I was thinking I would burn the contents of my current out
file to 0x90000400 in flash and then I must right a 1k bootloader
that will load the coff file from 0x90000400 in the same way as CSS
loads programs in the DSP.
Is there any examples of how to go about doing this? How do I read
the coff file and place the sections in there appropriate places? Is
there some better way to do this?

Thanks

Ron
_____________________________________
Note: If you do a simple "reply" with your email client, only the au thor of this message will receive your answer. You need to do a "reply all" if you want your answer to be distributed to the entire group.

_____________________________________
About this discussion group:

To Join: Send an email to c...@yahoogroups.com

To Post: Send an email to c...@yahoogroups.com

To Leave: Send an email to c...@yahoogroups.com

Archives: http://www.yahoogroups.com/group/c6x

Other Groups: http://www.dsprelated.com


_____________________________________
Note: If you do a simple "reply" with your email client, only the author of this message will receive your answer.  You need to do a "reply all" if you want your answer to be distributed to the entire group.

_____________________________________
About this discussion group:

To Join:  Send an email to c6x-s u...@yahoogroups.com

To Post:  Send an email to c...@yahoogroups.com

To Leave: Send an email to c...@yahoogroups.com

Archives: http://www.yahoogroups.com/group/c6x

Other Groups: http://www.dsprelated.com


">Yahoo! Terms of Service.
--

_______________________________________________
Sign-up for your own personalized E-mail at Mail.com

CareerBuilder.com has over 400,000 jobs. Be smarter about your job search