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

Subversion Repositories eco32

[/] [eco32/] [trunk/] [hwtests/] [dsptest/] [serial.s] - Blame information for rev 206

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

Line No. Rev Author Line
1 14 hellwig
;
2
; serial.s -- the serial line interface
3
;
4
 
5
;***************************************************************
6
 
7
        .set    ser0base,0xF0300000     ; serial line 0 base address
8 149 hellwig
        .set    ser1base,0xF0301000     ; serial line 1 base address
9 14 hellwig
 
10
        .export serinit                 ; initialize serial interface
11
 
12
        .export ser0inchk               ; line 0 input check
13
        .export ser0in                  ; line 0 input
14
        .export ser0outchk              ; line 0 output check
15
        .export ser0out                 ; line 0 output
16
 
17
        .export ser1inchk               ; line 1 input check
18
        .export ser1in                  ; line 1 input
19
        .export ser1outchk              ; line 1 output check
20
        .export ser1out                 ; line 1 output
21
 
22
;***************************************************************
23
 
24
        .code
25
        .align  4
26
 
27
serinit:
28
        jr      $31
29
 
30
;***************************************************************
31
 
32
        .code
33
        .align  4
34
 
35
ser0inchk:
36
        add     $8,$0,ser0base
37
        ldw     $2,$8,0
38
        and     $2,$2,1
39
        jr      $31
40
 
41
ser0in:
42
        add     $8,$0,ser0base
43
ser0in1:
44
        ldw     $9,$8,0
45
        and     $9,$9,1
46
        beq     $9,$0,ser0in1
47
        ldw     $2,$8,4
48
        jr      $31
49
 
50
ser0outchk:
51
        add     $8,$0,ser0base
52
        ldw     $2,$8,8
53
        and     $2,$2,1
54
        jr      $31
55
 
56
ser0out:
57
        add     $8,$0,ser0base
58
ser0out1:
59
        ldw     $9,$8,8
60
        and     $9,$9,1
61
        beq     $9,$0,ser0out1
62
        stw     $4,$8,12
63
        jr      $31
64
 
65
;***************************************************************
66
 
67
        .code
68
        .align  4
69
 
70
ser1inchk:
71
        add     $8,$0,ser1base
72
        ldw     $2,$8,0
73
        and     $2,$2,1
74
        jr      $31
75
 
76
ser1in:
77
        add     $8,$0,ser1base
78
ser1in1:
79
        ldw     $9,$8,0
80
        and     $9,$9,1
81
        beq     $9,$0,ser1in1
82
        ldw     $2,$8,4
83
        jr      $31
84
 
85
ser1outchk:
86
        add     $8,$0,ser1base
87
        ldw     $2,$8,8
88
        and     $2,$2,1
89
        jr      $31
90
 
91
ser1out:
92
        add     $8,$0,ser1base
93
ser1out1:
94
        ldw     $9,$8,8
95
        and     $9,$9,1
96
        beq     $9,$0,ser1out1
97
        stw     $4,$8,12
98
        jr      $31

powered by: WebSVN 2.1.0

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