Hi,
I am executing the below code
AREA asse1, CODE, READONLY export start1 start1 mov r0,#10; mov r1,#00; loop add r1,r0 ;r1=r1+r0 subs r0,#1 ; dec ro bne loop stop b stop end
I have added all the start up files, but getting an error
.\Objects\ex6.axf: Error: L6218E: Undefined symbol main (referred from __rtentry2.o).
I am getting similiar error for C-codes also
Please help
Please read the instructions for posting source code, it will make it more readable and shows you are attentive to detail. http://www.keil.com/forum/tips.asp
So if it is complaining about a missing symbol perhaps you could consider *adding* the symbol?
export main main b .
The linker was still expecting to see a file in the project defining main(), evidently you were not supplying that, and it therefore complained. If you get similar errors when compiling other projects consider what the error messages are complaining about.
AREA asse1,CODE,READONLY
export start1
start1
mov r0,#10; mov r1,#00; loop add r1,r0 ;r1=r1+r0 subs r0,#1 ; dec ro bne loop stop b stop end
AREA asse1,CODE,READONLY export start1 start1 mov r0,#10; mov r1,#00; loop add r1,r0 ;r1=r1+r0 subs r0,#1 ; dec ro bne loop stop b stop main b . end