This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: How do I get __ARMEB__ defined ?


"Edward,Yan-Chi,Lin" wrote:
> 
> Thanks Jifl
> 
> But why the option "Use big endian mode" didn't add the "-EB" to the Global compiler flags ?

That would be a problem. Which platform is this?
 
> Now from my understanding. If I want to access a byte at, for examples, 0x7FF9003,
> I can't use HAL_READ_UINT8(0x7FF9003). Is that right ?

Yes, you always have to *assume* it is little-endian, and let the system
handle the translation if it's actually big-endian. Believe me, this is
better for generic code than the alternative which is always to provide two
values.

Jifl
-- 
Red Hat UK, Rustat House, 62 Clifton Road, Cambridge, UK. CB1 7EG 
Tel: +44 (1223) 271062              ||  These opinions are all my own fault

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]