I want to try programming in asm. How to connect startup file with new asm file?
I make this code:
GLOBAL prog1 AREA reset, CODE, READONLY ENTRY prog1 MOV R0, #11 stop B stop END
I saw in startup code "Enter C code " and then it is calling IMPORT __main. How to change it, so it will import my new asm function?
; Enter the C code IMPORT __main LDR R0, =__main BX R0 IF :DEF:__MICROLIB EXPORT __heap_base EXPORT __heap_limit ELSE ; User Initial Stack & Heap AREA |.text|, CODE, READONLY IMPORT __use_two_region_memory EXPORT __user_initial_stackheap __user_initial_stackheap LDR R0, = Heap_Mem LDR R1, =(Stack_Mem + USR_Stack_Size) LDR R2, = (Heap_Mem + Heap_Size) LDR R3, = Stack_Mem BX LR ENDIF END