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
f24ae228
Commit
f24ae228
authored
3 years ago
by
Eric Kooistra
Browse files
Options
Downloads
Patches
Plain Diff
Added c_exp_sub_a_ampl.
parent
678c4149
No related branches found
No related tags found
1 merge request
!231
Use applications/lofar2/model/pfs_coeff_final.m to create FIR coefficients for...
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
libraries/dsp/verify_pfb/tb_verify_pfb_wg.vhd
+9
-4
9 additions, 4 deletions
libraries/dsp/verify_pfb/tb_verify_pfb_wg.vhd
with
9 additions
and
4 deletions
libraries/dsp/verify_pfb/tb_verify_pfb_wg.vhd
+
9
−
4
View file @
f24ae228
...
@@ -239,9 +239,6 @@ ARCHITECTURE tb OF tb_verify_pfb_wg IS
...
@@ -239,9 +239,6 @@ ARCHITECTURE tb OF tb_verify_pfb_wg IS
CONSTANT
c_nof_channels
:
NATURAL
:
=
2
**
c_wpfb
.
nof_chan
;
-- = 2**0 = 1, so no time multiplexing of inputs
CONSTANT
c_nof_channels
:
NATURAL
:
=
2
**
c_wpfb
.
nof_chan
;
-- = 2**0 = 1, so no time multiplexing of inputs
CONSTANT
c_nof_sync
:
NATURAL
:
=
5
;
-- nof sync intervals to simulate
CONSTANT
c_nof_sync
:
NATURAL
:
=
5
;
-- nof sync intervals to simulate
-- Expected subband amplitude gain relative to input WG amplitude -1 for divide by 2 in two real input separate (Ampl --> Ampl/2)
CONSTANT
c_pfb_sub_scaling
:
REAL
:
=
2
.
0
**
REAL
((
g_fft_out_dat_w
+
g_fft_out_gain_w
)
-
(
g_fil_in_dat_w
+
g_fil_backoff_w
)
-
1
);
-- Subband at WG frequency
-- Subband at WG frequency
CONSTANT
c_bin_a
:
NATURAL
:
=
NATURAL
(
FLOOR
(
g_subband_index_a
));
CONSTANT
c_bin_a
:
NATURAL
:
=
NATURAL
(
FLOOR
(
g_subband_index_a
));
CONSTANT
c_bin_a_frac_en
:
BOOLEAN
:
=
g_subband_index_a
>
REAL
(
c_bin_a
);
CONSTANT
c_bin_a_frac_en
:
BOOLEAN
:
=
g_subband_index_a
>
REAL
(
c_bin_a
);
...
@@ -277,7 +274,13 @@ ARCHITECTURE tb OF tb_verify_pfb_wg IS
...
@@ -277,7 +274,13 @@ ARCHITECTURE tb OF tb_verify_pfb_wg IS
-- subband index / c_N_fft = 64 / 1024 = 1/16
-- subband index / c_N_fft = 64 / 1024 = 1/16
-- SST
-- SST
-- Expected subband amplitude gain relative to input WG amplitude -1 for divide by 2 in two real input separate (Ampl --> Ampl/2)
-- . assume fir_filter_dc_gain ~= 1.0, like with c_wpfb_lofar1_fir_filter_dc_gain 0.994817
CONSTANT
c_pfb_sub_scaling
:
REAL
:
=
func_wpfb_subband_gain
(
c_wpfb
);
CONSTANT
c_exp_sub_a_ampl
:
REAL
:
=
c_wg_ampl_a
*
c_pfb_sub_scaling
;
CONSTANT
c_exp_sub_b_ampl
:
REAL
:
=
c_wg_ampl_a
*
c_pfb_sub_scaling
;
-- TB
-- TB
SIGNAL
bs_end
:
STD_LOGIC
:
=
'0'
;
SIGNAL
bs_end
:
STD_LOGIC
:
=
'0'
;
SIGNAL
tb_end
:
STD_LOGIC
:
=
'0'
;
SIGNAL
tb_end
:
STD_LOGIC
:
=
'0'
;
...
@@ -1017,6 +1020,7 @@ BEGIN
...
@@ -1017,6 +1020,7 @@ BEGIN
print_str
(
". sub_a_re = "
&
int_to_str
(
sub_a_re
));
print_str
(
". sub_a_re = "
&
int_to_str
(
sub_a_re
));
print_str
(
". sub_a_im = "
&
int_to_str
(
sub_a_im
));
print_str
(
". sub_a_im = "
&
int_to_str
(
sub_a_im
));
print_str
(
". sub_a_ampl = "
&
real_to_str
(
sub_a_ampl
,
10
,
3
));
print_str
(
". sub_a_ampl = "
&
real_to_str
(
sub_a_ampl
,
10
,
3
));
print_str
(
". sub_a_ampl/c_exp_sub_a_ampl = "
&
real_to_str
(
sub_a_ampl
/
c_exp_sub_a_ampl
,
10
,
6
));
print_str
(
". sub_a_re_frac = "
&
int_to_str
(
sub_a_re_frac
));
print_str
(
". sub_a_re_frac = "
&
int_to_str
(
sub_a_re_frac
));
print_str
(
". sub_a_im_frac = "
&
int_to_str
(
sub_a_im_frac
));
print_str
(
". sub_a_im_frac = "
&
int_to_str
(
sub_a_im_frac
));
print_str
(
". sub_a_ampl_frac = "
&
real_to_str
(
sub_a_ampl_frac
,
10
,
3
));
print_str
(
". sub_a_ampl_frac = "
&
real_to_str
(
sub_a_ampl_frac
,
10
,
3
));
...
@@ -1060,6 +1064,7 @@ BEGIN
...
@@ -1060,6 +1064,7 @@ BEGIN
print_str
(
". sub_b_re = "
&
int_to_str
(
sub_b_re
));
print_str
(
". sub_b_re = "
&
int_to_str
(
sub_b_re
));
print_str
(
". sub_b_im = "
&
int_to_str
(
sub_b_im
));
print_str
(
". sub_b_im = "
&
int_to_str
(
sub_b_im
));
print_str
(
". sub_b_ampl = "
&
real_to_str
(
sub_b_ampl
,
10
,
3
));
print_str
(
". sub_b_ampl = "
&
real_to_str
(
sub_b_ampl
,
10
,
3
));
print_str
(
". sub_b_ampl/c_exp_sub_b_ampl = "
&
real_to_str
(
sub_b_ampl
/
c_exp_sub_b_ampl
,
10
,
6
));
print_str
(
". sub_b_re_frac = "
&
int_to_str
(
sub_b_re_frac
));
print_str
(
". sub_b_re_frac = "
&
int_to_str
(
sub_b_re_frac
));
print_str
(
". sub_b_im_frac = "
&
int_to_str
(
sub_b_im_frac
));
print_str
(
". sub_b_im_frac = "
&
int_to_str
(
sub_b_im_frac
));
print_str
(
". sub_b_ampl_frac = "
&
real_to_str
(
sub_b_ampl_frac
,
10
,
3
));
print_str
(
". sub_b_ampl_frac = "
&
real_to_str
(
sub_b_ampl_frac
,
10
,
3
));
...
...
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