Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
A
AIDA-2020 TLU
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
2
Issues
2
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Projects
AIDA-2020 TLU
Commits
357230c5
Commit
357230c5
authored
May 08, 2018
by
David Cussans
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Backing out changes to T0/Sync generator going back to generating T0 pulse
parent
9fe99a24
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
15 deletions
+17
-15
T0_Shutter_Iface_rtl.vhd
components/tlu/firmware/hdl/T0_Shutter_Iface_rtl.vhd
+17
-15
No files found.
components/tlu/firmware/hdl/T0_Shutter_Iface_rtl.vhd
View file @
357230c5
...
...
@@ -81,7 +81,7 @@ ARCHITECTURE rtl OF T0_Shutter_Iface IS
signal
s_enable_sequence
:
std_logic
;
--! take high to enable sequence
signal
s_enable_internal_cycle
:
std_logic
;
--! take high to enable internal sequence
signal
s_T0_ipbus
:
std_logic
;
--! T0 synchronization signal on IPBus clock domain.
signal
s_run_active
:
std_logic
;
--! Take active to issue T0 pulse and enable shutters
--
signal s_run_active : std_logic; --! Take active to issue T0 pulse and enable shutters
constant
c_NUM_CTRL_REGS
:
integer
:
=
9
;
constant
c_NUM_STAT_REGS
:
integer
:
=
1
;
signal
s_ipbus_statusregs
:
ipb_reg_v
(
c_NUM_STAT_REGS
-
1
downto
0
)
:
=
(
others
=>
(
others
=>
'0'
));
...
...
@@ -131,8 +131,9 @@ begin
rstb
=>
open
);
s_enable_sequence
<=
(
s_ipbus_controlregs
(
0
)(
0
)
and
s_run_active
)
when
(
rising_edge
(
clk_4x_i
)
and
(
clk_4x_strobe_i
=
'1'
));
s_run_active
<=
s_ipbus_controlregs
(
8
)(
0
);
--! Set to 1 to issue T0 and start shutter
-- s_enable_sequence <= ( s_ipbus_controlregs(0)(0) and s_run_active ) when (rising_edge(clk_4x_i) and (clk_4x_strobe_i = '1'));
s_enable_sequence
<=
s_ipbus_controlregs
(
0
)(
0
)
when
(
rising_edge
(
clk_4x_i
)
and
(
clk_4x_strobe_i
=
'1'
));
-- s_run_active <= s_ipbus_controlregs(8)(0); --! Set to 1 to issue T0 and start shutter
s_enable_internal_cycle
<=
s_ipbus_controlregs
(
0
)(
1
);
s_trigger_source_select
<=
s_ipbus_controlregs
(
1
);
...
...
@@ -147,25 +148,26 @@ begin
-- A bodge. I can't figure out which standard IPBus register generates a
-- pulse, so put this logic in parallel.
--------------------
--
ipbus_generateT0: process (ipbus_clk_i)
--
begin -- process ipbus_clk_i
--
if rising_edge(ipbus_clk_i) then
--
--
if (ipbus_i.ipb_strobe = '1' and ipbus_i.ipb_write = '1' and ipbus_i.ipb_addr(3 downto 0) = c_T0_address ) then
--
s_T0_ipbus <= '1'; -- set T0 signal high
--
else
--
s_T0_ipbus <= '0';
--
end if;
ipbus_generateT0
:
process
(
ipbus_clk_i
)
begin
-- process ipbus_clk_i
if
rising_edge
(
ipbus_clk_i
)
then
if
(
ipbus_i
.
ipb_strobe
=
'1'
and
ipbus_i
.
ipb_write
=
'1'
and
ipbus_i
.
ipb_addr
(
3
downto
0
)
=
c_T0_address
)
then
s_T0_ipbus
<=
'1'
;
-- set T0 signal high
else
s_T0_ipbus
<=
'0'
;
end
if
;
--
end if;
--
end process ipbus_generateT0;
end
if
;
end
process
ipbus_generateT0
;
--! Retime T0 generated by IPBus onto clk_4x and align with strobe
cmp_T0_retime
:
entity
work
.
stretchPulse4x
port
map
(
clk_4x_i
=>
clk_4x_i
,
clk_4x_strobe_i
=>
clk_4x_strobe_i
,
pulse_i
=>
s_run_active
,
-- pulse_i => s_run_active,
pulse_i
=>
s_T0_ipbus
pulse_o
=>
T0_o
);
END
rtl
;
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment