eFEX firmware  1.7.3
ATLAS l1-calo - electron and tau feature extraction firmware for eFEX boards

Back to eFEX documentation
common_id_registers.vhd
Go to the documentation of this file.
1 
38 
39 library IEEE;
40 use IEEE.STD_LOGIC_1164.all;
41 use ieee.numeric_std.all;
42 library ipbus_lib;
43 use ipbus_lib.ipbus.all;
44 use ipbus_lib.ipbus_reg_types.all;
45 library infrastructure_lib;
46 use infrastructure_lib.ipbus_decode_efex_common_id_version.all;
47 
50  port(
52  ipb_clk : in std_logic;
54  ipb_rst : in std_logic;
56  ipb_in : in ipb_wbus;
58  ipb_out : out ipb_rbus;
60  Module_ID : in std_logic_vector(31 downto 0);
62  xml_version : in std_logic_vector(31 downto 0);
64  xml_Gitsha : in std_logic_vector(31 downto 0);
66  fw_version : in std_logic_vector(31 downto 0);
68  fw_Gitsha : in std_logic_vector(31 downto 0);
70  build_date : in std_logic_vector(31 downto 0);
72  build_time : in std_logic_vector(31 downto 0)
73 
74  );
75 
76 
79 architecture Behavioral of common_id_registers is
80 
81  signal ipbw : ipb_wbus_array(N_SLAVES-1 downto 0);
82  signal ipbr : ipb_rbus_array(N_SLAVES-1 downto 0);
83 
84 begin
85 
86  fabric_common_IDversion : entity ipbus_lib.ipbus_fabric_sel
87  generic map(NSLV => N_SLAVES, --defined in ipbus_decode_common_IdVersion
88  SEL_WIDTH => ipbus_sel_width)
89  port map(
90  ipb_in => ipb_in,
91  ipb_out => ipb_out,
92  sel => ipbus_sel_efex_common_id_version(ipb_in.ipb_addr),
93  ipb_to_slaves => ipbw,
94  ipb_from_slaves => ipbr
95  );
96 
97  Moduleid : entity ipbus_lib.ipbus_ctrlreg_v -- reads the module ID register
98  generic map (
99  N_CTRL => 0, --number of control reg
100  N_STAT => 1) --number of status reg
101  port map (
102  clk => ipb_clk,
103  reset => ipb_rst,
104  ipbus_in => ipbw(N_SLV_MODULE_ID),
105  ipbus_out => ipbr(N_SLV_MODULE_ID),
106  d => (0 => Module_ID),
107  q => open,
108  -- qmask => (others => '0'),
109  stb => open);
110 
111  Xmlversion : entity ipbus_lib.ipbus_ctrlreg_v -- reads the module ID register
112  generic map (
113  N_CTRL => 0, --number of control reg
114  N_STAT => 2) --number of status reg
115  port map (
116  clk => ipb_clk,
117  reset => ipb_rst,
118  ipbus_in => ipbw(N_SLV_XML_VERSION),
119  ipbus_out => ipbr(N_SLV_XML_VERSION),
120  d => (0 => xml_version, 1 => xml_Gitsha),
121  q => open,
122  -- qmask => (others => '0'),
123  stb => open);
124 
125  buildversion : entity ipbus_lib.ipbus_ctrlreg_v -- reads the module ID register
126  generic map (
127  N_CTRL => 0, --number of control reg
128  N_STAT => 2) --number of status reg
129  port map (
130  clk => ipb_clk,
131  reset => ipb_rst,
132  ipbus_in => ipbw(N_SLV_BUILD_TIME_AND_DATE),
133  ipbus_out => ipbr(N_SLV_BUILD_TIME_AND_DATE),
134  d => (0 => build_date, 1 => build_time),
135  q => open,
136  -- qmask => (others => '0'),
137  stb => open);
138 
139  firmwareversion : entity ipbus_lib.ipbus_ctrlreg_v -- reads the module ID register
140  generic map (
141  N_CTRL => 0, --number of control reg
142  N_STAT => 2) --number of status reg
143  port map (
144  clk => ipb_clk,
145  reset => ipb_rst,
146  ipbus_in => ipbw(N_SLV_FIRMWARE_VERSION),
147  ipbus_out => ipbr(N_SLV_FIRMWARE_VERSION),
148  d => (0 => fw_version, 1 => fw_Gitsha),
149  q => open,
150  -- qmask => (others => '0'),
151  stb => open);
152 
153 end Behavioral;
154 
FPGA Common ID Module.
in fw_version std_logic_vector( 31 downto 0)
Version of the repository (format: MMmmcccc in hex)
in xml_Gitsha std_logic_vector( 31 downto 0)
Short 7-digit git SHA of the XMLs.
in ipb_rst std_logic
ipbus reset
in fw_Gitsha std_logic_vector( 31 downto 0)
Short 7-digit git SHA of the repository.
in Module_ID std_logic_vector( 31 downto 0)
module id of the eFEX
in build_date std_logic_vector( 31 downto 0)
Date format DDMMYYYY in decimal.
in build_time std_logic_vector( 31 downto 0)
Time format 00HHMMSS in decimal.
in ipb_clk std_logic
ipbus clk of 31.25MHz
out ipb_out ipb_rbus
IPBus output bus going from slaves to m.
in ipb_in ipb_wbus
IPBus input bus going from master to slaves.
in xml_version std_logic_vector( 31 downto 0)
Version of the XMLs.