Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Killer
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Harbor Registry
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Vytor Calixto
Killer
Commits
6ac0e1cc
Commit
6ac0e1cc
authored
9 years ago
by
Israel Barreto Sant'Anna
Browse files
Options
Downloads
Patches
Plain Diff
Changed from lw/sw to lbu/sb the character read/write in handlerUART
Signed-off-by:
Israel B. Sant'Anna
<
ibsa14@inf.ufpr.br
>
parent
7e8c6aaa
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
cMIPS/tests/handlerUART.s
+8
-6
8 additions, 6 deletions
cMIPS/tests/handlerUART.s
with
8 additions
and
6 deletions
cMIPS/tests/handlerUART.s
+
8
−
6
View file @
6ac0e1cc
...
@@ -10,6 +10,8 @@ RX:
...
@@ -10,6 +10,8 @@ RX:
lw
$a1
,
48
(
$a0
)
#
Read
nrx
lw
$a1
,
48
(
$a0
)
#
Read
nrx
la
$
2
,
x_IO_BASE_ADDR
sw
$a1
,
0
(
$
2
)
#
Print
for
debug
addiu
$k1
,
$zero
,
16
addiu
$k1
,
$zero
,
16
slt
$k1
,
$a1
,
$k1
#
If
nrx
>=
16
the
queue
is
full
slt
$k1
,
$a1
,
$k1
#
If
nrx
>=
16
the
queue
is
full
...
@@ -28,13 +30,13 @@ RX:
...
@@ -28,13 +30,13 @@ RX:
lui
$a1
,
%
hi
(
HW_uart_addr
)
lui
$a1
,
%
hi
(
HW_uart_addr
)
ori
$a1
,
$a1
,
%
lo
(
HW_uart_addr
)
ori
$a1
,
$a1
,
%
lo
(
HW_uart_addr
)
l
w
$k1
,
4
(
$a1
)
#
Read
data
l
bu
$k1
,
4
(
$a1
)
#
Read
data
nop
nop
s
w
$k1
,
0
(
$a0
)
#
Put
data
on
RX_queue
tail
s
b
$k1
,
0
(
$a0
)
#
Put
data
on
RX_queue
tail
#
FIXME
:
Breaks
after
trying
to
save
second
character
on
rx_queue
la
$
2
,
x_IO_BASE_ADDR
la
$
2
,
x_IO_BASE_ADDR
sw
$k1
,
0
(
$
2
)
#
Print
for
debug
sw
$a0
,
0
(
$
2
)
#
Print
for
debug
TX
:
TX
:
...
@@ -61,11 +63,11 @@ TX:
...
@@ -61,11 +63,11 @@ TX:
addiu
$a1
,
$a1
,
24
#
tx_hd
position
on
tx_queue
addiu
$a1
,
$a1
,
24
#
tx_hd
position
on
tx_queue
add
$a0
,
$a1
,
$a0
#
tx_queue
head
address
add
$a0
,
$a1
,
$a0
#
tx_queue
head
address
l
w
$a1
,
0
(
$a0
)
#
Read
TX_queue
head
l
bu
$a1
,
0
(
$a0
)
#
Read
TX_queue
head
lui
$a0
,
%
hi
(
HW_uart_addr
)
lui
$a0
,
%
hi
(
HW_uart_addr
)
ori
$a0
,
$a0
,
%
lo
(
HW_uart_addr
)
ori
$a0
,
$a0
,
%
lo
(
HW_uart_addr
)
s
w
$a1
,
0
(
$a0
)
#
Put
data
on
UART
s
b
$a1
,
4
(
$a0
)
#
Put
data
on
UART
END
:
END
:
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment