Applerm-II/reset.S
Takashi Toyoshima dd372c8a2d Ready to implement a 6502 interpreter
All investigation for implementation and testing were done.
Now, 6502.S can be verified on qemu-arm, and run even on LPC1114.
All I have to do is just implement the 6502 interpreter.
2014-12-05 02:43:58 +09:00

33 lines
478 B
ArmAsm

.syntax unified
.cpu cortex-m0
.align 2
.thumb
.thumb_func
.include "registers.inc"
.extern cpu6502_reset
.extern cpu6502_run
.extern uart_init
.extern uart_putc
.section .rodata
hello:
.ascii "Applerm II\n\000"
.text
.global _reset
.type _reset, %function
_reset:
ldr r0, =#(_stack_top - 32)
mov sp, r0
bl uart_init
ldr r0, =#hello
bl uart_putstr
bl cpu6502_reset
bl cpu6502_run
1:
b 1b
.size _reset, .-_reset