OpenCores
URL https://opencores.org/ocsvn/eco32/eco32/trunk

Subversion Repositories eco32

[/] [eco32/] [trunk/] [simtest/] [rom/] [rom02.s] - Blame information for rev 191

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 9 hellwig
;
2
; rom02.s -- terminal output, polled
3
;
4
 
5
        .set    tba,0xF0300000  ; terminal base address
6
 
7
        add     $8,$0,tba        ; set terminal base address
8
L1:
9
        add     $10,$0,'a'       ; set char to ASCII 'a'
10
L2:
11
        ldw     $9,$8,8         ; load transmitter status word into $9
12
        and     $9,$9,1         ; extract LSB - 'transmitter ready'
13
        beq     $9,$0,L2 ; loop while not ready
14
        stw     $10,$8,12       ; load char into transmitter data register
15
        add     $10,$10,1       ; next char
16
        sub     $9,$10,'z'+1    ; check if above 'z'
17
        bne     $9,$0,L2 ; no - loop
18
        j       L1              ; else reset to 'a'

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.