Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
H
HDL
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
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
RTSD
HDL
Commits
3c504fff
Commit
3c504fff
authored
3 years ago
by
Reinier van der Walle
Browse files
Options
Downloads
Patches
Plain Diff
Updated comment
parent
bbddaea4
No related branches found
Branches containing commit
No related tags found
2 merge requests
!100
Removed text for XSub that is now written in Confluence Subband correlator...
,
!88
Resolve L2SDP-288
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
libraries/dsp/st/src/vhdl/st_xsq.vhd
+16
-13
16 additions, 13 deletions
libraries/dsp/st/src/vhdl/st_xsq.vhd
libraries/dsp/st/tb/vhdl/tb_st_xsq.vhd
+25
-24
25 additions, 24 deletions
libraries/dsp/st/tb/vhdl/tb_st_xsq.vhd
with
41 additions
and
37 deletions
libraries/dsp/st/src/vhdl/st_xsq.vhd
+
16
−
13
View file @
3c504fff
...
@@ -19,11 +19,11 @@
...
@@ -19,11 +19,11 @@
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
-- Author : R. vd Walle
-- Author : R. vd Walle
-- Purpose:
-- Purpose:
-- Store the
(auto)power
statistics of
a
complex input stream with
-- Store the statistics of
the
complex input stream
s in_a and in_b
with
-- blocks of g_nof_crosslets * g_nof_signal_inputs**2 multiplexed subbands into a MM register.
-- blocks of g_nof_crosslets * g_nof_signal_inputs**2 multiplexed subbands into a MM register.
-- Description:
-- Description:
--
--
-- After each sync the MM register gets updated with the
(auto) power
statistics
-- After each sync the MM register gets updated with the statistics
-- of the previous sync interval. The length of the sync interval determines
-- of the previous sync interval. The length of the sync interval determines
-- the nof accumlations per statistic, hence the integration time. See st_calc
-- the nof accumlations per statistic, hence the integration time. See st_calc
-- for more details.
-- for more details.
...
@@ -35,7 +35,9 @@
...
@@ -35,7 +35,9 @@
-- Therefore it is not necessary to use a dual page register that swaps at
-- Therefore it is not necessary to use a dual page register that swaps at
-- the sync.
-- the sync.
-- . The minimum c_nof_statistics = 8. Lower values lead to simulation errors. This is
-- . The minimum c_nof_statistics = 8. Lower values lead to simulation errors. This is
-- due to the read latency of 2 of the accumulation memory in the st_calc entity.
-- due to the read latency of 2 of the accumulation memory in the st_calc entity.
-- . More detail can be found in:
-- https://support.astron.nl/confluence/display/L2M/L5+SDPFW+Design+Document%3A+Subband+Correlator
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
LIBRARY
IEEE
,
common_lib
,
mm_lib
,
technology_lib
,
dp_lib
;
LIBRARY
IEEE
,
common_lib
,
mm_lib
,
technology_lib
,
dp_lib
;
...
@@ -55,14 +57,14 @@ ENTITY st_xsq IS
...
@@ -55,14 +57,14 @@ ENTITY st_xsq IS
g_stat_data_sz
:
NATURAL
:
=
2
-- statistics word width >= statistics accumulator width and fit in a power of 2 multiple 32b MM words
g_stat_data_sz
:
NATURAL
:
=
2
-- statistics word width >= statistics accumulator width and fit in a power of 2 multiple 32b MM words
);
);
PORT
(
PORT
(
mm_rst
:
IN
STD_LOGIC
;
mm_rst
:
IN
STD_LOGIC
;
mm_clk
:
IN
STD_LOGIC
;
mm_clk
:
IN
STD_LOGIC
;
dp_rst
:
IN
STD_LOGIC
;
dp_rst
:
IN
STD_LOGIC
;
dp_clk
:
IN
STD_LOGIC
;
dp_clk
:
IN
STD_LOGIC
;
-- Streaming
-- Streaming
in_a
:
IN
t_dp_sosi
;
-- Complex input data
in_a
:
IN
t_dp_sosi
;
-- Complex input data
in_b
:
IN
t_dp_sosi
;
-- Complex input data
in_b
:
IN
t_dp_sosi
;
-- Complex input data
-- Memory Mapped
-- Memory Mapped
ram_st_xsq_mosi
:
IN
t_mem_mosi
:
=
c_mem_mosi_rst
;
ram_st_xsq_mosi
:
IN
t_mem_mosi
:
=
c_mem_mosi_rst
;
...
@@ -136,7 +138,9 @@ BEGIN
...
@@ -136,7 +138,9 @@ BEGIN
src_out
=>
pipe_in_b
src_out
=>
pipe_in_b
);
);
-- accumulators
---------------------------------------------------------------
-- st_calc
---------------------------------------------------------------
st_calc
:
ENTITY
work
.
st_calc
st_calc
:
ENTITY
work
.
st_calc
GENERIC
MAP
(
GENERIC
MAP
(
g_technology
=>
g_technology
,
g_technology
=>
g_technology
,
...
@@ -169,12 +173,11 @@ BEGIN
...
@@ -169,12 +173,11 @@ BEGIN
---------------------------------------------------------------
---------------------------------------------------------------
-- COMBINE MEMORY MAPPED INTERFACES
-- COMBINE MEMORY MAPPED INTERFACES
---------------------------------------------------------------
---------------------------------------------------------------
-- Translate incoming MM interface [
N_
crosslets][
S_p
n A][
S_p
n B][
N_
complex][word] to
-- Translate incoming MM interface [crosslets][
i
n A][
i
n B][complex][word] to
-- [
N_
complex][
N_
crosslets][
S_p
n A][
S_p
n B][word]
-- [complex][crosslets][
i
n A][
i
n B][word]
p_remap
:
PROCESS
(
ram_st_xsq_mosi
)
p_remap
:
PROCESS
(
ram_st_xsq_mosi
)
BEGIN
BEGIN
remapped_ram_st_xsq_mosi
<=
ram_st_xsq_mosi
;
remapped_ram_st_xsq_mosi
<=
ram_st_xsq_mosi
;
--
remapped_ram_st_xsq_mosi
.
address
(
c_total_ram_addr_w
-1
DOWNTO
c_nof_word_w
)
<=
ram_st_xsq_mosi
.
address
(
ceil_log2
(
c_nof_complex
)
+
ceil_log2
(
g_stat_data_sz
)
-1
DOWNTO
ceil_log2
(
g_stat_data_sz
));
remapped_ram_st_xsq_mosi
.
address
(
c_total_ram_addr_w
-1
DOWNTO
c_nof_word_w
)
<=
ram_st_xsq_mosi
.
address
(
ceil_log2
(
c_nof_complex
)
+
ceil_log2
(
g_stat_data_sz
)
-1
DOWNTO
ceil_log2
(
g_stat_data_sz
));
remapped_ram_st_xsq_mosi
.
address
(
c_nof_word_w
-1
DOWNTO
0
)
<=
ram_st_xsq_mosi
.
address
(
c_total_ram_addr_w
-1
DOWNTO
ceil_log2
(
c_nof_complex
)
+
ceil_log2
(
g_stat_data_sz
))
&
ram_st_xsq_mosi
.
address
(
ceil_log2
(
g_stat_data_sz
)
-1
DOWNTO
0
);
remapped_ram_st_xsq_mosi
.
address
(
c_nof_word_w
-1
DOWNTO
0
)
<=
ram_st_xsq_mosi
.
address
(
c_total_ram_addr_w
-1
DOWNTO
ceil_log2
(
c_nof_complex
)
+
ceil_log2
(
g_stat_data_sz
))
&
ram_st_xsq_mosi
.
address
(
ceil_log2
(
g_stat_data_sz
)
-1
DOWNTO
0
);
END
PROCESS
;
END
PROCESS
;
...
...
This diff is collapsed.
Click to expand it.
libraries/dsp/st/tb/vhdl/tb_st_xsq.vhd
+
25
−
24
View file @
3c504fff
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
--
--
-- Copyright
(C) 2012
-- Copyright
2021
-- ASTRON (Netherlands Institute for Radio Astronomy) <http://www.astron.nl/>
-- ASTRON (Netherlands Institute for Radio Astronomy) <http://www.astron.nl/>
-- P.O.Box 2, 7990 AA Dwingeloo, The Netherlands
-- P.O.Box 2, 7990 AA Dwingeloo, The Netherlands
--
--
-- This program is free software: you can redistribute it and/or modify
-- Licensed under the Apache License, Version 2.0 (the "License");
-- it under the terms of the GNU General Public License as published by
-- you may not use this file except in compliance with the License.
-- the Free Software Foundation, either version 3 of the License, or
-- You may obtain a copy of the License at
-- (at your option) any later version.
--
--
-- This program is distributed in the hope that it will be useful,
-- http://www.apache.org/licenses/LICENSE-2.0
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
--
-- You should have received a copy of the GNU General Public License
-- Unless required by applicable law or agreed to in writing, software
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
-- distributed under the License is distributed on an "AS IS" BASIS,
-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-- See the License for the specific language governing permissions and
-- limitations under the License.
--
--
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
--
-------------------------------------------------------------------------------
-- Author : R vd Walle
-- Purpose: Testbench for the st_xsq unit.
-- Purpose: Testbench for the st_xsq unit.
--
--
--
-- Usage in non-auto-mode (c_modelsim_start = 0 in python):
-- Usage in non-auto-mode (c_modelsim_start = 0 in python):
-- > as 5
-- > as 5
-- > run -all
-- > run -all
-- > Run python script in separate terminal: "python tc_mmf_st_xst.py --unb 0 --bn 0 --sim"
-- Description:
-- > Check the results of the python script.
-- The tb generates random data to feed into st_xsq. The output is compared to
-- > Stop the simulation manually in Modelsim by pressing the stop-button.
-- a pre-calculated expected array of xsq values.
-- > Evalute the WAVE window.
-- Remark:
-- . More detail can be found in:
-- https://support.astron.nl/confluence/display/L2M/L5+SDPFW+Design+Document%3A+Subband+Correlator
LIBRARY
IEEE
,
common_lib
,
mm_lib
,
diag_lib
,
dp_lib
;
LIBRARY
IEEE
,
common_lib
,
mm_lib
,
diag_lib
,
dp_lib
;
USE
IEEE
.
std_logic_1164
.
ALL
;
USE
IEEE
.
std_logic_1164
.
ALL
;
...
@@ -161,12 +162,12 @@ BEGIN
...
@@ -161,12 +162,12 @@ BEGIN
WAIT
;
WAIT
;
END
PROCESS
;
END
PROCESS
;
in_sosi_a
.
sync
<=
st_sosi
.
sync
;
in_sosi_a
.
sync
<=
st_sosi
.
sync
;
in_sosi_b
.
sync
<=
st_sosi
.
sync
;
in_sosi_b
.
sync
<=
st_sosi
.
sync
;
in_sosi_a
.
sop
<=
st_sosi
.
sop
;
in_sosi_a
.
sop
<=
st_sosi
.
sop
;
in_sosi_b
.
sop
<=
st_sosi
.
sop
;
in_sosi_b
.
sop
<=
st_sosi
.
sop
;
in_sosi_a
.
eop
<=
st_sosi
.
eop
;
in_sosi_a
.
eop
<=
st_sosi
.
eop
;
in_sosi_b
.
eop
<=
st_sosi
.
eop
;
in_sosi_b
.
eop
<=
st_sosi
.
eop
;
in_sosi_a
.
valid
<=
st_sosi
.
valid
;
in_sosi_a
.
valid
<=
st_sosi
.
valid
;
in_sosi_b
.
valid
<=
st_sosi
.
valid
;
in_sosi_b
.
valid
<=
st_sosi
.
valid
;
...
...
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