gen_got_trm : process(CLK)
begin
if rising_edge(CLK) then
- if RESET = '1' or send_reply_trm = '1' or locked = '0' then
+ if RESET = '1' or locked = '0' then
got_trm <= (others => '0');
else
got_trm <= got_trm or locking_point or (reply_reading_F3 and reg_current_reply_reading_TRM)
begin
if rising_edge(CLK) then
if RESET = '1' or reply_data_counter_reset = '1' then
- reply_data_counter <= (others => '1');
+ reply_data_counter <= (others => '0');
elsif last_comb_REPLY_POOL_DATAREADY = '1' and (packet_counter = c_F0 or packet_counter = c_F2) then
reply_data_counter <= reply_data_counter + 1;
end if;
end if;
--if number of announced words is reached and F1 or F3 is written, then care about padding
- if reply_data_counter = current_point_length and packet_counter(0) = '1' and comb_REPLY_muxed_DATAREADY = '1' then
+ if (reply_data_counter = current_point_length and packet_counter(0) = '1' and comb_REPLY_muxed_DATAREADY = '1')
+ or or_all(current_reply_reading_TRM and reply_arbiter_result) = '1' then
reply_arbiter_CLK_EN <= '1';
reply_data_counter_reset <= '1';
--either padding or trm follows. So: start reading in any case.
start_read_padding <= reply_arbiter_result;
- elsif or_all(current_reply_reading_TRM and reply_arbiter_result) = '1' then
- reply_data_counter_reset <= '1';
- reply_arbiter_CLK_EN <= '1';
end if;
- if send_reply_trm = '1' then
+ if send_reply_trm = '1' then
if packet_counter /= c_H0 then
next_state <= SEND_PADDING;
else