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

Subversion Repositories w11

[/] [w11/] [tags/] [w11a_V0.7/] [tools/] [asm-11/] [w11/] [sys/] [dl11/] [simple_echo.mac] - Blame information for rev 33

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 19 wfjm
; $Id: simple_echo.mac 504 2013-04-13 15:37:24Z mueller $
2
;
3
; simple echo test for DL11 interface
4
;
5
        RCSR = 177560
6
        RBUF = 177562
7
        XCSR = 177564
8
        XBUF = 177566
9
;
10
        CR = 015
11
        LF = 012
12
;
13
; transfer vector
14
;
15
        .asect
16
        . = 200
17
        jmp     start
18
;
19
; test code
20
;
21
        . = 1000
22
;
23
start:  mov     #start,sp
24
;
25
1$:     tstb    @#RCSR          ; input ready ?
26
        bpl     1$              ; if not poll
27
        movb    @#RBUF,r0       ; get input char
28
2$:     tstb    @#XCSR          ; output ready ?
29
        bpl     2$              ; if not poll
30
        movb    r0,@#XBUF       ; echo received char
31
        cmpb    #CR,r0          ; was it CR ?
32
        bne     1$              ; if not, wait for next input
33
3$:     tstb    @#XCSR          ; output ready ?
34
        bpl     3$
35
        movb    #LF,@#XBUF      ; send LF
36
        br      1$
37
;
38
        .end

powered by: WebSVN 2.1.0

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