This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

ARM, C and Assembly

Hi,
I want to write some subroutines with µVision3 in assembler and use this in my C-Funktions (Philips LPC2148). For example I have wrote(copied) this one:

//--------------------------------------------
//cpu_asm.asm 
//--------------------------------------------

NO_INT          EQU     0xC0

AREA    OSCPUSRSave, CODE
        PUBLIC  __OSCPUSRSave

__OSCPUSRSave   PROC    CODE32


    MRS     R0,CPSR
    ORR     R1,R0,#NO_INT
    MSR     CPSR_c,R1

    MRS     R1,CPSR
    AND     R1,R1,#NO_INT
    CMP     R1,#NO_INT

    BNE     __OSCPUSRSave
    BX      LR

ENDP

END

//--------------------------------------------


After that i declared in a C-File:

extern void __OSCPUSRSave(void);

Now i get every time the error Message: ***Warning L123: UNRESOLVED EXTERNAL SYMBOLS and ***ERROR L128: REFERENCE MADE TO UNRESOLVED EXTERNAL SYMBOL: __OSCPUSave?T ADDRESS: 000003AAH I think the linker have to find the procedur because i wrote: PUBLIC __OSCPUSRSave , but he didn't.
I hope someone can help me, thanks.

Parents Reply Children
No data