DSPRelated.com
Forums

updating a programm

Started by lime...@freenet.de July 18, 2007
hi,
i have the following problem.
the task is: -----
| DSP,6711 |
| Programm1:runs and |
| loads programm2(binary-file with hex6x)|
| over network from PC and stores |
| it into SDRAM:beginning at 0x80400000 |
| |
| |
------
know i can load succesfully programm2 which is the simple blink-programm and which i have convert into binary form with/without -boot option by hex6x tool
******this is the hex.cmd file*******
FlashBlink.out

-b
-map fbHex.map
-memwidth 8
-image
-zero
-boot /* create a boot table for all initialized sects */
-bootorg 0x80400400 /* address of the boot/copy-table */
-bootsection .boot_load 0x80400000 /* section containing our asm boot routine */
ROMS
{
FLASH: org = 80400000h, len = 0x20000,romwidth = 8, files = {FlashBlink62.hex}
}
**************************************************************

know this second Programm is exactly stored in SDRAM beginning at 0x80400000. but Programm1 is active in the area 0x80000000-0x80400000
so what i want is to disable or delete Programm1 and make the Programm2 active which has to run after a maybe a reset.

Other issue is the .boot_load from Programm2 i know where it is and i tried to copy this into the flash, because i know that after a reset the first 1k is copied to 0x000 and the dsp executes it, but it doesn't work! i can't copied it really from SDRAM to flash(0x90000000), so for this i try it with menue edit->memory->copy function by CCS2.1

so i have to know: -how to copy 1k from sdram to flash?
-how to disable the first programm and start running the
programm2?


What board are you using?


for writing in Flash, you need a specific driver...have to use a specific algorithm, not possible from CCS.


We wrote our own driver...maybe you can find some on the web...it's not that hard once you know how it works (which is most of the time the problem).


Regards








From: l...@freenet.de
Reply-To: l...@freenet.de
To: c...
Subject: [c6x] updating a programm
Date: Wed, 18 Jul 2007 08:51:15 -0400
>hi,
>i have the following problem.
>the task is: -----
> | DSP,6711 |
> | Programm1:runs and |
> | loads programm2(binary-file with hex6x)|
> | over network from PC and stores |
> | it into SDRAM:beginning at 0x80400000 |
> | |
> | |
> ------
>know i can load succesfully programm2 which is the simple blink-programm and which i have convert into binary form with/without -boot option by hex6x tool
>******this is the hex.cmd file*******
>FlashBlink.out
>
>-b
>-map fbHex.map
>-memwidth
8
>-image
>-zero
>-boot /* create a boot table for all initialized sects */
>-bootorg 0x80400400 /* address of the boot/copy-table */
>-bootsection .boot_load 0x80400000 /* section containing our asm boot routine */
>
>
>ROMS
>{
> FLASH: org = 80400000h, len = 0x20000,romwidth = 8, files = {FlashBlink62.hex}
> }
>**************************************************************
>
>know this second Programm is exactly stored in SDRAM beginning at 0x80400000. but Programm1 is active in the area 0x80000000-0x80400000
>so what i want is to disable or delete Programm1 and make the Programm2 active which has to run after a maybe a reset.
>
>Other issue is the .boot_load from Programm2 i know where it is and i tried to copy this into the flash, because i know that after a reset the first 1k is
copied to 0x000 and the dsp executes it, but it doesn't work! i can't copied it really from SDRAM to flash(0x90000000), so for this i try it with menue edit->memory->copy function by CCS2.1
>
>so i have to know: -how to copy 1k from sdram to flash?
> -how to disable the first programm and start running the
> programm2?
>
>
>
>
>
>
><*> To visit your group on the web, go to:
> http://groups.yahoo.com/group/c6x/
>
><*> Your email settings:
> Individual Email | Traditional
>
><*> To change settings online go to:
> http://groups.yahoo.com/group/c6x/join
> (Yahoo! ID required)
>
><*> To change settings via email:
> mailto:c...
> mailto:c...
>
><*> To unsubscribe from this group, send an email to:
> c...
>
><*> Your use of Yahoo! Groups is subject to:
> http://docs.yahoo.com/info/terms/
>

__._,_.___







">http://www.dsprelated.com/groups/c6x/1.php



_____________________________________

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:



Archives:  http://www.dsprelated.com/groups/c6x/1.php



To Post:  Send an email to c...



Other DSP Related Groups: http://www.dsprelated.com/groups.php









stime84784467













__,_._,___
Limes-

> i have the following problem.
> the task is: -----
> | DSP,6711 |
> | Programm1:runs and |
> | loads programm2(binary-file with hex6x)|
> | over network from PC and stores |
> | it into SDRAM:beginning at 0x80400000 |
> | |
> | |
> ------
> know i can load succesfully programm2 which is the simple
> blink-programm and which i have convert into binary form
> with/without -boot option by hex6x tool
>
> :
> :
>
> so i have to know: -how to copy 1k from sdram to flash?
> -how to disable the first programm and start running the
> programm2?

Just some general comments. When ready to "switch programs" then you might try:

-jump to some small code outside the
the program storage areas and outside
what the .cmd file "knows about"

-small code copies new program to desired
location, changes the Reset vector if
needed

-small code asserts chip Reset pin, for
example asserts a GPIO line that is OR'd
with the existing Reset circuit

Note that C6x processors do not have a Reset instruction, so it takes some work to
re-establish the Reset state of the processor in software. A lot of registers have
to be written to Reset values specified in the data sheet.

-Jeff