##// END OF EJS Templates
Update Sample transformation from ADC to IIR_FILTER
pellion -
r347:326fa6e96475 JC
parent child
Show More
@@ -127,6 +127,7 ARCHITECTURE beh OF LFR_em IS
127
127
128 -- AD Converter ADS7886
128 -- AD Converter ADS7886
129 SIGNAL sample : Samples14v(7 DOWNTO 0);
129 SIGNAL sample : Samples14v(7 DOWNTO 0);
130 SIGNAL sample_s : Samples(7 DOWNTO 0);
130 SIGNAL sample_val : STD_LOGIC;
131 SIGNAL sample_val : STD_LOGIC;
131 SIGNAL ADC_nCS_sig : STD_LOGIC;
132 SIGNAL ADC_nCS_sig : STD_LOGIC;
132 SIGNAL ADC_CLK_sig : STD_LOGIC;
133 SIGNAL ADC_CLK_sig : STD_LOGIC;
@@ -353,15 +354,15 BEGIN -- beh
353 pirq_ms => 6,
354 pirq_ms => 6,
354 pirq_wfp => 14,
355 pirq_wfp => 14,
355 hindex => 2,
356 hindex => 2,
356 top_lfr_version => X"00010A") -- aa.bb.cc version
357 top_lfr_version => X"00010B") -- aa.bb.cc version
357 -- AA : BOARD NUMBER
358 -- AA : BOARD NUMBER
358 -- 0 => MINI_LFR
359 -- 0 => MINI_LFR
359 -- 1 => EM
360 -- 1 => EM
360 PORT MAP (
361 PORT MAP (
361 clk => clk_25,
362 clk => clk_25,
362 rstn => rstn,
363 rstn => rstn,
363 sample_B => sample(2 DOWNTO 0),
364 sample_B => sample_s(2 DOWNTO 0),
364 sample_E => sample(7 DOWNTO 3),
365 sample_E => sample_s(7 DOWNTO 3),
365 sample_val => sample_val,
366 sample_val => sample_val,
366 apbi => apbi_ext,
367 apbi => apbi_ext,
367 apbo => apbo_ext(15),
368 apbo => apbo_ext(15),
@@ -372,6 +373,11 BEGIN -- beh
372 data_shaping_BW => bias_fail_sw,
373 data_shaping_BW => bias_fail_sw,
373 observation_reg => observation_reg);
374 observation_reg => observation_reg);
374
375
376
377 all_sample: FOR I IN 7 DOWNTO 0 GENERATE
378 sample_s(I) <= sample(I) & '0' & '0';
379 END GENERATE all_sample;
380
375 -----------------------------------------------------------------------------
381 -----------------------------------------------------------------------------
376 --
382 --
377 -----------------------------------------------------------------------------
383 -----------------------------------------------------------------------------
@@ -163,6 +163,7 ARCHITECTURE beh OF MINI_LFR_top IS
163
163
164 -- AD Converter ADS7886
164 -- AD Converter ADS7886
165 SIGNAL sample : Samples14v(7 DOWNTO 0);
165 SIGNAL sample : Samples14v(7 DOWNTO 0);
166 SIGNAL sample_s : Samples(7 DOWNTO 0);
166 SIGNAL sample_val : STD_LOGIC;
167 SIGNAL sample_val : STD_LOGIC;
167 SIGNAL ADC_nCS_sig : STD_LOGIC;
168 SIGNAL ADC_nCS_sig : STD_LOGIC;
168 SIGNAL ADC_CLK_sig : STD_LOGIC;
169 SIGNAL ADC_CLK_sig : STD_LOGIC;
@@ -429,8 +430,8 BEGIN -- beh
429 PORT MAP (
430 PORT MAP (
430 clk => clk_25,
431 clk => clk_25,
431 rstn => reset,
432 rstn => reset,
432 sample_B => sample(2 DOWNTO 0),
433 sample_B => sample_s(2 DOWNTO 0),
433 sample_E => sample(7 DOWNTO 3),
434 sample_E => sample_s(7 DOWNTO 3),
434 sample_val => sample_val,
435 sample_val => sample_val,
435 apbi => apbi_ext,
436 apbi => apbi_ext,
436 apbo => apbo_ext(15),
437 apbo => apbo_ext(15),
@@ -441,6 +442,12 BEGIN -- beh
441 data_shaping_BW => bias_fail_sw_sig,
442 data_shaping_BW => bias_fail_sw_sig,
442 observation_reg => observation_reg);
443 observation_reg => observation_reg);
443
444
445 all_sample: FOR I IN 7 DOWNTO 0 GENERATE
446 sample_s(I) <= sample(I) & '0' & '0';
447 END GENERATE all_sample;
448
449
450
444 top_ad_conv_ADS7886_v2_1 : top_ad_conv_ADS7886_v2
451 top_ad_conv_ADS7886_v2_1 : top_ad_conv_ADS7886_v2
445 GENERIC MAP(
452 GENERIC MAP(
446 ChannelCount => 8,
453 ChannelCount => 8,
@@ -46,8 +46,8 ENTITY lpp_lfr IS
46 clk : IN STD_LOGIC;
46 clk : IN STD_LOGIC;
47 rstn : IN STD_LOGIC;
47 rstn : IN STD_LOGIC;
48 -- SAMPLE
48 -- SAMPLE
49 sample_B : IN Samples14v(2 DOWNTO 0);
49 sample_B : IN Samples(2 DOWNTO 0);
50 sample_E : IN Samples14v(4 DOWNTO 0);
50 sample_E : IN Samples(4 DOWNTO 0);
51 sample_val : IN STD_LOGIC;
51 sample_val : IN STD_LOGIC;
52 -- APB
52 -- APB
53 apbi : IN apb_slv_in_type;
53 apbi : IN apb_slv_in_type;
@@ -106,7 +106,7 ENTITY lpp_lfr IS
106 END lpp_lfr;
106 END lpp_lfr;
107
107
108 ARCHITECTURE beh OF lpp_lfr IS
108 ARCHITECTURE beh OF lpp_lfr IS
109 SIGNAL sample : Samples14v(7 DOWNTO 0);
109 --SIGNAL sample : Samples14v(7 DOWNTO 0);
110 SIGNAL sample_s : Samples(7 DOWNTO 0);
110 SIGNAL sample_s : Samples(7 DOWNTO 0);
111 --
111 --
112 SIGNAL data_shaping_SP0 : STD_LOGIC;
112 SIGNAL data_shaping_SP0 : STD_LOGIC;
@@ -299,12 +299,12 ARCHITECTURE beh OF lpp_lfr IS
299
299
300 BEGIN
300 BEGIN
301
301
302 sample(4 DOWNTO 0) <= sample_E(4 DOWNTO 0);
302 sample_s(4 DOWNTO 0) <= sample_E(4 DOWNTO 0);
303 sample(7 DOWNTO 5) <= sample_B(2 DOWNTO 0);
303 sample_s(7 DOWNTO 5) <= sample_B(2 DOWNTO 0);
304
304
305 all_channel : FOR i IN 7 DOWNTO 0 GENERATE
305 --all_channel : FOR i IN 7 DOWNTO 0 GENERATE
306 sample_s(i) <= sample(i)(13) & sample(i)(13) & sample(i);
306 -- sample_s(i) <= sample(i)(13) & sample(i)(13) & sample(i);
307 END GENERATE all_channel;
307 --END GENERATE all_channel;
308
308
309 -----------------------------------------------------------------------------
309 -----------------------------------------------------------------------------
310 lpp_lfr_filter_1 : lpp_lfr_filter
310 lpp_lfr_filter_1 : lpp_lfr_filter
@@ -46,8 +46,8 ENTITY lpp_lfr_WFP_nMS IS
46 clk : IN STD_LOGIC;
46 clk : IN STD_LOGIC;
47 rstn : IN STD_LOGIC;
47 rstn : IN STD_LOGIC;
48 -- SAMPLE
48 -- SAMPLE
49 sample_B : IN Samples14v(2 DOWNTO 0);
49 sample_B : IN Samples(2 DOWNTO 0);
50 sample_E : IN Samples14v(4 DOWNTO 0);
50 sample_E : IN Samples(4 DOWNTO 0);
51 sample_val : IN STD_LOGIC;
51 sample_val : IN STD_LOGIC;
52 -- APB
52 -- APB
53 apbi : IN apb_slv_in_type;
53 apbi : IN apb_slv_in_type;
@@ -106,7 +106,7 ENTITY lpp_lfr_WFP_nMS IS
106 END lpp_lfr_WFP_nMS;
106 END lpp_lfr_WFP_nMS;
107
107
108 ARCHITECTURE beh OF lpp_lfr_WFP_nMS IS
108 ARCHITECTURE beh OF lpp_lfr_WFP_nMS IS
109 SIGNAL sample : Samples14v(7 DOWNTO 0);
109 -- SIGNAL sample : Samples14v(7 DOWNTO 0);
110 SIGNAL sample_s : Samples(7 DOWNTO 0);
110 SIGNAL sample_s : Samples(7 DOWNTO 0);
111 --
111 --
112 SIGNAL data_shaping_SP0 : STD_LOGIC;
112 SIGNAL data_shaping_SP0 : STD_LOGIC;
@@ -299,12 +299,13 ARCHITECTURE beh OF lpp_lfr_WFP_nMS IS
299
299
300 BEGIN
300 BEGIN
301
301
302 sample(4 DOWNTO 0) <= sample_E(4 DOWNTO 0);
302 sample_s(4 DOWNTO 0) <= sample_E(4 DOWNTO 0);
303 sample(7 DOWNTO 5) <= sample_B(2 DOWNTO 0);
303 sample_s(7 DOWNTO 5) <= sample_B(2 DOWNTO 0);
304
304
305 all_channel : FOR i IN 7 DOWNTO 0 GENERATE
305 --all_channel : FOR i IN 7 DOWNTO 0 GENERATE
306 sample_s(i) <= sample(i)(13) & sample(i)(13) & sample(i);
306 -- --sample_s(i) <= sample(i)(13) & sample(i)(13) & sample(i);
307 END GENERATE all_channel;
307 -- sample_s(i) <= sample(i) & '0' & '0';
308 --END GENERATE all_channel;
308
309
309 -----------------------------------------------------------------------------
310 -----------------------------------------------------------------------------
310 lpp_lfr_filter_1 : lpp_lfr_filter
311 lpp_lfr_filter_1 : lpp_lfr_filter
@@ -151,8 +151,8 PACKAGE lpp_lfr_pkg IS
151 PORT (
151 PORT (
152 clk : IN STD_LOGIC;
152 clk : IN STD_LOGIC;
153 rstn : IN STD_LOGIC;
153 rstn : IN STD_LOGIC;
154 sample_B : IN Samples14v(2 DOWNTO 0);
154 sample_B : IN Samples(2 DOWNTO 0);
155 sample_E : IN Samples14v(4 DOWNTO 0);
155 sample_E : IN Samples(4 DOWNTO 0);
156 sample_val : IN STD_LOGIC;
156 sample_val : IN STD_LOGIC;
157 apbi : IN apb_slv_in_type;
157 apbi : IN apb_slv_in_type;
158 apbo : OUT apb_slv_out_type;
158 apbo : OUT apb_slv_out_type;
@@ -186,8 +186,8 PACKAGE lpp_lfr_pkg IS
186 PORT (
186 PORT (
187 clk : IN STD_LOGIC;
187 clk : IN STD_LOGIC;
188 rstn : IN STD_LOGIC;
188 rstn : IN STD_LOGIC;
189 sample_B : IN Samples14v(2 DOWNTO 0);
189 sample_B : IN Samples(2 DOWNTO 0);
190 sample_E : IN Samples14v(4 DOWNTO 0);
190 sample_E : IN Samples(4 DOWNTO 0);
191 sample_val : IN STD_LOGIC;
191 sample_val : IN STD_LOGIC;
192 apbi : IN apb_slv_in_type;
192 apbi : IN apb_slv_in_type;
193 apbo : OUT apb_slv_out_type;
193 apbo : OUT apb_slv_out_type;
General Comments 0
You need to be logged in to leave comments. Login now