Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

SAM7S256 porting

8 views
Skip to first unread message

AnaDron

unread,
May 25, 2010, 6:57:01 AM5/25/10
to
Hello
I tried to compile the port on SAM7S256. Project NativeSample successfully
compiled, but the file VectorsTrampolines.s I saw this:

. Section VectorsTrampolines, "xa",% progbits

. Arm

ARM_Vectors:

@ RESET
RESET_VECTOR:
b UNDEF_VECTOR

@ UNDEF INSTR
UNDEF_VECTOR:
ldr pc, UNDEF_SubHandler_Trampoline

...

UNDEF_SubHandler_Trampoline:
. Word UNDEF_SubHandler

Thus, we see that the reset vector refers to undef vector. Going further
along the chain, it became obvious that in the end call the function
AT91_SAM_Driver::Reset, which resets the processor.
Why is this happening?

P.S. Sorry my english... :)

Lorenzo Tessiore

unread,
May 27, 2010, 4:05:07 PM5/27/10
to
hello,


in VectorHandler.s, we call UNDEF_HANDLER vector, which is coded in
DeviceCode\Cores\arm\Diagnostics\Aborts.cpp as

void UNDEF_Handler( UINT32* registers, UINT32 sp, UINT32 lr )
{
ASSERT_IRQ_MUST_BE_OFF();

#if !defined(BUILD_RTM)
Verify_RAMConstants((void *) FALSE);

ABORT_HandlerDisplay(registers, sp, lr, 4, "Undef Instr", TRUE);

CPU_Halt();
#else
CPU_Reset();
#endif // !defined(BUILD_RTM)
}


that means that is you are building for 'RTM' (with /p:flavor=RTM) then you
get a reset


Regards
L.

AnaDron

unread,
Jun 1, 2010, 2:48:01 AM6/1/10
to
I do not create for the 'RTM'. Thus it turns out that the function
CPU_HALT. And further "while (true);".
Ie to start processing it to fall into an infinite loop. I can not
understand - where the entrance to the function of EntryPoint.

Lorenzo Tessiore

unread,
Jun 2, 2010, 6:54:51 PM6/2/10
to
it is here

%SPOCLIENT%\DeviceCode\Cores\arm\AssemblyCode\arm\[gnu_s|RVD_s]\FirstEntry.s

0 new messages