eFEX firmware
1.7.3
ATLAS l1-calo - electron and tau feature extraction firmware for eFEX boards
Back to eFEX documentation
Readout
src
busy_flag_fsm.vhd
Go to the documentation of this file.
1
10
11
library
IEEE
;
12
use
IEEE.STD_LOGIC_1164.
ALL
;
13
use
IEEE.NUMERIC_STD.
ALL
;
14
15
entity
busy_flag_fsm
is
16
generic
(
17
width
:
integer
:=
32
18
)
;
19
Port
(
20
clk
:
in
STD_LOGIC
;
21
rst
:
in
STD_LOGIC
;
22
busy_flag_assert
:
in
STD_LOGIC_VECTOR
(
width
-
1
downto
0
)
;
23
busy_flag_negate
:
in
STD_LOGIC_VECTOR
(
width
-
1
downto
0
)
;
24
fifo_data_count
:
in
STD_LOGIC_VECTOR
(
width
-
1
downto
0
)
;
25
busy_flag
:
out
STD_LOGIC
:=
'
0
'
26
)
;
27
end
busy_flag_fsm
;
28
29
architecture
Behavioral
of
busy_flag_fsm
is
30
signal
busy_flag_i
:
STD_LOGIC
:=
'
0
'
;
31
begin
32
33
busy_flag
<=
busy_flag_i
;
-- output to cFPGA
34
35
U1_proc :
process
(clk)
36
begin
37
if
(
clk
'
event
and
clk
=
'
1
'
)
then
38
if
(
rst
=
'
1
'
)
then
39
busy_flag_i
<=
'
0
'
;
-- set flag ZERO
40
else
41
if
(
unsigned
(
fifo_data_count
)
>
unsigned
(
busy_flag_assert
)
)
then
42
busy_flag_i
<=
'
1
'
;
43
else
44
if
(
unsigned
(
fifo_data_count
)
<
unsigned
(
busy_flag_negate
)
)
then
45
busy_flag_i
<=
'
0
'
;
46
end
if
;
47
end
if
;
48
end
if
;
49
end
if
;
50
end
process
U1_proc
;
51
52
end
Behavioral;
busy_flag_fsm.Behavioral
Definition:
busy_flag_fsm.vhd:29
busy_flag_fsm
Definition:
busy_flag_fsm.vhd:15
Generated on Tue Nov 11 2025 09:44:32 for eFEX firmware by
1.9.1