Skip to content
Snippets Groups Projects
Commit bbc8f383 authored by Reinier van der Walle's avatar Reinier van der Walle
Browse files

added restart mechanism to local oscillator to start at BSN = 0 (or any

even BSN)
parent 506deee1
No related branches found
No related tags found
2 merge requests!277Resolve DIST2-2,!276Resolve DISTURB-2
Pipeline #32786 passed
...@@ -112,7 +112,7 @@ ARCHITECTURE tb OF tb_disturb2_unb2b_station_fsub IS ...@@ -112,7 +112,7 @@ ARCHITECTURE tb OF tb_disturb2_unb2b_station_fsub IS
CONSTANT c_hi_factor : REAL := 1.0 + c_percentage; -- higher boundary CONSTANT c_hi_factor : REAL := 1.0 + c_percentage; -- higher boundary
-- WG -- WG
CONSTANT c_bsn_start_wg : NATURAL := c_init_bsn + 2; -- start WG at this BSN to instead of some BSN, to avoid mismatches in exact expected data values CONSTANT c_bsn_start_wg : NATURAL := c_init_bsn + 3; -- start WG at this BSN to instead of some BSN, to avoid mismatches in exact expected data values
-- .ampl -- .ampl
CONSTANT c_wg_ampl : NATURAL := NATURAL(g_wg_ampl * REAL(c_disturb_FS_adc)); -- in number of lsb CONSTANT c_wg_ampl : NATURAL := NATURAL(g_wg_ampl * REAL(c_disturb_FS_adc)); -- in number of lsb
CONSTANT c_exp_sp_power : REAL := REAL(c_wg_ampl**2) / 2.0; CONSTANT c_exp_sp_power : REAL := REAL(c_wg_ampl**2) / 2.0;
...@@ -347,10 +347,15 @@ BEGIN ...@@ -347,10 +347,15 @@ BEGIN
-- 3 : ampl[16:0] -- 3 : ampl[16:0]
v_offset := g_sp * c_mm_span_reg_diag_wg; v_offset := g_sp * c_mm_span_reg_diag_wg;
mmf_mm_bus_wr(c_mm_file_reg_diag_wg, v_offset + 0, 1024*2**16 + 1, tb_clk); -- nof_samples, mode calc mmf_mm_bus_wr(c_mm_file_reg_diag_wg, v_offset + 0, 1024*2**16 + 1, tb_clk); -- nof_samples, mode calc
mmf_mm_bus_wr(c_mm_file_reg_diag_wg, v_offset + 1, INTEGER(c_wg_phase * c_diag_wg_phase_unit), tb_clk); -- phase offset in degrees --mmf_mm_bus_wr(c_mm_file_reg_diag_wg, v_offset + 1, INTEGER(c_wg_phase * c_diag_wg_phase_unit), tb_clk); -- phase offset in degrees
mmf_mm_bus_wr(c_mm_file_reg_diag_wg, v_offset + 1, 0, tb_clk); -- phase offset in degrees
mmf_mm_bus_wr(c_mm_file_reg_diag_wg, v_offset + 2, INTEGER(REAL(g_subband) * c_disturb_wg_subband_freq_unit), tb_clk); -- freq mmf_mm_bus_wr(c_mm_file_reg_diag_wg, v_offset + 2, INTEGER(REAL(g_subband) * c_disturb_wg_subband_freq_unit), tb_clk); -- freq
mmf_mm_bus_wr(c_mm_file_reg_diag_wg, v_offset + 3, INTEGER(REAL(c_wg_ampl) * c_disturb_wg_ampl_lsb), tb_clk); -- ampl mmf_mm_bus_wr(c_mm_file_reg_diag_wg, v_offset + 3, INTEGER(REAL(c_wg_ampl) * c_disturb_wg_ampl_lsb), tb_clk); -- ampl
mmf_mm_bus_wr(c_mm_file_reg_diag_wg, v_offset + 4, 1024*2**16 + 1, tb_clk); -- nof_samples, mode calc
--mmf_mm_bus_wr(c_mm_file_reg_diag_wg, v_offset + 5, INTEGER((c_wg_phase + 360.0 * REAL(c_wg_latency) * 0.5 / REAL(c_disturb_N_fft)) * c_diag_wg_phase_unit), tb_clk); -- phase offset in degrees
mmf_mm_bus_wr(c_mm_file_reg_diag_wg, v_offset + 5, 0, tb_clk); -- phase offset in degrees
mmf_mm_bus_wr(c_mm_file_reg_diag_wg, v_offset + 6, INTEGER((REAL(g_subband) - 0.5) * c_disturb_wg_subband_freq_unit), tb_clk); -- freq
mmf_mm_bus_wr(c_mm_file_reg_diag_wg, v_offset + 7, INTEGER(REAL(c_wg_ampl) * c_disturb_wg_ampl_lsb), tb_clk); -- ampl
-- Read current BSN -- Read current BSN
mmf_mm_bus_rd(c_mm_file_reg_bsn_scheduler_wg, 0, current_bsn_wg(31 DOWNTO 0), tb_clk); mmf_mm_bus_rd(c_mm_file_reg_bsn_scheduler_wg, 0, current_bsn_wg(31 DOWNTO 0), tb_clk);
mmf_mm_bus_rd(c_mm_file_reg_bsn_scheduler_wg, 1, current_bsn_wg(63 DOWNTO 32), tb_clk); mmf_mm_bus_rd(c_mm_file_reg_bsn_scheduler_wg, 1, current_bsn_wg(63 DOWNTO 32), tb_clk);
......
...@@ -118,6 +118,7 @@ ARCHITECTURE str OF node_disturb_oversampled_filterbank IS ...@@ -118,6 +118,7 @@ ARCHITECTURE str OF node_disturb_oversampled_filterbank IS
CONSTANT c_buf_file : STRING := "data/freq_shift_half_subband_2048x16_im_re.hex"; CONSTANT c_buf_file : STRING := "data/freq_shift_half_subband_2048x16_im_re.hex";
CONSTANT c_wg_ctrl : t_diag_wg := (TO_UVEC(c_diag_wg_mode_repeat, c_diag_wg_mode_w), TO_UVEC(c_buf.nof_dat, c_diag_wg_nofsamples_w), (OTHERS => '0'), (OTHERS => '0'), (OTHERS => '0')); CONSTANT c_wg_ctrl : t_diag_wg := (TO_UVEC(c_diag_wg_mode_repeat, c_diag_wg_mode_w), TO_UVEC(c_buf.nof_dat, c_diag_wg_nofsamples_w), (OTHERS => '0'), (OTHERS => '0'), (OTHERS => '0'));
CONSTANT c_wg_phase_offset : NATURAL := 6; -- Compensate for WG start latency. In nof samples.
CONSTANT c_fil_coefs_mem_addr_w : NATURAL := ceil_log2(c_disturb_N_fft * c_disturb_N_taps); CONSTANT c_fil_coefs_mem_addr_w : NATURAL := ceil_log2(c_disturb_N_fft * c_disturb_N_taps);
...@@ -139,6 +140,7 @@ ARCHITECTURE str OF node_disturb_oversampled_filterbank IS ...@@ -139,6 +140,7 @@ ARCHITECTURE str OF node_disturb_oversampled_filterbank IS
SIGNAL wg_rddata : STD_LOGIC_VECTOR(c_buf.dat_w -1 DOWNTO 0); SIGNAL wg_rddata : STD_LOGIC_VECTOR(c_buf.dat_w -1 DOWNTO 0);
SIGNAL wg_rdval : STD_LOGIC; SIGNAL wg_rdval : STD_LOGIC;
SIGNAL wg_address : STD_LOGIC_VECTOR(c_buf.adr_w -1 DOWNTO 0); SIGNAL wg_address : STD_LOGIC_VECTOR(c_buf.adr_w -1 DOWNTO 0);
SIGNAL wg_rom_address : STD_LOGIC_VECTOR(c_buf.adr_w -1 DOWNTO 0);
SIGNAL wg_rd : STD_LOGIC; SIGNAL wg_rd : STD_LOGIC;
SIGNAL wg_out_dat : STD_LOGIC_VECTOR(c_buf.dat_w -1 DOWNTO 0); SIGNAL wg_out_dat : STD_LOGIC_VECTOR(c_buf.dat_w -1 DOWNTO 0);
...@@ -168,6 +170,8 @@ ARCHITECTURE str OF node_disturb_oversampled_filterbank IS ...@@ -168,6 +170,8 @@ ARCHITECTURE str OF node_disturb_oversampled_filterbank IS
SIGNAL selector_en : STD_LOGIC; SIGNAL selector_en : STD_LOGIC;
SIGNAL weighted_subbands_flag : STD_LOGIC; SIGNAL weighted_subbands_flag : STD_LOGIC;
SIGNAL dp_bsn_source_restart_pipe : STD_LOGIC; SIGNAL dp_bsn_source_restart_pipe : STD_LOGIC;
SIGNAL dp_bsn_source_restart_delayed : STD_LOGIC;
SIGNAL dp_bsn_source_restart_wg : STD_LOGIC;
SIGNAL dp_bsn_source_restart_pipe_complex : STD_LOGIC; SIGNAL dp_bsn_source_restart_pipe_complex : STD_LOGIC;
BEGIN BEGIN
--------------------------------------------------------------- ---------------------------------------------------------------
...@@ -265,17 +269,35 @@ BEGIN ...@@ -265,17 +269,35 @@ BEGIN
rd_dat => wg_rddata rd_dat => wg_rddata
); );
-- Waveform generator -- Waveform generator as local oscillator.
u_wg : ENTITY diag_lib.diag_wg p_lo_restart : PROCESS(dp_clk, dp_rst)
BEGIN
IF rising_edge(dp_clk) THEN
dp_bsn_source_restart_wg <= '0';
IF dp_rst = '1' THEN
dp_bsn_source_restart_delayed <= '0';
ELSIF si_sosi_arr(0).sop = '1' THEN
dp_bsn_source_restart_delayed <= dp_bsn_source_restart_pipe;
IF dp_bsn_source_restart_pipe = '1' AND si_sosi_arr(0).bsn(0) = '0' THEN -- even bsn, start now.
dp_bsn_source_restart_wg <= '1';
ELSE -- Odd bsn, start 1 block later.
dp_bsn_source_restart_wg <= dp_bsn_source_restart_delayed;
END IF;
END IF;
END IF;
END PROCESS;
u_lo_wg : ENTITY diag_lib.diag_wg
GENERIC MAP ( GENERIC MAP (
g_buf_dat_w => c_buf.dat_w, g_buf_dat_w => c_buf.dat_w,
g_buf_addr_w => c_buf.adr_w, g_buf_addr_w => c_buf.adr_w,
g_rate_offset => c_wg_phase_offset,
g_calc_support => FALSE g_calc_support => FALSE
) )
PORT MAP ( PORT MAP (
rst => dp_rst, rst => dp_rst,
clk => dp_clk, clk => dp_clk,
restart => dp_bsn_source_restart_pipe, restart => dp_bsn_source_restart_wg,
buf_rddat => wg_rddata, buf_rddat => wg_rddata,
buf_rdval => wg_rdval, buf_rdval => wg_rdval,
......
%% Cell type:markdown id:ceaadd7c tags: %% Cell type:markdown id:ceaadd7c tags:
Copyright 2022 Copyright 2022
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
Licensed under the Apache License, Version 2.0 (the "License"); Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License. you may not use this file except in compliance with the License.
You may obtain a copy of the License at You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0 http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS, distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and See the License for the specific language governing permissions and
limitations under the License. limitations under the License.
-------------------------------------------------------------------------------- --------------------------------------------------------------------------------
Author: R vd Walle Author: R vd Walle
Purpose: Simulate the principle of the DISTURB2 filterbank firmware Purpose: Simulate the principle of the DISTURB2 filterbank firmware
Description: Generate an input signal containing 2 sine waves with frequencies Description: Generate an input signal containing 2 sine waves with frequencies
at the center frequency of subband 50 and subband 50.5. This demonstrates how at the center frequency of subband 50 and subband 50.5. This demonstrates how
the two FFT results from a normal FFT and the FFT of a frequency shifted (by the two FFT results from a normal FFT and the FFT of a frequency shifted (by
half a subband) input show that both are not ideal. Thereafter, the two FFT half a subband) input show that both are not ideal. Thereafter, the two FFT
results are combined to generate the ideal output. This is done by first results are combined to generate the ideal output. This is done by first
performing FFT's on each subband using 16 samples to create channels. Then performing FFT's on each subband using 16 samples to create channels. Then
the channels are combined by using the middle 8 channels of each subband the channels are combined by using the middle 8 channels of each subband
interleaving the channels from the normal FFT and the shifted FFT. interleaving the channels from the normal FFT and the shifted FFT.
%% Cell type:code id:bc607828 tags: %% Cell type:code id:bc607828 tags:
``` python ``` python
# System imports # System imports
import numpy as np import numpy as np
from scipy import signal from scipy import signal
import matplotlib import matplotlib
import matplotlib.pyplot as plt import matplotlib.pyplot as plt
from tools import * from tools import *
from common import * from common import *
``` ```
%% Cell type:code id:9b0dea9f tags: %% Cell type:code id:9b0dea9f tags:
``` python ``` python
# Constants # Constants
N_sub = 512 N_sub = 512
N_wg_samples = 4 * N_sub N_wg_samples = 4 * N_sub
sample_freq = 200000000 sample_freq = 200000000
shift_freq = 0.5 * ((sample_freq/2 ) / N_sub) # half a subband shift_freq = 0.5 * ((sample_freq/2 ) / N_sub) # half a subband
N_sample = 2 * N_sub N_sample = 2 * N_sub
N_blocks = 16 # Also number of channels per subband N_blocks = 16 # Also number of channels per subband
wg_sub = 50.5 wg_sub = 50.5
wg_sub_n = 50.0 wg_sub_n = 50
wg_freq = wg_sub * ((sample_freq/2) / N_sub) wg_freq = wg_sub * ((sample_freq/2) / N_sub)
wg_freq_n = wg_sub_n * ((sample_freq/2) / N_sub) wg_freq_n = wg_sub_n * ((sample_freq/2) / N_sub)
wg_ampl = 1.0 wg_ampl = 1.0
# Frequency shifting signal # Frequency shifting signal
n_array = np.arange(0, N_wg_samples, 1) n_array = np.arange(0, N_wg_samples, 1)
pow_array = [complex(0,1) * 2 * np.pi * (shift_freq / sample_freq) * n for n in n_array] pow_array = [complex(0,1) * 2 * np.pi * (shift_freq / sample_freq) * n for n in n_array]
nof_rep = ceil_div(N_blocks*N_sample, N_wg_samples) nof_rep = ceil_div(N_blocks*N_sample, N_wg_samples)
exp_array = np.tile([np.exp(w) for w in pow_array], nof_rep) # y[n] = e^(j * 2Pi * (f/Fs) * n) exp_array = np.tile([np.exp(w) for w in pow_array], nof_rep) # y[n] = e^(j * 2Pi * (f/Fs) * n)
#rotate exp_array
#rot = N_wg_samples // 2
#print(exp_array)
#exp_array = np.array(list(exp_array[rot:]) + list(exp_array[:rot]))
#print(exp_array)
# At what intervals time points are sampled # At what intervals time points are sampled
samplingInterval = 1 / sample_freq; samplingInterval = 1 / sample_freq;
# Begin time period of the signals # Begin time period of the signals
beginTime = 0; beginTime = 0;
# End time period of the signals # End time period of the signals
endTime = N_blocks * N_sample * samplingInterval; endTime = N_blocks * N_sample * samplingInterval;
# Time points # Time points
time = np.arange(beginTime, endTime, samplingInterval); time = np.arange(beginTime, endTime, samplingInterval);
# Create input signal # Create input signal
amplitude = np.sin(2*np.pi*wg_freq*time) + np.sin(2*np.pi*wg_freq_n*time) amplitude = np.sin(2*np.pi*wg_freq*time) + np.sin(2*np.pi*wg_freq_n*time)
spr_blocks = [amplitude[i * N_sample : (i+1) * N_sample] for i in range(N_blocks)] spr_blocks = [amplitude[i * N_sample : (i+1) * N_sample] for i in range(N_blocks)]
# Shifted signal # Shifted signal
amplitude_shft = amplitude * exp_array[0:len(time)] amplitude_shft = amplitude * exp_array[0:len(time)]
spc_blocks = [amplitude_shft[i * N_sample : (i+1) * N_sample] for i in range(N_blocks)] spc_blocks = [amplitude_shft[i * N_sample : (i+1) * N_sample] for i in range(N_blocks)]
# Bin indices for input/shifted signal # Bin indices for input/shifted signal
freq = np.fft.fftfreq(np.arange(N_sample).shape[-1], samplingInterval) freq = np.fft.fftfreq(np.arange(N_sample).shape[-1], samplingInterval)
subbands = [f/(shift_freq*2) for f in freq] subbands = [f/(shift_freq*2) for f in freq]
# Channel indices. # Channel indices.
freq_ch = np.fft.fftfreq(np.arange(N_blocks*N_sample).shape[-1], samplingInterval) freq_ch = np.fft.fftfreq(np.arange(N_blocks*N_sample).shape[-1], samplingInterval)
channels = [f/(shift_freq*2) for f in freq_ch] channels = [f/(shift_freq*2) for f in freq_ch]
channels = channels[0:len(channels) // 2:] # Only positive part is used. channels = channels[0:len(channels) // 2:] # Only positive part is used.
``` ```
%% Output
[1. +0.j 0.99999529+0.00306796j 0.99998118+0.00613588j ...
0.99995764-0.00920375j 0.99998118-0.00613588j 0.99999529-0.00306796j]
%% Cell type:code id:ae0fdaf0 tags: %% Cell type:code id:ae0fdaf0 tags:
``` python ``` python
# FFT of every block # FFT of every block
spr = [np.fft.fft(spr_block) for spr_block in spr_blocks] spr = [np.fft.fft(spr_block) for spr_block in spr_blocks]
# spr contains [blocks (N_blocks)][subbands (N_sample)] # spr contains [blocks (N_blocks)][subbands (N_sample)]
# We only need the positive part of the FFT and we need it in order [subbands][blocks] for channels # We only need the positive part of the FFT and we need it in order [subbands][blocks] for channels
sprT = [x[:N_sub] for x in spr] # Take positive part, like we receive from the FPGA. sprT = [x[:N_sub] for x in spr] # Take positive part, like we receive from the FPGA.
sprT = np.transpose(np.array(sprT)) # transpose sprT = np.transpose(np.array(sprT)) # transpose
# FFT of every subband, creating channels. # FFT of every subband, creating channels.
spr_ch = np.array([np.fft.fftshift(np.fft.fft(band)) for band in sprT]) spr_ch = np.array([np.fft.fftshift(np.fft.fft(band)) for band in sprT])
# The same for the shifted subbands # The same for the shifted subbands
spc = [np.fft.fft(spc_block) for spc_block in spc_blocks] spc = [np.fft.fft(spc_block) for spc_block in spc_blocks]
spcT = [x[:N_sub] for x in spc] spcT = [x[:N_sub] for x in spc]
spcT = np.transpose(np.array(spcT)) spcT = np.transpose(np.array(spcT))
spc_ch = np.array([np.fft.fftshift(np.fft.fft(band)) for band in spcT]) spc_ch = np.array([np.fft.fftshift(np.fft.fft(band)) for band in spcT])
# Combine the channels. # Combine the channels.
combined = [0] * N_blocks * N_sub combined = [0] * N_blocks * N_sub
for i in range(N_sub): for i in range(N_sub):
# for N_blocks = number of channels per subband = 16 # for N_blocks = number of channels per subband = 16
#0:8 = spr_ch[0][4:12] #0:8 = spr_ch[0][4:12]
#8:16 = spc_ch[0][4:12] #8:16 = spc_ch[0][4:12]
#16:24 = spr_ch[1][4:12] #16:24 = spr_ch[1][4:12]
#24:32 = spc_ch[1][4:12] #24:32 = spc_ch[1][4:12]
# ... # ...
n_ch = N_blocks // 2 n_ch = N_blocks // 2
combined[ 2 * i * n_ch : (2 * i + 1) * n_ch] = spc_ch[i][n_ch // 2 : n_ch + (n_ch // 2)] combined[ 2 * i * n_ch : (2 * i + 1) * n_ch] = spc_ch[i][n_ch // 2 : n_ch + (n_ch // 2)]
combined[(2 * i + 1) * n_ch : (2 * i + 2) * n_ch] = spr_ch[i][n_ch // 2 : n_ch + (n_ch // 2)] combined[(2 * i + 1) * n_ch : (2 * i + 2) * n_ch] = spr_ch[i][n_ch // 2 : n_ch + (n_ch // 2)]
# shift 3/4 subband to 0 # shift 3/4 subband to 0
combined = np.array(combined) combined = np.array(combined)
combined = combined[(3 * N_blocks // 4):] combined = combined[(3 * N_blocks // 4):]
combined = np.append(combined, spc_ch[N_sub-1][N_blocks // 4:]) combined = np.append(combined, spc_ch[N_sub-1][N_blocks // 4:])
``` ```
%% Cell type:code id:70cfb6c9 tags: %% Cell type:code id:70cfb6c9 tags:
``` python ``` python
# Create subplot # Create subplot
figure, axis = plt.subplots(5, 1, figsize=(15,20)) figure, axis = plt.subplots(5, 1, figsize=(15,20))
plt.subplots_adjust(hspace=1) plt.subplots_adjust(hspace=1)
windowRange = [48, 54] windowRange = [48, 54]
# Time domain representation of the input signal # Time domain representation of the input signal
axis[0].set_title('ADC input signal') axis[0].set_title('ADC input signal')
axis[0].plot(time, amplitude) axis[0].plot(time, amplitude)
axis[0].set_xlabel('Time') axis[0].set_xlabel('Time')
axis[0].set_ylabel('Amplitude') axis[0].set_ylabel('Amplitude')
# Time domain representation of the frequency shifted signal # Time domain representation of the frequency shifted signal
axis[1].set_title('Shifted input') axis[1].set_title('Shifted input')
axis[1].plot(time, amplitude_shft.real, time, amplitude_shft.imag) axis[1].plot(time, amplitude_shft.real, time, amplitude_shft.imag)
axis[1].set_xlabel('Time') axis[1].set_xlabel('Time')
axis[1].set_ylabel('Amplitude') axis[1].set_ylabel('Amplitude')
# Frequency domain representation of input signal # Frequency domain representation of input signal
x = subbands[windowRange[0]:windowRange[1]] x = subbands[windowRange[0]:windowRange[1]]
y = spr[0][windowRange[0]:windowRange[1]] y = spr[0][windowRange[0]:windowRange[1]]
axis[2].set_title('Fourier transform of ADC input') axis[2].set_title('Fourier transform of ADC input')
axis[2].plot(x, y.real, x, y.imag) axis[2].plot(x, y.real, x, y.imag)
axis[2].set_xlabel('Subband') axis[2].set_xlabel('Subband')
axis[2].set_ylabel('Amplitude') axis[2].set_ylabel('Amplitude')
# Frequency domain representation of frequency shifted signal # Frequency domain representation of frequency shifted signal
x = subbands[windowRange[0]:windowRange[1]] x = subbands[windowRange[0]:windowRange[1]]
y = spc[0][windowRange[0]:windowRange[1]] y = spc[0][windowRange[0]:windowRange[1]]
axis[3].set_title('Fourier transform of shifted input') axis[3].set_title('Fourier transform of shifted input')
axis[3].plot(x, y.real, x, y.imag) axis[3].plot(x, y.real, x, y.imag)
axis[3].set_xlabel('Subband') axis[3].set_xlabel('Subband')
axis[3].set_ylabel('Amplitude') axis[3].set_ylabel('Amplitude')
x = channels[N_blocks * windowRange[0]:N_blocks * windowRange[1]] x = channels[N_blocks * windowRange[0]:N_blocks * windowRange[1]]
y = combined[N_blocks * windowRange[0]:N_blocks * windowRange[1]] y = combined[N_blocks * windowRange[0]:N_blocks * windowRange[1]]
# Frequency domain representation of combined channels # Frequency domain representation of combined channels
axis[4].set_title('Fourier transform of combined') axis[4].set_title('Fourier transform of combined')
axis[4].plot(x, y.real, x, y.imag) axis[4].plot(x, y.real, x, y.imag)
axis[4].set_xlabel('Subband') axis[4].set_xlabel('Subband')
axis[4].set_ylabel('Amplitude') axis[4].set_ylabel('Amplitude')
plt.show() plt.show()
``` ```
%% Output %% Output
%% Cell type:code id:52b7ccb0 tags:
``` python
```
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment