Lösung des Praktikums Systementwurf
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

task_fft.vhd 1.8KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. library ieee;
  2. use ieee.std_logic_1164.all;
  3. use ieee.numeric_std.all;
  4. library work;
  5. use work.reg32.all;
  6. use work.task.all;
  7. entity task_fft is
  8. port (
  9. clk : in std_logic;
  10. reset : in std_logic;
  11. address : in std_logic_vector( 3 downto 0 );
  12. read : in std_logic;
  13. readdata : out std_logic_vector( 31 downto 0 );
  14. write : in std_logic;
  15. writedata : in std_logic_vector( 31 downto 0 );
  16. signal_read : out std_logic;
  17. signal_readdata : in std_logic_vector( 31 downto 0 );
  18. signal_write : out std_logic;
  19. signal_writedata : out std_logic_vector( 31 downto 0 )
  20. );
  21. end entity task_fft;
  22. architecture struct of task_fft is
  23. signal task_start : std_logic;
  24. signal task_state : work.task.State := work.task.TASK_IDLE;
  25. signal task_config : work.reg32.RegArray( 0 to 2 );
  26. begin
  27. u_control: entity work.hardware_task_control
  28. port map (
  29. clk => clk,
  30. reset => reset,
  31. address => address,
  32. read => read,
  33. readdata => readdata,
  34. write => write,
  35. writedata => writedata,
  36. task_start => task_start,
  37. task_state => task_state,
  38. task_config => task_config
  39. );
  40. u_fft: entity work.fft
  41. generic map (
  42. -- input data width of real/img part
  43. input_data_width => 32,
  44. -- output data width of real/img part
  45. output_data_width => 32
  46. )
  47. port map (
  48. clk => clk,
  49. reset => reset,
  50. task_start => task_start,
  51. task_state => task_state,
  52. signal_read => signal_read,
  53. signal_readdata => signal_readdata,
  54. signal_write => signal_write,
  55. signal_writedata => signal_writedata
  56. );
  57. end architecture struct;