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

error undefined symbol system init....

Hello my friends.i have a problem with my keil uvision4.
When i build my project error undefined symbol.... occurs.I read other forums and they said they add start up.c to teir project and their problem solved.But when i do this the program compiles with no errors but it doesnt work on the hard ware.Im sure that my code works because in my last keil uvision i didnt have this problem(the start up file worked without needing any c file in my last keil version and the hardware worked very nicely).
Does any one knows what the matter is?

Parents
  • Reset_Handler   PROC
                    EXPORT  Reset_Handler             [WEAK]
                    IMPORT  SystemInit
                    IMPORT  __main
                    LDR     R0, =SystemInit
                    BLX     R0
                    LDR     R0, =__main
                    BX      R0
                    ENDP
    


    I compared the start up files in the last version i had and this version.The code above is my new version and is lines 3,5,6 are not the same in these versions.When i removed these 3 lines every thing was alright .But i do'nt know the reason.I'm confuse why when i add system_lpc17xx.c the program does not work on hardware,but when i just remove these lines ,the code works.I do not use CMSIS.I just work with registers.

    Reset_Handler   PROC
                    EXPORT  Reset_Handler             [WEAK]
                    IMPORT  __main
                    LDR     R0, =__main
                    BX      R0
                    ENDP
    

Reply
  • Reset_Handler   PROC
                    EXPORT  Reset_Handler             [WEAK]
                    IMPORT  SystemInit
                    IMPORT  __main
                    LDR     R0, =SystemInit
                    BLX     R0
                    LDR     R0, =__main
                    BX      R0
                    ENDP
    


    I compared the start up files in the last version i had and this version.The code above is my new version and is lines 3,5,6 are not the same in these versions.When i removed these 3 lines every thing was alright .But i do'nt know the reason.I'm confuse why when i add system_lpc17xx.c the program does not work on hardware,but when i just remove these lines ,the code works.I do not use CMSIS.I just work with registers.

    Reset_Handler   PROC
                    EXPORT  Reset_Handler             [WEAK]
                    IMPORT  __main
                    LDR     R0, =__main
                    BX      R0
                    ENDP
    

Children