DSPRelated.com
Forums

C5402: big endian or little endian?

Started by gl4com November 29, 2005
Can somebody let me figure out if C5402 is little endian
or big endian?

this information should be into TI's docs but I wasn't able to get it.

Thanks in advance!

Gl.



GI-

> Can somebody let me figure out if C5402 is little endian
> or big endian?
>
> this information should be into TI's docs but I wasn't able to get it.

Nothing is mentioned because there are no choices:

-16-bit data is always stored as 16-bit chunk so there
is no byte-ordering issue

-there are some "double word" instructions; these access
the ms word first (low memory) then ls word

-in 8-bit mode, the HPI can be set to transfer ls byte
or ms byte first. But data still ends up in DSP memory
the same way

The second item above would be the closest thing to endianness for this device. For
example it could affect external processor software that assumed an Intel style
word-ordering model.

-Jeff



Hi,

As Jeff said I think there is nothing like big endian or little indian
within DSP 54x. Everything is either 16bit or 32bit. but, say an external
application running in say ARM processor which wants to read data words in
DSP through HPI then it depends on the format that processor/OS (say
embedded linux) or what you have chosen in it.

Ritesh On 11/29/05, Jeff Brower <jbrower@jbro...> wrote:
>
> GI-
>
> > Can somebody let me figure out if C5402 is little endian
> > or big endian?
> >
> > this information should be into TI's docs but I wasn't able to get it.
>
> Nothing is mentioned because there are no choices:
>
> -16-bit data is always stored as 16-bit chunk so there
> is no byte-ordering issue
>
> -there are some "double word" instructions; these access
> the ms word first (low memory) then ls word
>
> -in 8-bit mode, the HPI can be set to transfer ls byte
> or ms byte first. But data still ends up in DSP memory
> the same way
>
> The second item above would be the closest thing to endianness for this
> device. For
> example it could affect external processor software that assumed an Intel
> style
> word-ordering model.
>
> -Jeff
>



We consider it big endian. Its native type is a 16bit word. It is a
word addressable machine (16bits). 32 bit values are stored in memory
as

|HI_WORD|
|LO_WORD|

i.e. the high word is at the lower memory location, which makes it big
endian

-SKS

--- In c54x@c54x..., "gl4com" <gl4com@y...> wrote:
>
> Can somebody let me figure out if C5402 is little endian
> or big endian?
>
> this information should be into TI's docs but I wasn't able to get it.
>
> Thanks in advance!
>
> Gl.
>