- added uart_puts

git-svn-id: http://moon:8086/svn/vhdl/trunk@1633 cc03376c-175c-47c8-b038-4cd826a8556b
This commit is contained in:
2021-04-04 09:01:49 +00:00
parent 04c0284ca7
commit 64c6a3004d
+21
View File
@@ -9,6 +9,27 @@ UART_TX_FULL equ 0x02
UART_TX_CMPL equ 0x04
UART_RX_PRESENT equ 0x10
; -------------------------------------------------
; uart_puts
; -------------------------------------------------
; R1 : ptr to string
uart_puts: push R0
u_p_lp: movx R0, (R1)
inc R1
tst R0
jz ex_ugp
call uart_putchar
jmp u_p_lp
ex_ugp: pop R0
ret
; -------------------------------------------------
; uart_putchar
; -------------------------------------------------
; R0 = input
uart_putchar: jmp sout
; -------------------------------------------------
; sout
; -------------------------------------------------