Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
X
x393
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
Elphel
x393
Commits
e6cbe171
Commit
e6cbe171
authored
Feb 02, 2015
by
Andrey Filippov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
continue on mcntrl393, fixing some bugs too
parent
94f77f4d
Changes
4
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
593 additions
and
200 deletions
+593
-200
mcntrl393.v
memctrl/mcntrl393.v
+538
-148
mcntrl_ps_pio.v
memctrl/mcntrl_ps_pio.v
+3
-3
memctrl16.v
memctrl/memctrl16.v
+42
-42
mcont_to_chnbuf_reg.v
util_modules/mcont_to_chnbuf_reg.v
+10
-7
No files found.
memctrl/mcntrl393.v
View file @
e6cbe171
This diff is collapsed.
Click to expand it.
memctrl/mcntrl_ps_pio.v
View file @
e6cbe171
...
@@ -22,9 +22,9 @@
...
@@ -22,9 +22,9 @@
`timescale
1
ns
/
1
ps
`timescale
1
ns
/
1
ps
module
mcntrl_ps_pio
#(
module
mcntrl_ps_pio
#(
parameter
MCNTRL_PS_ADDR
=
'h100
,
parameter
MCNTRL_PS_ADDR
=
'h100
,
parameter
MCNTRL_PS_MASK
=
'h3e0
,
// both channels 0 and 1
parameter
MCNTRL_PS_MASK
=
'h3e0
,
// both channels 0 and 1
parameter
MCNTRL_PS_STATUS_REG_ADDR
=
'h2
,
parameter
MCNTRL_PS_STATUS_REG_ADDR
=
'h2
,
parameter
MCNTRL_PS_EN_RST
=
'h0
,
parameter
MCNTRL_PS_EN_RST
=
'h0
,
parameter
MCNTRL_PS_CMD
=
'h1
,
parameter
MCNTRL_PS_CMD
=
'h1
,
parameter
MCNTRL_PS_STATUS_CNTRL
=
'h2
parameter
MCNTRL_PS_STATUS_CNTRL
=
'h2
...
...
memctrl/memctrl16.v
View file @
e6cbe171
This diff is collapsed.
Click to expand it.
util_modules/mcont_to_chnbuf_reg.v
View file @
e6cbe171
...
@@ -28,12 +28,12 @@ parameter CHN_NUMBER=0
...
@@ -28,12 +28,12 @@ parameter CHN_NUMBER=0
input
ext_buf_wr
,
input
ext_buf_wr
,
input
[
6
:
0
]
ext_buf_waddr
,
// valid with ext_buf_wr
input
[
6
:
0
]
ext_buf_waddr
,
// valid with ext_buf_wr
input
[
3
:
0
]
ext_buf_wchn
,
// ==run_chn_d valid 1 cycle ahead opf ext_buf_wr!, maybe not needed - will be generated externally
input
[
3
:
0
]
ext_buf_wchn
,
// ==run_chn_d valid 1 cycle ahead opf ext_buf_wr!, maybe not needed - will be generated externally
input
[
63
:
0
]
ext_buf_wdata
,
// valid with ext_buf_wr
input
[
63
:
0
]
ext_buf_wdata
,
// valid with ext_buf_wr
input
seq_done
,
// sequence done
input
seq_done
,
// sequence done
output
reg
buf_done
,
//
sequence done for the specified channel
output
reg
buf_done
,
// @ posedge mclk
sequence done for the specified channel
output
reg
buf_wr_chn
,
output
reg
buf_wr_chn
,
// @ negedge mclk
output
reg
[
6
:
0
]
buf_waddr_chn
,
output
reg
[
6
:
0
]
buf_waddr_chn
,
// @ negedge mclk
output
reg
[
63
:
0
]
buf_wdata_chn
output
reg
[
63
:
0
]
buf_wdata_chn
// @ negedge mclk
)
;
)
;
reg
buf_chn_sel
;
reg
buf_chn_sel
;
always
@
(
posedge
rst
or
negedge
clk
)
begin
always
@
(
posedge
rst
or
negedge
clk
)
begin
...
@@ -42,11 +42,14 @@ parameter CHN_NUMBER=0
...
@@ -42,11 +42,14 @@ parameter CHN_NUMBER=0
if
(
rst
)
buf_wr_chn
<=
0
;
if
(
rst
)
buf_wr_chn
<=
0
;
else
buf_wr_chn
<=
buf_chn_sel
&&
ext_buf_wr
;
else
buf_wr_chn
<=
buf_chn_sel
&&
ext_buf_wr
;
end
always
@
(
posedge
rst
or
posedge
clk
)
begin
if
(
rst
)
buf_done
<=
0
;
if
(
rst
)
buf_done
<=
0
;
else
buf_done
<=
buf_chn_sel
&&
seq_done
;
else
buf_done
<=
buf_chn_sel
&&
seq_done
;
end
end
always
@
(
negedge
clk
)
if
(
buf_chn_sel
&&
ext_buf_wr
)
begin
always
@
(
negedge
clk
)
if
(
buf_chn_sel
&&
ext_buf_wr
)
begin
buf_waddr_chn
<=
ext_buf_waddr
;
buf_waddr_chn
<=
ext_buf_waddr
;
buf_wdata_chn
<=
ext_buf_wdata
;
buf_wdata_chn
<=
ext_buf_wdata
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment