Archived
1
0

add square signal

This commit is contained in:
2024-02-27 11:23:54 +01:00
parent 95e3c95a06
commit eb5a3d3a2a
29 changed files with 11560 additions and 511 deletions

View File

@ -0,0 +1,15 @@
-- VHDL Entity WaveformGenerator_test.waveformGen_tb.symbol
--
-- Created:
-- by - francois.corthay.UNKNOWN (WEA30906)
-- at - 14:48:16 25.02.2019
--
-- Generated by Mentor Graphics' HDL Designer(TM) 2019.2 (Build 5)
--
ENTITY waveformGen_tb IS
-- Declarations
END waveformGen_tb ;

View File

@ -0,0 +1,106 @@
--
-- VHDL Architecture WaveformGenerator_test.waveformGen_tb.struct
--
-- Created:
-- by - remi.heredero.UNKNOWN (WE2330808)
-- at - 11:05:34 27.02.2024
--
-- Generated by Mentor Graphics' HDL Designer(TM) 2019.2 (Build 5)
--
LIBRARY ieee;
USE ieee.std_logic_1164.all;
USE ieee.numeric_std.ALL;
LIBRARY WaveformGenerator;
LIBRARY WaveformGenerator_test;
ARCHITECTURE struct OF waveformGen_tb IS
-- Architecture declarations
constant bitNb: positive := 16;
constant clockFrequency: real := 60.0E6;
--constant clockFrequency: real := 66.0E6;
-- Internal signal declarations
SIGNAL clock : std_ulogic;
SIGNAL en : std_ulogic;
SIGNAL reset : std_ulogic;
SIGNAL sawtooth : unsigned(bitNb-1 DOWNTO 0);
SIGNAL square : unsigned(bitNb-1 DOWNTO 0);
SIGNAL step : unsigned(bitNb-1 DOWNTO 0);
-- Component Declarations
COMPONENT waveformGen
GENERIC (
phaseBitNb : positive := 16;
signalBitNb : positive := 16
);
PORT (
clock : IN std_ulogic ;
en : IN std_ulogic ;
reset : IN std_ulogic ;
step : IN unsigned (phaseBitNb-1 DOWNTO 0);
polygon : OUT unsigned (signalBitNb-1 DOWNTO 0);
sawtooth : OUT unsigned (phaseBitNb-1 DOWNTO 0);
sine : OUT unsigned (signalBitNb-1 DOWNTO 0);
square : OUT unsigned (signalBitNb-1 DOWNTO 0);
triangle : OUT unsigned (signalBitNb-1 DOWNTO 0)
);
END COMPONENT;
COMPONENT waveformGen_tester
GENERIC (
bitNb : positive := 16;
clockFrequency : real := 60.0E6
);
PORT (
sawtooth : IN unsigned (bitNb-1 DOWNTO 0);
square : IN unsigned (bitNb-1 DOWNTO 0);
clock : OUT std_ulogic ;
en : OUT std_ulogic ;
reset : OUT std_ulogic ;
step : OUT unsigned (bitNb-1 DOWNTO 0)
);
END COMPONENT;
-- Optional embedded configurations
-- pragma synthesis_off
FOR ALL : waveformGen USE ENTITY WaveformGenerator.waveformGen;
FOR ALL : waveformGen_tester USE ENTITY WaveformGenerator_test.waveformGen_tester;
-- pragma synthesis_on
BEGIN
-- Instance port mappings.
I_DUT : waveformGen
GENERIC MAP (
phaseBitNb => bitNb,
signalBitNb => bitNb
)
PORT MAP (
clock => clock,
en => en,
reset => reset,
step => step,
polygon => OPEN,
sawtooth => sawtooth,
sine => OPEN,
square => square,
triangle => OPEN
);
I_tb : waveformGen_tester
GENERIC MAP (
bitNb => bitNb,
clockFrequency => clockFrequency
)
PORT MAP (
sawtooth => sawtooth,
square => square,
clock => clock,
en => en,
reset => reset,
step => step
);
END struct;

View File

@ -0,0 +1,30 @@
-- VHDL Entity WaveformGenerator_test.waveformGen_tester.interface
--
-- Created:
-- by - remi.heredero.UNKNOWN (WE2330808)
-- at - 11:05:34 27.02.2024
--
-- Generated by Mentor Graphics' HDL Designer(TM) 2019.2 (Build 5)
--
LIBRARY ieee;
USE ieee.std_logic_1164.all;
USE ieee.numeric_std.ALL;
ENTITY waveformGen_tester IS
GENERIC(
bitNb : positive := 16;
clockFrequency : real := 60.0E6
);
PORT(
sawtooth : IN unsigned (BitNb-1 DOWNTO 0);
square : IN unsigned (BitNb-1 DOWNTO 0);
clock : OUT std_ulogic;
en : OUT std_ulogic;
reset : OUT std_ulogic;
step : OUT unsigned (bitNb-1 DOWNTO 0)
);
-- Declarations
END waveformGen_tester ;