Backport Memory Controller to rtps_builtin_endpoint
Backport Memory Controller and Memory FSM from RTPS/DDS Endpoints to RTPS Builtin Endpoint. The Memory is now using a single linked list and the FSM uses Frame Field Flags. The main FSM uses check_time to initiate stale checks, and the stale checks are done in the main FSM. Testbench was modified to accomodate the changes (Previous L0 Test4 was removed and integrated in L0 Test 1).
This commit is contained in:
parent
7f7b7a6164
commit
90a4c7928a
199
sim/L0_dds_reader_test7_arzkriu.do
Normal file
199
sim/L0_dds_reader_test7_arzkriu.do
Normal file
File diff suppressed because one or more lines are too long
@ -1,51 +1,64 @@
|
||||
onerror {resume}
|
||||
quietly WaveActivateNextPane {} 0
|
||||
add wave -noupdate -divider SYSTEM
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/uut/clk
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/uut/reset
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/clk
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/reset
|
||||
add wave -noupdate -divider INPUT
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/uut/empty
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/uut/rd
|
||||
add wave -noupdate -radix hexadecimal /L0_rtps_builtin_endpoint_test1/uut/data_in
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/uut/last_word_in
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/uut/last_word_in_latch
|
||||
add wave -noupdate -divider TESTBENCH
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/start
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/stim_stage
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/stimulus.length
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/cnt_stim
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/packet_sent
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/empty
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/rd
|
||||
add wave -noupdate -radix hexadecimal /l0_rtps_builtin_endpoint_test1/uut/data_in
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/last_word_in
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/last_word_in_latch
|
||||
add wave -noupdate -divider {MAIN FSM}
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/uut/stage
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/uut/stage_next
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/uut/cnt
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/uut/endpoint_mask
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/uut/participant_match
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/stage
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/stage_next
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/cnt
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/endpoint_mask
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/participant_match
|
||||
add wave -noupdate -divider {MEM FSM}
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/uut/mem_opcode
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/uut/mem_op_start
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/uut/mem_op_done
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/uut/mem_stage
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/uut/mem_stage_next
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/uut/mem_cnt
|
||||
add wave -noupdate -radix unsigned /L0_rtps_builtin_endpoint_test1/uut/mem_addr_base
|
||||
add wave -noupdate -radix unsigned /L0_rtps_builtin_endpoint_test1/uut/addr_res
|
||||
add wave -noupdate -group MEMORY -radix unsigned /l0_rtps_builtin_endpoint_test1/uut/mem_ctrl_inst/addr
|
||||
add wave -noupdate -group MEMORY /l0_rtps_builtin_endpoint_test1/uut/mem_ctrl_inst/read
|
||||
add wave -noupdate -group MEMORY /l0_rtps_builtin_endpoint_test1/uut/mem_ctrl_inst/ready_in
|
||||
add wave -noupdate -group MEMORY /l0_rtps_builtin_endpoint_test1/uut/mem_ctrl_inst/valid_in
|
||||
add wave -noupdate -group MEMORY -radix hexadecimal /l0_rtps_builtin_endpoint_test1/uut/mem_ctrl_inst/data_in
|
||||
add wave -noupdate -group MEMORY /l0_rtps_builtin_endpoint_test1/uut/mem_ctrl_inst/ready_out
|
||||
add wave -noupdate -group MEMORY /l0_rtps_builtin_endpoint_test1/uut/mem_ctrl_inst/valid_out
|
||||
add wave -noupdate -group MEMORY -radix hexadecimal /l0_rtps_builtin_endpoint_test1/uut/mem_ctrl_inst/data_out
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/mem_op_start
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/mem_opcode
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/mem_op_done
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/mem_stage
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/mem_stage_next
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/mem_cnt
|
||||
add wave -noupdate -radix unsigned /l0_rtps_builtin_endpoint_test1/uut/mem_addr_base
|
||||
add wave -noupdate -radix unsigned /l0_rtps_builtin_endpoint_test1/uut/mem_empty_head
|
||||
add wave -noupdate -radix unsigned /l0_rtps_builtin_endpoint_test1/uut/mem_occupied_head
|
||||
add wave -noupdate -childformat {{/l0_rtps_builtin_endpoint_test1/uut/participant_data.guid_prefix -radix hexadecimal} {/l0_rtps_builtin_endpoint_test1/uut/participant_data.meta_addr -radix hexadecimal} {/l0_rtps_builtin_endpoint_test1/uut/participant_data.def_addr -radix hexadecimal} {/l0_rtps_builtin_endpoint_test1/uut/participant_data.meta_port -radix hexadecimal} {/l0_rtps_builtin_endpoint_test1/uut/participant_data.def_port -radix hexadecimal} {/l0_rtps_builtin_endpoint_test1/uut/participant_data.lease_duration -radix unsigned} {/l0_rtps_builtin_endpoint_test1/uut/participant_data.lease_deadline -radix unsigned} {/l0_rtps_builtin_endpoint_test1/uut/participant_data.heartbeat_res_time -radix unsigned} {/l0_rtps_builtin_endpoint_test1/uut/participant_data.acknack_res_time -radix unsigned} {/l0_rtps_builtin_endpoint_test1/uut/participant_data.spdp_seq_nr -radix unsigned} {/l0_rtps_builtin_endpoint_test1/uut/participant_data.pub_seq_nr -radix unsigned} {/l0_rtps_builtin_endpoint_test1/uut/participant_data.sub_seq_nr -radix unsigned} {/l0_rtps_builtin_endpoint_test1/uut/participant_data.mes_seq_nr -radix unsigned}} -subitemconfig {/l0_rtps_builtin_endpoint_test1/uut/participant_data.guid_prefix {-height 15 -radix hexadecimal} /l0_rtps_builtin_endpoint_test1/uut/participant_data.meta_addr {-height 15 -radix hexadecimal} /l0_rtps_builtin_endpoint_test1/uut/participant_data.def_addr {-height 15 -radix hexadecimal} /l0_rtps_builtin_endpoint_test1/uut/participant_data.meta_port {-height 15 -radix hexadecimal} /l0_rtps_builtin_endpoint_test1/uut/participant_data.def_port {-height 15 -radix hexadecimal} /l0_rtps_builtin_endpoint_test1/uut/participant_data.lease_duration {-height 15 -radix unsigned} /l0_rtps_builtin_endpoint_test1/uut/participant_data.lease_deadline {-height 15 -radix unsigned} /l0_rtps_builtin_endpoint_test1/uut/participant_data.heartbeat_res_time {-height 15 -radix unsigned} /l0_rtps_builtin_endpoint_test1/uut/participant_data.acknack_res_time {-height 15 -radix unsigned} /l0_rtps_builtin_endpoint_test1/uut/participant_data.spdp_seq_nr {-height 15 -radix unsigned} /l0_rtps_builtin_endpoint_test1/uut/participant_data.pub_seq_nr {-height 15 -radix unsigned} /l0_rtps_builtin_endpoint_test1/uut/participant_data.sub_seq_nr {-height 15 -radix unsigned} /l0_rtps_builtin_endpoint_test1/uut/participant_data.mes_seq_nr {-height 15 -radix unsigned}} /l0_rtps_builtin_endpoint_test1/uut/participant_data
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/current_pmf
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/mem_field_flags
|
||||
add wave -noupdate -divider GUARD
|
||||
add wave -noupdate -radix unsigned /L0_rtps_builtin_endpoint_test1/uut/read_cnt
|
||||
add wave -noupdate -radix unsigned /L0_rtps_builtin_endpoint_test1/uut/parameter_end
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/uut/parse_prc/rd_guard
|
||||
add wave -noupdate -divider MEMORY
|
||||
add wave -noupdate -group MEMORY -radix unsigned /L0_rtps_builtin_endpoint_test1/uut/ram_inst/addr
|
||||
add wave -noupdate -group MEMORY /L0_rtps_builtin_endpoint_test1/uut/ram_inst/wen
|
||||
add wave -noupdate -group MEMORY /L0_rtps_builtin_endpoint_test1/uut/ram_inst/ren
|
||||
add wave -noupdate -group MEMORY -radix hexadecimal /L0_rtps_builtin_endpoint_test1/uut/ram_inst/wr_data
|
||||
add wave -noupdate -group MEMORY -radix hexadecimal /L0_rtps_builtin_endpoint_test1/uut/ram_inst/rd_data
|
||||
add wave -noupdate -radix unsigned /l0_rtps_builtin_endpoint_test1/uut/read_cnt
|
||||
add wave -noupdate -radix unsigned /l0_rtps_builtin_endpoint_test1/uut/parameter_end
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/parse_prc/rd_guard
|
||||
add wave -noupdate -divider MISC
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test1/uut/update_participant_flags
|
||||
add wave -noupdate -radix unsigned /L0_rtps_builtin_endpoint_test1/uut/mem_seq_nr
|
||||
add wave -noupdate -radix unsigned /L0_rtps_builtin_endpoint_test1/uut/seq_nr
|
||||
add wave -noupdate -radix unsigned /l0_rtps_builtin_endpoint_test1/uut/seq_nr
|
||||
add wave -noupdate -divider TESTBENCH
|
||||
add wave -noupdate -expand -group TESTBENCH /l0_rtps_builtin_endpoint_test1/start
|
||||
add wave -noupdate -expand -group TESTBENCH /l0_rtps_builtin_endpoint_test1/stim_stage
|
||||
add wave -noupdate -expand -group TESTBENCH /l0_rtps_builtin_endpoint_test1/stimulus.length
|
||||
add wave -noupdate -expand -group TESTBENCH /l0_rtps_builtin_endpoint_test1/cnt_stim
|
||||
add wave -noupdate -expand -group TESTBENCH /l0_rtps_builtin_endpoint_test1/packet_sent
|
||||
add wave -noupdate -expand -group TESTBENCH /l0_rtps_builtin_endpoint_test1/mem_check_done
|
||||
add wave -noupdate -expand -group TESTBENCH /l0_rtps_builtin_endpoint_test1/check_done
|
||||
add wave -noupdate -divider OUTPUT
|
||||
add wave -noupdate -radix hexadecimal /l0_rtps_builtin_endpoint_test1/uut/data_out
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/endpoint_full
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/endpoint_wr
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/rtps_wr
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/rtps_full
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test1/uut/last_word_out
|
||||
TreeUpdate [SetDefaultTree]
|
||||
WaveRestoreCursors {{Cursor 1} {10125000 ps} 1}
|
||||
WaveRestoreCursors {{Cursor 1} {82041201 ps} 0}
|
||||
quietly wave cursor active 1
|
||||
configure wave -namecolwidth 149
|
||||
configure wave -valuecolwidth 144
|
||||
@ -61,4 +74,4 @@ configure wave -griddelta 40
|
||||
configure wave -timeline 0
|
||||
configure wave -timelineunits ps
|
||||
update
|
||||
WaveRestoreZoom {9084076 ps} {10232418 ps}
|
||||
WaveRestoreZoom {81521938 ps} {82670280 ps}
|
||||
|
||||
@ -1,55 +1,65 @@
|
||||
onerror {resume}
|
||||
quietly WaveActivateNextPane {} 0
|
||||
add wave -noupdate -divider SYSTEM
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test5/uut/clk
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test5/uut/reset
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/clk
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/reset
|
||||
add wave -noupdate -radix unsigned /l0_rtps_builtin_endpoint_test5/uut/time
|
||||
add wave -noupdate -radix unsigned /l0_rtps_builtin_endpoint_test5/uut/check_time
|
||||
add wave -noupdate -divider INPUT
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test5/uut/empty
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test5/uut/rd
|
||||
add wave -noupdate -radix hexadecimal /L0_rtps_builtin_endpoint_test5/uut/data_in
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test5/uut/last_word_in
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test5/uut/last_word_in_latch
|
||||
add wave -noupdate -divider OUTPUT
|
||||
add wave -noupdate -radix hexadecimal /L0_rtps_builtin_endpoint_test5/uut/data_out
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test5/uut/endpoint_wr
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test5/uut/last_word_out
|
||||
add wave -noupdate -divider TESTBENCH
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test5/start
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test5/stim_stage
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test5/stimulus.length
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test5/cnt_stim
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test5/packet_sent
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/empty
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/rd
|
||||
add wave -noupdate -radix hexadecimal /l0_rtps_builtin_endpoint_test5/uut/data_in
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/last_word_in
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/last_word_in_latch
|
||||
add wave -noupdate -divider {MAIN FSM}
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test5/uut/stage
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test5/uut/stage_next
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test5/uut/cnt
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test5/uut/endpoint_mask
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test5/uut/participant_match
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/stage
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/stage_next
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/cnt
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/endpoint_mask
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/participant_match
|
||||
add wave -noupdate -divider {MEM FSM}
|
||||
add wave -noupdate -group MEM_FSM /L0_rtps_builtin_endpoint_test5/uut/mem_opcode
|
||||
add wave -noupdate -group MEM_FSM /L0_rtps_builtin_endpoint_test5/uut/mem_op_start
|
||||
add wave -noupdate -group MEM_FSM /L0_rtps_builtin_endpoint_test5/uut/mem_op_done
|
||||
add wave -noupdate -group MEM_FSM /L0_rtps_builtin_endpoint_test5/uut/mem_stage
|
||||
add wave -noupdate -group MEM_FSM /L0_rtps_builtin_endpoint_test5/uut/mem_stage_next
|
||||
add wave -noupdate -group MEM_FSM /L0_rtps_builtin_endpoint_test5/uut/mem_cnt
|
||||
add wave -noupdate -group MEM_FSM -radix unsigned /L0_rtps_builtin_endpoint_test5/uut/mem_addr_base
|
||||
add wave -noupdate -group MEM_FSM -radix unsigned /L0_rtps_builtin_endpoint_test5/uut/addr_res
|
||||
add wave -noupdate -group MEMORY -radix unsigned /l0_rtps_builtin_endpoint_test5/uut/mem_ctrl_inst/addr
|
||||
add wave -noupdate -group MEMORY /l0_rtps_builtin_endpoint_test5/uut/mem_ctrl_inst/read
|
||||
add wave -noupdate -group MEMORY /l0_rtps_builtin_endpoint_test5/uut/mem_ctrl_inst/ready_in
|
||||
add wave -noupdate -group MEMORY /l0_rtps_builtin_endpoint_test5/uut/mem_ctrl_inst/valid_in
|
||||
add wave -noupdate -group MEMORY -radix hexadecimal /l0_rtps_builtin_endpoint_test5/uut/mem_ctrl_inst/data_in
|
||||
add wave -noupdate -group MEMORY /l0_rtps_builtin_endpoint_test5/uut/mem_ctrl_inst/ready_out
|
||||
add wave -noupdate -group MEMORY /l0_rtps_builtin_endpoint_test5/uut/mem_ctrl_inst/valid_out
|
||||
add wave -noupdate -group MEMORY -radix hexadecimal /l0_rtps_builtin_endpoint_test5/uut/mem_ctrl_inst/data_out
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/mem_op_start
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/mem_opcode
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/mem_op_done
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/mem_stage
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/mem_stage_next
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/mem_cnt
|
||||
add wave -noupdate -radix unsigned /l0_rtps_builtin_endpoint_test5/uut/mem_addr_base
|
||||
add wave -noupdate -radix unsigned /l0_rtps_builtin_endpoint_test5/uut/mem_empty_head
|
||||
add wave -noupdate -radix unsigned /l0_rtps_builtin_endpoint_test5/uut/mem_occupied_head
|
||||
add wave -noupdate -childformat {{/l0_rtps_builtin_endpoint_test5/uut/participant_data.guid_prefix -radix hexadecimal} {/l0_rtps_builtin_endpoint_test5/uut/participant_data.meta_addr -radix hexadecimal} {/l0_rtps_builtin_endpoint_test5/uut/participant_data.def_addr -radix hexadecimal} {/l0_rtps_builtin_endpoint_test5/uut/participant_data.meta_port -radix hexadecimal} {/l0_rtps_builtin_endpoint_test5/uut/participant_data.def_port -radix hexadecimal} {/l0_rtps_builtin_endpoint_test5/uut/participant_data.lease_duration -radix unsigned} {/l0_rtps_builtin_endpoint_test5/uut/participant_data.lease_deadline -radix unsigned} {/l0_rtps_builtin_endpoint_test5/uut/participant_data.heartbeat_res_time -radix unsigned} {/l0_rtps_builtin_endpoint_test5/uut/participant_data.acknack_res_time -radix unsigned} {/l0_rtps_builtin_endpoint_test5/uut/participant_data.spdp_seq_nr -radix unsigned} {/l0_rtps_builtin_endpoint_test5/uut/participant_data.pub_seq_nr -radix unsigned} {/l0_rtps_builtin_endpoint_test5/uut/participant_data.sub_seq_nr -radix unsigned} {/l0_rtps_builtin_endpoint_test5/uut/participant_data.mes_seq_nr -radix unsigned}} -subitemconfig {/l0_rtps_builtin_endpoint_test5/uut/participant_data.guid_prefix {-height 15 -radix hexadecimal} /l0_rtps_builtin_endpoint_test5/uut/participant_data.meta_addr {-height 15 -radix hexadecimal} /l0_rtps_builtin_endpoint_test5/uut/participant_data.def_addr {-height 15 -radix hexadecimal} /l0_rtps_builtin_endpoint_test5/uut/participant_data.meta_port {-height 15 -radix hexadecimal} /l0_rtps_builtin_endpoint_test5/uut/participant_data.def_port {-height 15 -radix hexadecimal} /l0_rtps_builtin_endpoint_test5/uut/participant_data.lease_duration {-height 15 -radix unsigned} /l0_rtps_builtin_endpoint_test5/uut/participant_data.lease_deadline {-height 15 -radix unsigned} /l0_rtps_builtin_endpoint_test5/uut/participant_data.heartbeat_res_time {-height 15 -radix unsigned} /l0_rtps_builtin_endpoint_test5/uut/participant_data.acknack_res_time {-height 15 -radix unsigned} /l0_rtps_builtin_endpoint_test5/uut/participant_data.spdp_seq_nr {-height 15 -radix unsigned} /l0_rtps_builtin_endpoint_test5/uut/participant_data.pub_seq_nr {-height 15 -radix unsigned} /l0_rtps_builtin_endpoint_test5/uut/participant_data.sub_seq_nr {-height 15 -radix unsigned} /l0_rtps_builtin_endpoint_test5/uut/participant_data.mes_seq_nr {-height 15 -radix unsigned}} /l0_rtps_builtin_endpoint_test5/uut/participant_data
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/current_pmf
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/mem_field_flags
|
||||
add wave -noupdate -divider GUARD
|
||||
add wave -noupdate -radix unsigned /L0_rtps_builtin_endpoint_test5/uut/read_cnt
|
||||
add wave -noupdate -radix unsigned /L0_rtps_builtin_endpoint_test5/uut/parameter_end
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test5/uut/parse_prc/rd_guard
|
||||
add wave -noupdate -divider MEMORY
|
||||
add wave -noupdate -group MEMORY -radix unsigned /L0_rtps_builtin_endpoint_test5/uut/ram_inst/addr
|
||||
add wave -noupdate -group MEMORY /L0_rtps_builtin_endpoint_test5/uut/ram_inst/wen
|
||||
add wave -noupdate -group MEMORY /L0_rtps_builtin_endpoint_test5/uut/ram_inst/ren
|
||||
add wave -noupdate -group MEMORY -radix hexadecimal /L0_rtps_builtin_endpoint_test5/uut/ram_inst/wr_data
|
||||
add wave -noupdate -group MEMORY -radix hexadecimal /L0_rtps_builtin_endpoint_test5/uut/ram_inst/rd_data
|
||||
add wave -noupdate -radix unsigned /l0_rtps_builtin_endpoint_test5/uut/read_cnt
|
||||
add wave -noupdate -radix unsigned /l0_rtps_builtin_endpoint_test5/uut/parameter_end
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/parse_prc/rd_guard
|
||||
add wave -noupdate -divider MISC
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test5/uut/update_participant_flags
|
||||
add wave -noupdate -radix unsigned /L0_rtps_builtin_endpoint_test5/uut/mem_seq_nr
|
||||
add wave -noupdate -radix unsigned /L0_rtps_builtin_endpoint_test5/uut/seq_nr
|
||||
add wave -noupdate -radix unsigned /l0_rtps_builtin_endpoint_test5/uut/seq_nr
|
||||
add wave -noupdate -divider TESTBENCH
|
||||
add wave -noupdate -expand -group TESTBENCH /l0_rtps_builtin_endpoint_test5/start
|
||||
add wave -noupdate -expand -group TESTBENCH /l0_rtps_builtin_endpoint_test5/stim_stage
|
||||
add wave -noupdate -expand -group TESTBENCH /l0_rtps_builtin_endpoint_test5/stimulus.length
|
||||
add wave -noupdate -expand -group TESTBENCH /l0_rtps_builtin_endpoint_test5/cnt_stim
|
||||
add wave -noupdate -expand -group TESTBENCH /l0_rtps_builtin_endpoint_test5/packet_sent
|
||||
add wave -noupdate -expand -group TESTBENCH /l0_rtps_builtin_endpoint_test5/check_done
|
||||
add wave -noupdate -divider OUTPUT
|
||||
add wave -noupdate -radix hexadecimal /l0_rtps_builtin_endpoint_test5/uut/data_out
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/endpoint_full
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/endpoint_wr
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/rtps_wr
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/rtps_full
|
||||
add wave -noupdate /l0_rtps_builtin_endpoint_test5/uut/last_word_out
|
||||
TreeUpdate [SetDefaultTree]
|
||||
WaveRestoreCursors {Begin {847825000 ps} 1} {Error {851525000 ps} 1} {Cursor {33675000 ps} 0}
|
||||
WaveRestoreCursors {{Cursor 1} {64726 ps} 0}
|
||||
quietly wave cursor active 1
|
||||
configure wave -namecolwidth 149
|
||||
configure wave -valuecolwidth 144
|
||||
@ -63,6 +73,6 @@ configure wave -gridoffset 0
|
||||
configure wave -gridperiod 1
|
||||
configure wave -griddelta 40
|
||||
configure wave -timeline 0
|
||||
configure wave -timelineunits ns
|
||||
configure wave -timelineunits ps
|
||||
update
|
||||
WaveRestoreZoom {848883724 ps} {850032066 ps}
|
||||
WaveRestoreZoom {0 ps} {1148342 ps}
|
||||
|
||||
@ -1,71 +0,0 @@
|
||||
onerror {resume}
|
||||
quietly WaveActivateNextPane {} 0
|
||||
add wave -noupdate -divider SYSTEM
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test7/uut/clk
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test7/uut/reset
|
||||
add wave -noupdate -divider INPUT
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test7/uut/empty
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test7/uut/rd
|
||||
add wave -noupdate -radix hexadecimal /L0_rtps_builtin_endpoint_test7/uut/data_in
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test7/uut/last_word_in
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test7/uut/last_word_in_latch
|
||||
add wave -noupdate -radix hexadecimal /L0_rtps_builtin_endpoint_test7/uut/time
|
||||
add wave -noupdate -divider OUTPUT
|
||||
add wave -noupdate -radix hexadecimal /L0_rtps_builtin_endpoint_test7/uut/data_out
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test7/uut/endpoint_wr
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test7/uut/last_word_out
|
||||
add wave -noupdate -divider TESTBENCH
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test7/start
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test7/stim_stage
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test7/stimulus.length
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test7/cnt_stim
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test7/packet_sent
|
||||
add wave -noupdate -divider {MAIN FSM}
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test7/uut/stage
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test7/uut/stage_next
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test7/uut/cnt
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test7/uut/endpoint_mask
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test7/uut/participant_match
|
||||
add wave -noupdate -radix hexadecimal /L0_rtps_builtin_endpoint_test7/uut/lease_duration
|
||||
add wave -noupdate -radix hexadecimal /L0_rtps_builtin_endpoint_test7/uut/deadline
|
||||
add wave -noupdate -divider {MEM FSM}
|
||||
add wave -noupdate -expand -group MEM_FSM /L0_rtps_builtin_endpoint_test7/uut/mem_opcode
|
||||
add wave -noupdate -expand -group MEM_FSM /L0_rtps_builtin_endpoint_test7/uut/mem_op_start
|
||||
add wave -noupdate -expand -group MEM_FSM /L0_rtps_builtin_endpoint_test7/uut/mem_op_done
|
||||
add wave -noupdate -expand -group MEM_FSM /L0_rtps_builtin_endpoint_test7/uut/mem_stage
|
||||
add wave -noupdate -expand -group MEM_FSM /L0_rtps_builtin_endpoint_test7/uut/mem_stage_next
|
||||
add wave -noupdate -expand -group MEM_FSM /L0_rtps_builtin_endpoint_test7/uut/mem_cnt
|
||||
add wave -noupdate -expand -group MEM_FSM -radix unsigned /L0_rtps_builtin_endpoint_test7/uut/mem_addr_base
|
||||
add wave -noupdate -expand -group MEM_FSM -radix unsigned /L0_rtps_builtin_endpoint_test7/uut/addr_res
|
||||
add wave -noupdate -divider GUARD
|
||||
add wave -noupdate -radix unsigned /L0_rtps_builtin_endpoint_test7/uut/read_cnt
|
||||
add wave -noupdate -radix unsigned /L0_rtps_builtin_endpoint_test7/uut/parameter_end
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test7/uut/parse_prc/rd_guard
|
||||
add wave -noupdate -divider MEMORY
|
||||
add wave -noupdate -expand -group MEMORY -radix unsigned /L0_rtps_builtin_endpoint_test7/uut/ram_inst/addr
|
||||
add wave -noupdate -expand -group MEMORY /L0_rtps_builtin_endpoint_test7/uut/ram_inst/wen
|
||||
add wave -noupdate -expand -group MEMORY /L0_rtps_builtin_endpoint_test7/uut/ram_inst/ren
|
||||
add wave -noupdate -expand -group MEMORY -radix hexadecimal /L0_rtps_builtin_endpoint_test7/uut/ram_inst/wr_data
|
||||
add wave -noupdate -expand -group MEMORY -radix hexadecimal /L0_rtps_builtin_endpoint_test7/uut/ram_inst/rd_data
|
||||
add wave -noupdate -divider MISC
|
||||
add wave -noupdate /L0_rtps_builtin_endpoint_test7/uut/update_participant_flags
|
||||
add wave -noupdate -radix unsigned /L0_rtps_builtin_endpoint_test7/uut/mem_seq_nr
|
||||
add wave -noupdate -radix unsigned /L0_rtps_builtin_endpoint_test7/uut/seq_nr
|
||||
TreeUpdate [SetDefaultTree]
|
||||
WaveRestoreCursors {Begin {31125000 ps} 1} {Error {45825000 ps} 1} {Cursor {31192063 ps} 0}
|
||||
quietly wave cursor active 3
|
||||
configure wave -namecolwidth 149
|
||||
configure wave -valuecolwidth 144
|
||||
configure wave -justifyvalue left
|
||||
configure wave -signalnamewidth 1
|
||||
configure wave -snapdistance 10
|
||||
configure wave -datasetprefix 0
|
||||
configure wave -rowmargin 4
|
||||
configure wave -childrowmargin 2
|
||||
configure wave -gridoffset 0
|
||||
configure wave -gridperiod 1
|
||||
configure wave -griddelta 40
|
||||
configure wave -timeline 0
|
||||
configure wave -timelineunits ns
|
||||
update
|
||||
WaveRestoreZoom {30675309 ps} {31823651 ps}
|
||||
@ -1,68 +1,76 @@
|
||||
onerror {resume}
|
||||
quietly WaveActivateNextPane {} 0
|
||||
add wave -noupdate -divider SYSTEM
|
||||
add wave -noupdate /L1_rtps_builtin_endpoint_test1/uut/clk
|
||||
add wave -noupdate /L1_rtps_builtin_endpoint_test1/uut/reset
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/clk
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/reset
|
||||
add wave -noupdate -radix unsigned /l1_rtps_builtin_endpoint_test1/uut/time
|
||||
add wave -noupdate -radix unsigned /l1_rtps_builtin_endpoint_test1/uut/check_time
|
||||
add wave -noupdate -divider INPUT
|
||||
add wave -noupdate /L1_rtps_builtin_endpoint_test1/uut/empty
|
||||
add wave -noupdate /L1_rtps_builtin_endpoint_test1/uut/rd
|
||||
add wave -noupdate -radix hexadecimal /L1_rtps_builtin_endpoint_test1/uut/data_in
|
||||
add wave -noupdate /L1_rtps_builtin_endpoint_test1/uut/last_word_in
|
||||
add wave -noupdate /L1_rtps_builtin_endpoint_test1/uut/last_word_in_latch
|
||||
add wave -noupdate -radix hexadecimal /L1_rtps_builtin_endpoint_test1/uut/time
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/empty
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/rd
|
||||
add wave -noupdate -radix hexadecimal /l1_rtps_builtin_endpoint_test1/uut/data_in
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/last_word_in
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/last_word_in_latch
|
||||
add wave -noupdate -radix hexadecimal /l1_rtps_builtin_endpoint_test1/uut/time
|
||||
add wave -noupdate -divider OUTPUT
|
||||
add wave -noupdate -radix hexadecimal /L1_rtps_builtin_endpoint_test1/uut/data_out
|
||||
add wave -noupdate /L1_rtps_builtin_endpoint_test1/uut/last_word_out
|
||||
add wave -noupdate /L1_rtps_builtin_endpoint_test1/uut/rtps_wr
|
||||
add wave -noupdate /L1_rtps_builtin_endpoint_test1/uut/rtps_full
|
||||
add wave -noupdate -divider TESTBENCH
|
||||
add wave -noupdate /L1_rtps_builtin_endpoint_test1/start
|
||||
add wave -noupdate /L1_rtps_builtin_endpoint_test1/stim_stage
|
||||
add wave -noupdate /L1_rtps_builtin_endpoint_test1/stimulus.length
|
||||
add wave -noupdate /L1_rtps_builtin_endpoint_test1/cnt_stim
|
||||
add wave -noupdate /L1_rtps_builtin_endpoint_test1/packet_sent
|
||||
add wave -noupdate -radix hexadecimal /l1_rtps_builtin_endpoint_test1/uut/data_out
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/last_word_out
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/rtps_wr
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/rtps_full
|
||||
add wave -noupdate -divider {MAIN FSM}
|
||||
add wave -noupdate /L1_rtps_builtin_endpoint_test1/uut/stage
|
||||
add wave -noupdate /L1_rtps_builtin_endpoint_test1/uut/stage_next
|
||||
add wave -noupdate /L1_rtps_builtin_endpoint_test1/uut/cnt
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/stage
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/stage_next
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/cnt
|
||||
add wave -noupdate -divider {MEM FSM}
|
||||
add wave -noupdate -expand -group MEM_FSM /L1_rtps_builtin_endpoint_test1/uut/mem_opcode
|
||||
add wave -noupdate -expand -group MEM_FSM /L1_rtps_builtin_endpoint_test1/uut/mem_op_start
|
||||
add wave -noupdate -expand -group MEM_FSM /L1_rtps_builtin_endpoint_test1/uut/mem_op_done
|
||||
add wave -noupdate -expand -group MEM_FSM /L1_rtps_builtin_endpoint_test1/uut/mem_stage
|
||||
add wave -noupdate -expand -group MEM_FSM /L1_rtps_builtin_endpoint_test1/uut/mem_stage_next
|
||||
add wave -noupdate -expand -group MEM_FSM /L1_rtps_builtin_endpoint_test1/uut/mem_cnt
|
||||
add wave -noupdate -expand -group MEM_FSM -radix unsigned /L1_rtps_builtin_endpoint_test1/uut/mem_addr_base
|
||||
add wave -noupdate -expand -group MEM_FSM -radix unsigned /L1_rtps_builtin_endpoint_test1/uut/addr_res
|
||||
add wave -noupdate -group MEMORY /l1_rtps_builtin_endpoint_test1/uut/mem_abort_read
|
||||
add wave -noupdate -group MEMORY -radix unsigned /l1_rtps_builtin_endpoint_test1/uut/mem_ctrl_inst/addr
|
||||
add wave -noupdate -group MEMORY /l1_rtps_builtin_endpoint_test1/uut/mem_ctrl_inst/read
|
||||
add wave -noupdate -group MEMORY /l1_rtps_builtin_endpoint_test1/uut/mem_ctrl_inst/ready_in
|
||||
add wave -noupdate -group MEMORY /l1_rtps_builtin_endpoint_test1/uut/mem_ctrl_inst/valid_in
|
||||
add wave -noupdate -group MEMORY -radix hexadecimal /l1_rtps_builtin_endpoint_test1/uut/mem_ctrl_inst/data_in
|
||||
add wave -noupdate -group MEMORY /l1_rtps_builtin_endpoint_test1/uut/mem_ctrl_inst/ready_out
|
||||
add wave -noupdate -group MEMORY /l1_rtps_builtin_endpoint_test1/uut/mem_ctrl_inst/valid_out
|
||||
add wave -noupdate -group MEMORY -radix hexadecimal /l1_rtps_builtin_endpoint_test1/uut/mem_ctrl_inst/data_out
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/mem_op_start
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/mem_op_done
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/mem_opcode
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/mem_stage
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/mem_stage_next
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/mem_cnt
|
||||
add wave -noupdate -childformat {{/l1_rtps_builtin_endpoint_test1/uut/participant_data.guid_prefix -radix hexadecimal} {/l1_rtps_builtin_endpoint_test1/uut/participant_data.meta_addr -radix hexadecimal} {/l1_rtps_builtin_endpoint_test1/uut/participant_data.def_addr -radix hexadecimal} {/l1_rtps_builtin_endpoint_test1/uut/participant_data.meta_port -radix hexadecimal} {/l1_rtps_builtin_endpoint_test1/uut/participant_data.def_port -radix hexadecimal} {/l1_rtps_builtin_endpoint_test1/uut/participant_data.lease_duration -radix unsigned} {/l1_rtps_builtin_endpoint_test1/uut/participant_data.lease_deadline -radix unsigned} {/l1_rtps_builtin_endpoint_test1/uut/participant_data.heartbeat_res_time -radix unsigned} {/l1_rtps_builtin_endpoint_test1/uut/participant_data.acknack_res_time -radix unsigned} {/l1_rtps_builtin_endpoint_test1/uut/participant_data.spdp_seq_nr -radix unsigned} {/l1_rtps_builtin_endpoint_test1/uut/participant_data.pub_seq_nr -radix unsigned} {/l1_rtps_builtin_endpoint_test1/uut/participant_data.sub_seq_nr -radix unsigned} {/l1_rtps_builtin_endpoint_test1/uut/participant_data.mes_seq_nr -radix unsigned}} -expand -subitemconfig {/l1_rtps_builtin_endpoint_test1/uut/participant_data.guid_prefix {-height 15 -radix hexadecimal} /l1_rtps_builtin_endpoint_test1/uut/participant_data.meta_addr {-height 15 -radix hexadecimal} /l1_rtps_builtin_endpoint_test1/uut/participant_data.def_addr {-height 15 -radix hexadecimal} /l1_rtps_builtin_endpoint_test1/uut/participant_data.meta_port {-height 15 -radix hexadecimal} /l1_rtps_builtin_endpoint_test1/uut/participant_data.def_port {-height 15 -radix hexadecimal} /l1_rtps_builtin_endpoint_test1/uut/participant_data.lease_duration {-height 15 -radix unsigned} /l1_rtps_builtin_endpoint_test1/uut/participant_data.lease_deadline {-height 15 -radix unsigned} /l1_rtps_builtin_endpoint_test1/uut/participant_data.heartbeat_res_time {-height 15 -radix unsigned} /l1_rtps_builtin_endpoint_test1/uut/participant_data.acknack_res_time {-height 15 -radix unsigned} /l1_rtps_builtin_endpoint_test1/uut/participant_data.spdp_seq_nr {-height 15 -radix unsigned} /l1_rtps_builtin_endpoint_test1/uut/participant_data.pub_seq_nr {-height 15 -radix unsigned} /l1_rtps_builtin_endpoint_test1/uut/participant_data.sub_seq_nr {-height 15 -radix unsigned} /l1_rtps_builtin_endpoint_test1/uut/participant_data.mes_seq_nr {-height 15 -radix unsigned}} /l1_rtps_builtin_endpoint_test1/uut/participant_data
|
||||
add wave -noupdate -radix unsigned /l1_rtps_builtin_endpoint_test1/uut/mem_addr_base
|
||||
add wave -noupdate -radix unsigned /l1_rtps_builtin_endpoint_test1/uut/mem_empty_head
|
||||
add wave -noupdate -radix unsigned /l1_rtps_builtin_endpoint_test1/uut/mem_occupied_head
|
||||
add wave -noupdate -divider GUARD
|
||||
add wave -noupdate -radix unsigned /L1_rtps_builtin_endpoint_test1/uut/read_cnt
|
||||
add wave -noupdate -radix unsigned /L1_rtps_builtin_endpoint_test1/uut/parameter_end
|
||||
add wave -noupdate /L1_rtps_builtin_endpoint_test1/uut/parse_prc/rd_guard
|
||||
add wave -noupdate -divider MEMORY
|
||||
add wave -noupdate -expand -group MEMORY -radix unsigned /L1_rtps_builtin_endpoint_test1/uut/ram_inst/addr
|
||||
add wave -noupdate -expand -group MEMORY /L1_rtps_builtin_endpoint_test1/uut/ram_inst/wen
|
||||
add wave -noupdate -expand -group MEMORY /L1_rtps_builtin_endpoint_test1/uut/ram_inst/ren
|
||||
add wave -noupdate -expand -group MEMORY -radix hexadecimal /L1_rtps_builtin_endpoint_test1/uut/ram_inst/wr_data
|
||||
add wave -noupdate -expand -group MEMORY -radix hexadecimal /L1_rtps_builtin_endpoint_test1/uut/ram_inst/rd_data
|
||||
add wave -noupdate -radix unsigned /l1_rtps_builtin_endpoint_test1/uut/read_cnt
|
||||
add wave -noupdate -radix unsigned /l1_rtps_builtin_endpoint_test1/uut/parameter_end
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/parse_prc/rd_guard
|
||||
add wave -noupdate -divider MISC
|
||||
add wave -noupdate /L1_rtps_builtin_endpoint_test1/uut/update_participant_flags
|
||||
add wave -noupdate -radix unsigned /L1_rtps_builtin_endpoint_test1/uut/seq_nr
|
||||
add wave -noupdate -group FIFO -radix hexadecimal /L1_rtps_builtin_endpoint_test1/fifo_inst/data_in
|
||||
add wave -noupdate -group FIFO /L1_rtps_builtin_endpoint_test1/fifo_inst/write
|
||||
add wave -noupdate -group FIFO /L1_rtps_builtin_endpoint_test1/fifo_inst/full
|
||||
add wave -noupdate -group FIFO -radix hexadecimal /L1_rtps_builtin_endpoint_test1/fifo_inst/data_out
|
||||
add wave -noupdate -group FIFO /L1_rtps_builtin_endpoint_test1/fifo_inst/read
|
||||
add wave -noupdate -group FIFO /L1_rtps_builtin_endpoint_test1/fifo_inst/empty
|
||||
add wave -noupdate -group RTPS_OUT -radix hexadecimal /L1_rtps_builtin_endpoint_test1/rtps_out_inst/data_in
|
||||
add wave -noupdate -group RTPS_OUT /L1_rtps_builtin_endpoint_test1/rtps_out_inst/last_word_in
|
||||
add wave -noupdate -group RTPS_OUT /L1_rtps_builtin_endpoint_test1/rtps_out_inst/rd
|
||||
add wave -noupdate -group RTPS_OUT /L1_rtps_builtin_endpoint_test1/rtps_out_inst/empty
|
||||
add wave -noupdate -group RTPS_OUT -radix hexadecimal /L1_rtps_builtin_endpoint_test1/rtps_out_inst/data_out
|
||||
add wave -noupdate -group RTPS_OUT /L1_rtps_builtin_endpoint_test1/rtps_out_inst/wr
|
||||
add wave -noupdate -group RTPS_OUT /L1_rtps_builtin_endpoint_test1/rtps_out_inst/full
|
||||
add wave -noupdate -group RTPS_OUT /L1_rtps_builtin_endpoint_test1/rtps_out_inst/selector
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/alive
|
||||
add wave -noupdate /l1_rtps_builtin_endpoint_test1/uut/endpoint_alive
|
||||
add wave -noupdate -radix unsigned -childformat {{/l1_rtps_builtin_endpoint_test1/uut/seq_nr(0) -radix unsigned} {/l1_rtps_builtin_endpoint_test1/uut/seq_nr(1) -radix unsigned}} -subitemconfig {/l1_rtps_builtin_endpoint_test1/uut/seq_nr(0) {-radix unsigned} /l1_rtps_builtin_endpoint_test1/uut/seq_nr(1) {-radix unsigned}} /l1_rtps_builtin_endpoint_test1/uut/seq_nr
|
||||
add wave -noupdate -group FIFO -radix hexadecimal /l1_rtps_builtin_endpoint_test1/fifo_inst/data_in
|
||||
add wave -noupdate -group FIFO /l1_rtps_builtin_endpoint_test1/fifo_inst/write
|
||||
add wave -noupdate -group FIFO /l1_rtps_builtin_endpoint_test1/fifo_inst/full
|
||||
add wave -noupdate -group FIFO -radix hexadecimal /l1_rtps_builtin_endpoint_test1/fifo_inst/data_out
|
||||
add wave -noupdate -group FIFO /l1_rtps_builtin_endpoint_test1/fifo_inst/read
|
||||
add wave -noupdate -group FIFO /l1_rtps_builtin_endpoint_test1/fifo_inst/empty
|
||||
add wave -noupdate -group RTPS_OUT -radix hexadecimal /l1_rtps_builtin_endpoint_test1/rtps_out_inst/data_in
|
||||
add wave -noupdate -group RTPS_OUT /l1_rtps_builtin_endpoint_test1/rtps_out_inst/last_word_in
|
||||
add wave -noupdate -group RTPS_OUT /l1_rtps_builtin_endpoint_test1/rtps_out_inst/rd
|
||||
add wave -noupdate -group RTPS_OUT /l1_rtps_builtin_endpoint_test1/rtps_out_inst/empty
|
||||
add wave -noupdate -group RTPS_OUT -radix hexadecimal /l1_rtps_builtin_endpoint_test1/rtps_out_inst/data_out
|
||||
add wave -noupdate -group RTPS_OUT /l1_rtps_builtin_endpoint_test1/rtps_out_inst/wr
|
||||
add wave -noupdate -group RTPS_OUT /l1_rtps_builtin_endpoint_test1/rtps_out_inst/full
|
||||
add wave -noupdate -group RTPS_OUT /l1_rtps_builtin_endpoint_test1/rtps_out_inst/selector
|
||||
add wave -noupdate -divider TESTBENCH
|
||||
add wave -noupdate -group TESTBENCH /l1_rtps_builtin_endpoint_test1/start
|
||||
add wave -noupdate -group TESTBENCH /l1_rtps_builtin_endpoint_test1/stim_stage
|
||||
add wave -noupdate -group TESTBENCH /l1_rtps_builtin_endpoint_test1/stimulus.length
|
||||
add wave -noupdate -group TESTBENCH /l1_rtps_builtin_endpoint_test1/cnt_stim
|
||||
add wave -noupdate -group TESTBENCH /l1_rtps_builtin_endpoint_test1/packet_sent
|
||||
TreeUpdate [SetDefaultTree]
|
||||
WaveRestoreCursors {Begin {31125000 ps} 1} {Error {50874035 ps} 1} {Cursor {28075000 ps} 0}
|
||||
WaveRestoreCursors {Begin {31125000 ps} 1} {Error {36375000 ps} 1} {Cursor {36411652 ps} 0}
|
||||
quietly wave cursor active 2
|
||||
configure wave -namecolwidth 149
|
||||
configure wave -valuecolwidth 144
|
||||
@ -78,4 +86,4 @@ configure wave -griddelta 40
|
||||
configure wave -timeline 0
|
||||
configure wave -timelineunits ns
|
||||
update
|
||||
WaveRestoreZoom {50582404 ps} {51730746 ps}
|
||||
WaveRestoreZoom {35541123 ps} {36689465 ps}
|
||||
|
||||
57
src/REF.txt
57
src/REF.txt
@ -189,54 +189,55 @@ PARTICICPANT DATA
|
||||
31............24..............16..............8...............0
|
||||
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|
||||
+-------------------------------------------------------------+
|
||||
00| |
|
||||
+ +
|
||||
01| GUIDPREFIX |
|
||||
+ +
|
||||
02| |
|
||||
00| NEXT_ADDRESS |
|
||||
+-------------------------------------------------------------+
|
||||
03| META_IPv4_ADDRESS |
|
||||
01| |
|
||||
+ +
|
||||
02| GUIDPREFIX |
|
||||
+ +
|
||||
03| |
|
||||
+-------------------------------------------------------------+
|
||||
04| DEFAULT_IPv4_ADDRESS |
|
||||
04| META_IPv4_ADDRESS |
|
||||
+-------------------------------------------------------------+
|
||||
05| DEFAULT_IPv4_ADDRESS |
|
||||
+-----------------------------+-------------------------------+
|
||||
05| META_UDP_PORT | DEFAULT_UDP_PORT |
|
||||
06| META_UDP_PORT | DEFAULT_UDP_PORT |
|
||||
+-----------------------------+-------------------------------+
|
||||
06| |
|
||||
+ SPDP_SEQ_NR +
|
||||
07| |
|
||||
+-------------------------------------------------------------+
|
||||
+ SPDP_SEQ_NR +
|
||||
08| |
|
||||
+ LEASE_DURATION +
|
||||
+-------------------------------------------------------------+
|
||||
09| |
|
||||
+-------------------------------------------------------------+
|
||||
+ LEASE_DURATION +
|
||||
10| |
|
||||
+ LEASE_DEADLINE +
|
||||
+-------------------------------------------------------------+
|
||||
11| |
|
||||
+-----------------------------------------------------+-+-+-+-+
|
||||
12| UNUSED |P|S|M|Q|
|
||||
+-----------------------------------------------------+-+-+-+-+
|
||||
13| |
|
||||
+ ACKNACK_RES_TIME +
|
||||
+ LEASE_DEADLINE +
|
||||
12| |
|
||||
+-------------------------------------------------------+-+-+-+
|
||||
13| UNUSED |P|S|M|
|
||||
+-------------------------------------------------------+-+-+-+
|
||||
14| |
|
||||
+-------------------------------------------------------------+
|
||||
+ ACKNACK_RES_TIME +
|
||||
15| |
|
||||
+ HEARTBEAT_RES_TIME +
|
||||
+-------------------------------------------------------------+
|
||||
16| |
|
||||
+-------------------------------------------------------------+
|
||||
+ HEARTBEAT_RES_TIME +
|
||||
17| |
|
||||
+ PUBLICATION_SEQ_NR +
|
||||
+-------------------------------------------------------------+
|
||||
18| |
|
||||
+-------------------------------------------------------------+
|
||||
+ PUBLICATION_SEQ_NR +
|
||||
19| |
|
||||
+ SUBSCRIPTION_SEQ_NR +
|
||||
20| |
|
||||
+-------------------------------------------------------------+
|
||||
20| |
|
||||
+ SUBSCRIPTION_SEQ_NR +
|
||||
21| |
|
||||
+ MESSAGE_SEQ_NR +
|
||||
+-------------------------------------------------------------+
|
||||
22| |
|
||||
+ MESSAGE_SEQ_NR +
|
||||
23| |
|
||||
+-------------------------------------------------------------+
|
||||
|
||||
Q...Reader expects in-line QoS
|
||||
M...Send Message Data (Liveliness Update)
|
||||
S...Send Subriber Data
|
||||
P...Send Publisher Data
|
||||
|
||||
@ -82,6 +82,7 @@
|
||||
* Since the Instance Handle has to be Unique but also orderable, we could use the actual Instance Memory Base Address. Since the Instances are in a list, we also have implicitly an order to all registered Instances. [It may be necessary to add a PREV pointer to the IMF to better support the read_previous_isntance operation]
|
||||
* Does the DEADLINE_QOS apply also to NOT_ALIVE Instances? (Current implementation makes no distinction)
|
||||
* Does TIME_BASED_FILTER also apply to meta-samples (DISPOSED, NO_WRITERS)? That is an easy way to not get convergent state in different DDS Readers. What do other implementations do?
|
||||
* In rtps_builtin_endpoint we initiate a participant memory search ASAP (in the PACKET_SRC_GUIDPREFIX stage). Further down we branch to several different branches, which each needing different Participant Data Fields. Currently we are fetching ALL needed Fields from ALL branches. Would it make sense to delay the search until the PACKET_DEST_ENTITYID/CHECK_SRC_ENTITYID stage, and only fetch the relevant Fields?
|
||||
|
||||
* Fast-RTPS does not follow DDSI-RTPS Specification
|
||||
- Open Github Issue
|
||||
|
||||
@ -18,6 +18,7 @@ use work.rtps_test_package.all;
|
||||
-- * Unmatching previously matched Participants (Due to incompatibility)
|
||||
-- * Update data of previously matched Participant
|
||||
-- * Big/Little Endian Participant Data
|
||||
-- * Memory Full Behaviour
|
||||
|
||||
|
||||
entity L0_rtps_builtin_endpoint_test1 is
|
||||
@ -44,9 +45,24 @@ architecture testbench of L0_rtps_builtin_endpoint_test1 is
|
||||
signal start : std_logic := '0';
|
||||
shared variable SB_out : work.ScoreBoardPkg_builtin_endpoint.ScoreBoardPType;
|
||||
shared variable SB_mem : work.ScoreBoardPkg_MemoryTest.ScoreBoardPType;
|
||||
signal stim_done, check_done : std_logic := '0';
|
||||
signal stim_done, mem_check_done, check_done, test_done : std_logic := '0';
|
||||
|
||||
-- *FUNCTION DECLARATION*
|
||||
procedure wait_on_complete is
|
||||
begin
|
||||
if (test_done /= '1') then
|
||||
wait until test_done = '1';
|
||||
end if;
|
||||
end procedure;
|
||||
|
||||
procedure wait_on_mem_check is
|
||||
begin
|
||||
if (mem_check_done /= '1') then
|
||||
wait until mem_check_done = '1';
|
||||
end if;
|
||||
end procedure;
|
||||
|
||||
procedure wait_on_sent is
|
||||
begin
|
||||
wait until rising_edge(packet_sent);
|
||||
end procedure;
|
||||
@ -79,7 +95,8 @@ begin
|
||||
variable rtps_sub : RTPS_SUBMESSAGE_TYPE := DEFAULT_RTPS_SUBMESSAGE;
|
||||
variable RV : RandomPType;
|
||||
variable participant : PARTICIPANT_DATA_TYPE := DEFAULT_PARTICIPANT_DATA;
|
||||
variable p0, p1, p2 : GUIDPREFIX_TYPE;
|
||||
variable m0, m1, m2 : PARTICIPANT_DATA_TYPE := DEFAULT_PARTICIPANT_DATA;
|
||||
variable p0, p1, p2, p3 : GUIDPREFIX_TYPE;
|
||||
|
||||
-- Wrapper to use procedure as function
|
||||
impure function gen_rand_loc_2 return LOCATOR_TYPE is
|
||||
@ -135,6 +152,7 @@ begin
|
||||
p0 := gen_rand_guid_prefix;
|
||||
p1 := gen_rand_guid_prefix;
|
||||
p2 := gen_rand_guid_prefix;
|
||||
p3 := gen_rand_guid_prefix;
|
||||
|
||||
|
||||
Log("Initiating Test", INFO);
|
||||
@ -143,6 +161,7 @@ begin
|
||||
wait until rising_edge(clk);
|
||||
wait until rising_edge(clk);
|
||||
reset <= '0';
|
||||
-- MEMORY STATE: -/0,1,2
|
||||
|
||||
Log("Match Participant 0 [Compatible]", INFO);
|
||||
participant := DEFAULT_PARTICIPANT_DATA;
|
||||
@ -154,16 +173,18 @@ begin
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_ANNOUNCER):= '1';
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_DETECTOR) := '1';
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_ANNOUNCER) := '1';
|
||||
m0 := participant;
|
||||
gen_participant_data(participant, rtps_sub.data);
|
||||
gen_sentinel(rtps_sub.data);
|
||||
gen_rtps_handler_out(rtps_sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
rtps_sub.data := EMPTY_TEST_PACKET;
|
||||
rtps_sub.writerSN := rtps_sub.writerSN + 1;
|
||||
-- MEMORY STATE [p0,0,0]
|
||||
-- MEMORY STATE: 0(p0)/1,2
|
||||
|
||||
Log("Match Participant 1 [Compatible, Little Endian]", INFO);
|
||||
participant := DEFAULT_PARTICIPANT_DATA;
|
||||
@ -176,16 +197,18 @@ begin
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_ANNOUNCER):= '1';
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_DETECTOR) := '1';
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_ANNOUNCER) := '1';
|
||||
m1 := participant;
|
||||
gen_participant_data(participant, rtps_sub.data);
|
||||
gen_sentinel(rtps_sub.data);
|
||||
gen_rtps_handler_out(rtps_sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
rtps_sub.data := EMPTY_TEST_PACKET;
|
||||
rtps_sub.writerSN := rtps_sub.writerSN + 1;
|
||||
-- MEMORY STATE [p0,p1,0]
|
||||
-- MEMORY STATE: 1(p1),0(p0)/2
|
||||
|
||||
Log("Ignore Participant 2 [Incompatible Domain ID]", INFO);
|
||||
participant := DEFAULT_PARTICIPANT_DATA;
|
||||
@ -201,13 +224,13 @@ begin
|
||||
gen_participant_data(participant, rtps_sub.data);
|
||||
gen_sentinel(rtps_sub.data);
|
||||
gen_rtps_handler_out(rtps_sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
rtps_sub.data := EMPTY_TEST_PACKET;
|
||||
rtps_sub.writerSN := rtps_sub.writerSN + 1;
|
||||
-- MEMORY STATE [p0,p1,0]
|
||||
-- MEMORY STATE: 1(p1),0(p0)/2
|
||||
|
||||
Log("Unmatch Participant 0 [Incompatible Domain ID]", INFO);
|
||||
participant := DEFAULT_PARTICIPANT_DATA;
|
||||
@ -220,17 +243,19 @@ begin
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_ANNOUNCER):= '1';
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_DETECTOR) := '1';
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_ANNOUNCER) := '1';
|
||||
m0 := DEFAULT_PARTICIPANT_DATA;
|
||||
gen_participant_data(participant, rtps_sub.data);
|
||||
gen_sentinel(rtps_sub.data);
|
||||
gen_rtps_handler_out(rtps_sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
push_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
rtps_sub.data := EMPTY_TEST_PACKET;
|
||||
rtps_sub.writerSN := rtps_sub.writerSN + 1;
|
||||
-- MEMORY STATE [0,p1,0]
|
||||
-- MEMORY STATE: 1(p1)/0,2
|
||||
|
||||
|
||||
Log("Ignore Participant 2 [Incompatible Domain TAG]", INFO);
|
||||
participant := DEFAULT_PARTICIPANT_DATA;
|
||||
@ -246,13 +271,13 @@ begin
|
||||
gen_participant_data(participant, rtps_sub.data);
|
||||
gen_sentinel(rtps_sub.data);
|
||||
gen_rtps_handler_out(rtps_sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
rtps_sub.data := EMPTY_TEST_PACKET;
|
||||
rtps_sub.writerSN := rtps_sub.writerSN + 1;
|
||||
-- MEMORY STATE [0,p1,0]
|
||||
-- MEMORY STATE: 1(p1)/0,2
|
||||
|
||||
Log("Unmatch Participant 1 [Incompatible Domain TAG]", INFO);
|
||||
participant := DEFAULT_PARTICIPANT_DATA;
|
||||
@ -268,19 +293,19 @@ begin
|
||||
gen_participant_data(participant, rtps_sub.data);
|
||||
gen_sentinel(rtps_sub.data);
|
||||
gen_rtps_handler_out(rtps_sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
push_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
rtps_sub.data := EMPTY_TEST_PACKET;
|
||||
rtps_sub.writerSN := rtps_sub.writerSN + 1;
|
||||
-- MEMORY STATE [0,0,0]
|
||||
-- MEMORY STATE: -/1,0,2
|
||||
|
||||
Log("Match Participant 0 [+Unicast Metatraffic Locator]", INFO);
|
||||
participant := DEFAULT_PARTICIPANT_DATA;
|
||||
participant.guidPrefix := p0;
|
||||
participant.nr := 0;
|
||||
participant.nr := 1;
|
||||
participant.match := MATCH;
|
||||
participant.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
participant.metatrafficUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
@ -288,21 +313,23 @@ begin
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_ANNOUNCER):= '1';
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_DETECTOR) := '1';
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_ANNOUNCER) := '1';
|
||||
m1 := participant;
|
||||
gen_participant_data(participant, rtps_sub.data);
|
||||
gen_sentinel(rtps_sub.data);
|
||||
gen_rtps_handler_out(rtps_sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
rtps_sub.data := EMPTY_TEST_PACKET;
|
||||
rtps_sub.writerSN := rtps_sub.writerSN + 1;
|
||||
-- MEMORY STATE [p0,0,0]
|
||||
-- MEMORY STATE: 1(p0)/0,2
|
||||
|
||||
Log("Match Participant 1 [ALL Values Set non default]", INFO);
|
||||
participant := DEFAULT_PARTICIPANT_DATA;
|
||||
participant.guidPrefix := p1;
|
||||
participant.nr := 1;
|
||||
participant.nr := 0;
|
||||
participant.vendorId := RV.RandSlv(VENDORID_WIDTH);
|
||||
participant.expectsInlineQoS(0) := '1';
|
||||
participant.leaseDuration := gen_duration(5,500);
|
||||
@ -317,16 +344,18 @@ begin
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_ANNOUNCER):= '1';
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_DETECTOR) := '1';
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_ANNOUNCER) := '1';
|
||||
m0 := participant;
|
||||
gen_participant_data(participant, rtps_sub.data);
|
||||
gen_sentinel(rtps_sub.data);
|
||||
gen_rtps_handler_out(rtps_sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
rtps_sub.data := EMPTY_TEST_PACKET;
|
||||
rtps_sub.writerSN := rtps_sub.writerSN + 1;
|
||||
-- MEMORY STATE [p0,p1,0]
|
||||
-- MEMORY STATE: 0(p1),1(p0)/2
|
||||
|
||||
Log("Ignore Participant 2 [Incompatible Protocol Version]", INFO);
|
||||
participant := DEFAULT_PARTICIPANT_DATA;
|
||||
@ -342,13 +371,13 @@ begin
|
||||
gen_participant_data(participant, rtps_sub.data);
|
||||
gen_sentinel(rtps_sub.data);
|
||||
gen_rtps_handler_out(rtps_sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
rtps_sub.data := EMPTY_TEST_PACKET;
|
||||
rtps_sub.writerSN := rtps_sub.writerSN + 1;
|
||||
-- MEMORY STATE [p0,p1,0]
|
||||
-- MEMORY STATE: 0(p1),1(p0)/2
|
||||
|
||||
Log("Unmatch Participant 0 [Incompatible Protocol Version]", INFO);
|
||||
participant := DEFAULT_PARTICIPANT_DATA;
|
||||
@ -361,36 +390,39 @@ begin
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_ANNOUNCER):= '1';
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_DETECTOR) := '1';
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_ANNOUNCER) := '1';
|
||||
m1 := DEFAULT_PARTICIPANT_DATA;
|
||||
gen_participant_data(participant, rtps_sub.data);
|
||||
gen_sentinel(rtps_sub.data);
|
||||
gen_rtps_handler_out(rtps_sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
push_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
rtps_sub.data := EMPTY_TEST_PACKET;
|
||||
rtps_sub.writerSN := rtps_sub.writerSN + 1;
|
||||
-- MEMORY STATE [0,p1,0]
|
||||
-- MEMORY STATE: 0(p1)/1,2
|
||||
|
||||
Log("Match Participant 0 [Compatible, Only Subscribers]", INFO);
|
||||
participant := DEFAULT_PARTICIPANT_DATA;
|
||||
participant.guidPrefix := p0;
|
||||
participant.nr := 0;
|
||||
participant.nr := 1;
|
||||
participant.match := MATCH;
|
||||
participant.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_ANNOUNCER):= '1';
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_DETECTOR) := '1';
|
||||
m1 := participant;
|
||||
gen_participant_data(participant, rtps_sub.data);
|
||||
gen_sentinel(rtps_sub.data);
|
||||
gen_rtps_handler_out(rtps_sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
rtps_sub.data := EMPTY_TEST_PACKET;
|
||||
rtps_sub.writerSN := rtps_sub.writerSN + 1;
|
||||
-- MEMORY STATE [p0,p1,0]
|
||||
-- MEMORY STATE: 1(p0),0(p1)/2
|
||||
|
||||
Log("Match Participant 2 [Compatible, Only Publishers]", INFO);
|
||||
participant := DEFAULT_PARTICIPANT_DATA;
|
||||
@ -400,21 +432,23 @@ begin
|
||||
participant.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_ANNOUNCER) := '1';
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_DETECTOR) := '1';
|
||||
m2 := participant;
|
||||
gen_participant_data(participant, rtps_sub.data);
|
||||
gen_sentinel(rtps_sub.data);
|
||||
gen_rtps_handler_out(rtps_sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
rtps_sub.data := EMPTY_TEST_PACKET;
|
||||
rtps_sub.writerSN := rtps_sub.writerSN + 1;
|
||||
-- MEMORY STATE [p0,p1,p2]
|
||||
-- MEMORY STATE: 2(p2),1(p0),0(p1)/-
|
||||
|
||||
Log("Update Participant 1 [Valid/Invalid Default/Metatraffic Locators]", INFO);
|
||||
participant := DEFAULT_PARTICIPANT_DATA;
|
||||
participant.guidPrefix := p1;
|
||||
participant.nr := 1;
|
||||
participant.nr := 0;
|
||||
participant.match := MATCH;
|
||||
participant.defaultUnicastLocatorList := (numLocators => int(4,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, 1 => gen_rand_loc_2, 2 => gen_rand_loc_2, 3 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
participant.defaultUnicastLocatorList.locator(1).kind := LOCATOR_KIND_UDPv6;
|
||||
@ -434,16 +468,42 @@ begin
|
||||
participant.metatrafficMulticastLocatorList.locator(3).addr := (others => '0');
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_ANNOUNCER) := '1';
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_DETECTOR) := '1';
|
||||
m0 := participant;
|
||||
gen_participant_data(participant, rtps_sub.data);
|
||||
gen_sentinel(rtps_sub.data);
|
||||
gen_rtps_handler_out(rtps_sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
rtps_sub.data := EMPTY_TEST_PACKET;
|
||||
rtps_sub.writerSN := rtps_sub.writerSN + 1;
|
||||
-- MEMORY STATE: 2(p2),1(p0),0(p1)/-
|
||||
|
||||
Log("Ignore Participant 3 [Memory Full]", INFO);
|
||||
participant := DEFAULT_PARTICIPANT_DATA;
|
||||
participant.guidPrefix := p3;
|
||||
participant.nr := 0;
|
||||
participant.match := MATCH;
|
||||
participant.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_DETECTOR) := '1';
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_ANNOUNCER):= '1';
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_DETECTOR) := '1';
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_ANNOUNCER) := '1';
|
||||
gen_participant_data(participant, rtps_sub.data);
|
||||
gen_sentinel(rtps_sub.data);
|
||||
gen_rtps_handler_out(rtps_sub, participant, stimulus);
|
||||
-- Re-Check Memory
|
||||
SB_mem.Push(gen_participant_mem_frame(m0));
|
||||
SB_mem.Push(gen_participant_mem_frame(m1));
|
||||
SB_mem.Push(gen_participant_mem_frame(m2));
|
||||
start_test;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
rtps_sub.data := EMPTY_TEST_PACKET;
|
||||
rtps_sub.writerSN := rtps_sub.writerSN + 1;
|
||||
-- MEMORY STATE [p0,p1,p2]
|
||||
|
||||
Log("Unmatch Participant 2 [No Endpoints]", INFO);
|
||||
participant := DEFAULT_PARTICIPANT_DATA;
|
||||
@ -451,17 +511,18 @@ begin
|
||||
participant.nr := 2;
|
||||
participant.match := UNMATCH;
|
||||
participant.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
m2 := DEFAULT_PARTICIPANT_DATA;
|
||||
gen_participant_data(participant, rtps_sub.data);
|
||||
gen_sentinel(rtps_sub.data);
|
||||
gen_rtps_handler_out(rtps_sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
push_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
rtps_sub.data := EMPTY_TEST_PACKET;
|
||||
rtps_sub.writerSN := rtps_sub.writerSN + 1;
|
||||
-- MEMORY STATE [p0,p1,0]
|
||||
-- MEMORY STATE: 1(p0),0(p1)/2
|
||||
|
||||
Log("Unmatch Participant 0 [Incompatible Built-in Endpoints]", INFO);
|
||||
participant := DEFAULT_PARTICIPANT_DATA;
|
||||
@ -471,31 +532,23 @@ begin
|
||||
participant.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_DETECTOR) := '1';
|
||||
participant.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_DETECTOR) := '1';
|
||||
m1 := DEFAULT_PARTICIPANT_DATA;
|
||||
gen_participant_data(participant, rtps_sub.data);
|
||||
gen_sentinel(rtps_sub.data);
|
||||
gen_rtps_handler_out(rtps_sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
push_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
rtps_sub.data := EMPTY_TEST_PACKET;
|
||||
rtps_sub.writerSN := rtps_sub.writerSN + 1;
|
||||
-- MEMORY STATE [0,p1,0]
|
||||
|
||||
-- DUMMY PACKET (Trigger last mem check)
|
||||
-- Mark Packet as non-standard Payload, in order to trigger the packet to be skipped (as early as possible)
|
||||
rtps_sub.data := EMPTY_TEST_PACKET;
|
||||
rtps_sub.flags(SUBMESSAGE_NON_STANDARD_PAYLOAD_FLAG_POS):= '1';
|
||||
gen_rtps_handler_out(rtps_sub, participant, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
-- MEMORY STATE: 0(p1)/1,2
|
||||
|
||||
stim_done <= '1';
|
||||
wait until check_done = '1';
|
||||
wait_on_complete;
|
||||
TranscriptOpen(RESULTS_FILE, APPEND_MODE);
|
||||
SetTranscriptMirror;
|
||||
AlertIf((not SB_out.empty) or (not SB_mem.empty), "Incomplete test run");
|
||||
ReportAlerts;
|
||||
TranscriptClose;
|
||||
std.env.stop;
|
||||
@ -570,39 +623,59 @@ begin
|
||||
|
||||
output_check_prc : process(all)
|
||||
begin
|
||||
check_done <= '0';
|
||||
if rising_edge(clk) then
|
||||
if (endpoint_wr /= (0 to NUM_ENDPOINTS-1 => '0')) then
|
||||
SB_out.Check(endpoint_wr & last_word_out & data_out);
|
||||
end if;
|
||||
if (stim_done = '1' and SB_out.empty) then
|
||||
check_done <= '1';
|
||||
else
|
||||
check_done <= '0';
|
||||
end if;
|
||||
end if;
|
||||
end process;
|
||||
|
||||
done_proc : process(clk)
|
||||
begin
|
||||
if rising_edge(clk) then
|
||||
if (stim_done = '1' and SB_mem.empty and check_done = '1') then
|
||||
test_done <= '1';
|
||||
else
|
||||
test_done <= '0';
|
||||
end if;
|
||||
end if;
|
||||
end process;
|
||||
|
||||
mem_check_prc : process
|
||||
alias mem is <<signal uut.ram_inst.mem : TEST_RAM_TYPE>>;
|
||||
alias mem is <<signal uut.mem_ctrl_inst.ram_inst.mem : TEST_RAM_TYPE>>;
|
||||
alias mem_op_done is <<signal uut.mem_op_done : std_logic>>;
|
||||
alias idle_sig is <<signal uut.idle_sig : std_logic>>;
|
||||
variable reference : TEST_PARTICIPANT_MEMORY_FRAME_TYPE;
|
||||
begin
|
||||
mem_check_done <= '0';
|
||||
-- SAFEGUARD: (Prevent Fall-through Behavior)
|
||||
if (reset /= '0') then
|
||||
wait until reset = '0';
|
||||
end if;
|
||||
-- NOTE: The first read after the packet is sent signifies that the State Machine has begun processing the next packet.
|
||||
-- The memory operation that could still be in progress is the last one concerning the last sent packet.
|
||||
wait until packet_sent = '1';
|
||||
wait until rising_edge(rd_sig);
|
||||
-- Wait for Packet to be sent
|
||||
wait until rising_edge(packet_sent);
|
||||
-- Wait for UUT IDLE state
|
||||
if (idle_sig /= '1') then
|
||||
wait until idle_sig = '1';
|
||||
end if;
|
||||
-- Wait for ongoing memory operation
|
||||
if (mem_op_done /= '1') then
|
||||
wait until mem_op_done = '1';
|
||||
end if;
|
||||
if (not SB_mem.empty) then
|
||||
while (not SB_mem.empty) loop
|
||||
SB_mem.Pop(reference);
|
||||
for i in 0 to reference'length-1 loop
|
||||
AffirmIf(?? (mem(reference(i).addr) ?= reference(i).data), "Address: " & integer'image(reference(i).addr) & " Received: " & to_hstring(mem(reference(i).addr)) & " Expected: " & to_hstring(reference(i).data));
|
||||
end loop;
|
||||
end if;
|
||||
end loop;
|
||||
-- Toggle High for one clock cycle
|
||||
mem_check_done <= '1';
|
||||
wait until rising_edge(clk);
|
||||
end process;
|
||||
|
||||
watchdog : process
|
||||
|
||||
@ -11,8 +11,10 @@ use work.rtps_config_package.all;
|
||||
use work.rtps_test_package.all;
|
||||
|
||||
-- This testbench tests the input handling of parameter lists. We issue one parameter list with invalid parameter length (less than expected)
|
||||
-- and one with valid larger parameter length (extra Bytes after expected parameter end) for each of the parameters that are handled by the built-in endpoint.
|
||||
-- We also issue a parameter list that is missing its sentinel.
|
||||
-- and one with valid larger parameter length (extra Bytes after expected parameter end) for each of the parameters that are handled by the built-in endpoint by checking if the Participant/Endpoint matched.
|
||||
-- (We also issue a parameter list that is missing its sentinel)
|
||||
-- Particpant matches are checked by memory content, and Endpoint matches by match frame
|
||||
-- The Participant
|
||||
-- The PIDs handled are:
|
||||
-- * PID_PARTICIPANT_GUID
|
||||
-- * PID_DOMAIN_ID
|
||||
@ -64,10 +66,24 @@ architecture testbench of L0_rtps_builtin_endpoint_test3 is
|
||||
signal start : std_logic := '0';
|
||||
shared variable SB_out : work.ScoreBoardPkg_builtin_endpoint.ScoreBoardPType;
|
||||
shared variable SB_mem : work.ScoreBoardPkg_MemoryTest.ScoreBoardPType;
|
||||
signal stim_done, check_done, mem_check : std_logic := '0';
|
||||
signal stim_done, check_done, mem_check_done, test_done : std_logic := '0';
|
||||
|
||||
-- *FUNCTION DECLARATION*
|
||||
procedure wait_on_complete is
|
||||
begin
|
||||
if (test_done /= '1') then
|
||||
wait until test_done = '1';
|
||||
end if;
|
||||
end procedure;
|
||||
|
||||
procedure wait_on_mem_check is
|
||||
begin
|
||||
if (mem_check_done /= '1') then
|
||||
wait until mem_check_done = '1';
|
||||
end if;
|
||||
end procedure;
|
||||
|
||||
procedure wait_on_sent is
|
||||
begin
|
||||
wait until rising_edge(packet_sent);
|
||||
end procedure;
|
||||
@ -163,7 +179,6 @@ begin
|
||||
start <= '1';
|
||||
wait until rising_edge(clk);
|
||||
start <= '0';
|
||||
mem_check <= '0';
|
||||
wait until rising_edge(clk);
|
||||
end procedure;
|
||||
begin
|
||||
@ -217,7 +232,6 @@ begin
|
||||
e0.type_name := ENDPOINT_TYPE(0);
|
||||
|
||||
Log("Initiating Test", INFO);
|
||||
mem_check <= '1';
|
||||
stim_done <= '0';
|
||||
start <= '0';
|
||||
reset <= '1';
|
||||
@ -233,8 +247,8 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -250,10 +264,9 @@ begin
|
||||
gen_participant_data(participant, sub.data, PID_PARTICIPANT_GUID, -1);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -270,8 +283,8 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -287,10 +300,9 @@ begin
|
||||
gen_participant_data(participant, sub.data, PID_DOMAIN_ID, -1);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -307,8 +319,8 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -324,10 +336,9 @@ begin
|
||||
gen_participant_data(participant, sub.data, PID_DOMAIN_TAG, -1);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -344,8 +355,8 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -361,10 +372,9 @@ begin
|
||||
gen_participant_data(participant, sub.data, PID_PROTOCOL_VERSION, -1);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -381,8 +391,8 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -398,10 +408,9 @@ begin
|
||||
gen_participant_data(participant, sub.data, PID_PARTICIPANT_LEASE_DURATION, -1);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -418,8 +427,8 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -435,10 +444,9 @@ begin
|
||||
gen_participant_data(participant, sub.data, PID_BUILTIN_ENDPOINT_SET, -1);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -455,8 +463,8 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -473,10 +481,9 @@ begin
|
||||
gen_participant_data(participant, sub.data, PID_DEFAULT_UNICAST_LOCATOR, -1);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -494,8 +501,8 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -512,10 +519,9 @@ begin
|
||||
gen_participant_data(participant, sub.data, PID_DEFAULT_MULTICAST_LOCATOR, -1);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -533,8 +539,8 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -551,10 +557,9 @@ begin
|
||||
gen_participant_data(participant, sub.data, PID_METATRAFFIC_UNICAST_LOCATOR, -1);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -572,8 +577,8 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -590,10 +595,9 @@ begin
|
||||
gen_participant_data(participant, sub.data, PID_METATRAFFIC_MULTICAST_LOCATOR, -1);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -611,8 +615,8 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
@ -627,7 +631,8 @@ begin
|
||||
gen_endpoint_data(endpoint, sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -642,7 +647,8 @@ begin
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -658,7 +664,8 @@ begin
|
||||
wr_sig := (0 => '1', 9 => '1', 10 => '1', 15 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -674,7 +681,8 @@ begin
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -690,7 +698,8 @@ begin
|
||||
wr_sig := (0 => '1', 9 => '1', 10 => '1', 15 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -706,7 +715,8 @@ begin
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -722,7 +732,8 @@ begin
|
||||
wr_sig := (0 => '1', 9 => '1', 10 => '1', 15 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -738,7 +749,8 @@ begin
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -754,7 +766,8 @@ begin
|
||||
wr_sig := (0 => '1', 9 => '1', 10 => '1', 15 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -770,7 +783,8 @@ begin
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -786,7 +800,8 @@ begin
|
||||
wr_sig := (0 => '1', 9 => '1', 10 => '1', 15 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -802,7 +817,8 @@ begin
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -818,7 +834,8 @@ begin
|
||||
wr_sig := (0 => '1', 9 => '1', 10 => '1', 15 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -834,7 +851,8 @@ begin
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -850,7 +868,8 @@ begin
|
||||
wr_sig := (0 => '1', 9 => '1', 10 => '1', 15 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -866,7 +885,8 @@ begin
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -882,7 +902,8 @@ begin
|
||||
wr_sig := (0 => '1', 9 => '1', 10 => '1', 15 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -898,7 +919,8 @@ begin
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -914,7 +936,8 @@ begin
|
||||
wr_sig := (0 => '1', 9 => '1', 10 => '1', 15 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -930,7 +953,8 @@ begin
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -946,7 +970,8 @@ begin
|
||||
wr_sig := (0 => '1', 9 => '1', 10 => '1', 15 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -962,7 +987,8 @@ begin
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -978,7 +1004,8 @@ begin
|
||||
wr_sig := (0 => '1', 9 => '1', 10 => '1', 15 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -994,7 +1021,8 @@ begin
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -1010,7 +1038,8 @@ begin
|
||||
wr_sig := (0 => '1', 9 => '1', 10 => '1', 15 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -1027,7 +1056,8 @@ begin
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -1044,7 +1074,8 @@ begin
|
||||
wr_sig := (0 => '1', 9 => '1', 10 => '1', 15 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -1061,7 +1092,8 @@ begin
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -1078,7 +1110,8 @@ begin
|
||||
wr_sig := (0 => '1', 9 => '1', 10 => '1', 15 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -1095,7 +1128,8 @@ begin
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
@ -1112,17 +1146,17 @@ begin
|
||||
wr_sig := (0 => '1', 9 => '1', 10 => '1', 15 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
p_snp := p_snp + 1;
|
||||
|
||||
stim_done <= '1';
|
||||
wait_on_complete;
|
||||
TranscriptOpen(RESULTS_FILE, APPEND_MODE);
|
||||
SetTranscriptMirror;
|
||||
stim_done <= '1';
|
||||
wait until check_done = '1';
|
||||
AlertIf((not SB_out.empty) or (not SB_mem.empty), "Incomplete test run");
|
||||
ReportAlerts;
|
||||
TranscriptClose;
|
||||
std.env.stop;
|
||||
@ -1197,39 +1231,59 @@ begin
|
||||
|
||||
output_check_prc : process(all)
|
||||
begin
|
||||
check_done <= '0';
|
||||
if rising_edge(clk) then
|
||||
if (endpoint_wr /= (0 to NUM_ENDPOINTS-1 => '0')) then
|
||||
SB_out.Check(endpoint_wr & last_word_out & data_out);
|
||||
end if;
|
||||
if (stim_done = '1' and SB_out.empty) then
|
||||
check_done <= '1';
|
||||
else
|
||||
check_done <= '0';
|
||||
end if;
|
||||
end if;
|
||||
end process;
|
||||
|
||||
done_proc : process(clk)
|
||||
begin
|
||||
if rising_edge(clk) then
|
||||
if (stim_done = '1' and SB_mem.empty and check_done = '1') then
|
||||
test_done <= '1';
|
||||
else
|
||||
test_done <= '0';
|
||||
end if;
|
||||
end if;
|
||||
end process;
|
||||
|
||||
mem_check_prc : process
|
||||
alias mem is <<signal uut.ram_inst.mem : TEST_RAM_TYPE>>;
|
||||
alias mem is <<signal uut.mem_ctrl_inst.ram_inst.mem : TEST_RAM_TYPE>>;
|
||||
alias mem_op_done is <<signal uut.mem_op_done : std_logic>>;
|
||||
alias idle_sig is <<signal uut.idle_sig : std_logic>>;
|
||||
variable reference : TEST_PARTICIPANT_MEMORY_FRAME_TYPE;
|
||||
begin
|
||||
mem_check_done <= '0';
|
||||
-- SAFEGUARD: (Prevent Fall-through Behavior)
|
||||
if (reset /= '0') then
|
||||
wait until reset = '0';
|
||||
end if;
|
||||
-- NOTE: The first read after the packet is sent signifies that the State Machine has begun processing the next packet.
|
||||
-- The memory operation that could still be in progress is the last one concerning the last sent packet.
|
||||
wait on packet_sent until (packet_sent = '1' and mem_check = '1');
|
||||
wait until rising_edge(rd_sig);
|
||||
-- Wait for Packet to be sent
|
||||
wait until rising_edge(packet_sent);
|
||||
-- Wait for UUT IDLE state
|
||||
if (idle_sig /= '1') then
|
||||
wait until idle_sig = '1';
|
||||
end if;
|
||||
-- Wait for ongoing memory operation
|
||||
if (mem_op_done /= '1') then
|
||||
wait until mem_op_done = '1';
|
||||
end if;
|
||||
if (not SB_mem.empty) then
|
||||
while (not SB_mem.empty) loop
|
||||
SB_mem.Pop(reference);
|
||||
for i in 0 to reference'length-1 loop
|
||||
AffirmIf(?? (mem(reference(i).addr) ?= reference(i).data), "Address: " & integer'image(reference(i).addr) & " Received: " & to_hstring(mem(reference(i).addr)) & " Expected: " & to_hstring(reference(i).data));
|
||||
end loop;
|
||||
end if;
|
||||
end loop;
|
||||
-- Toggle High for one clock cycle
|
||||
mem_check_done <= '1';
|
||||
wait until rising_edge(clk);
|
||||
end process;
|
||||
|
||||
watchdog : process
|
||||
|
||||
@ -10,7 +10,7 @@ use work.user_config.all;
|
||||
use work.rtps_config_package.all;
|
||||
use work.rtps_test_package.all;
|
||||
|
||||
-- This testbench tests the internal memory handling of the rtps_builtin_endpoint. (Full Capacity behaviour)
|
||||
-- This testbench tests the sequence number handling of the participant, subscriber, and publisher DATA Submessages.
|
||||
|
||||
entity L0_rtps_builtin_endpoint_test4 is
|
||||
end entity;
|
||||
@ -18,7 +18,7 @@ end entity;
|
||||
architecture testbench of L0_rtps_builtin_endpoint_test4 is
|
||||
|
||||
-- *CONSTANT DECLARATION*
|
||||
constant MAX_REMOTE_PARTICIPANTS : natural := 4;
|
||||
constant MAX_REMOTE_PARTICIPANTS : natural := 1;
|
||||
|
||||
-- *TYPE DECLARATION*
|
||||
type TEST_STAGE_TYPE is (IDLE, BUSY);
|
||||
@ -36,14 +36,36 @@ architecture testbench of L0_rtps_builtin_endpoint_test4 is
|
||||
signal start : std_logic := '0';
|
||||
shared variable SB_out : work.ScoreBoardPkg_builtin_endpoint.ScoreBoardPType;
|
||||
shared variable SB_mem : work.ScoreBoardPkg_MemoryTest.ScoreBoardPType;
|
||||
signal stim_done, check_done, mem_check : std_logic := '0';
|
||||
signal stim_done, mem_check_done, check_done, test_done : std_logic := '0';
|
||||
|
||||
-- *FUNCTION DECLARATION*
|
||||
procedure wait_on_complete is
|
||||
begin
|
||||
if (test_done /= '1') then
|
||||
wait until test_done = '1';
|
||||
end if;
|
||||
end procedure;
|
||||
|
||||
procedure wait_on_mem_check is
|
||||
begin
|
||||
if (mem_check_done /= '1') then
|
||||
wait until mem_check_done = '1';
|
||||
end if;
|
||||
end procedure;
|
||||
|
||||
procedure wait_on_sent is
|
||||
begin
|
||||
wait until rising_edge(packet_sent);
|
||||
end procedure;
|
||||
|
||||
function gen_sn(input : natural) return SEQUENCENUMBER_TYPE is
|
||||
variable ret : SEQUENCENUMBER_TYPE;
|
||||
begin
|
||||
ret(0) := (others => '0');
|
||||
ret(1) := unsigned(int(input, WORD_WIDTH));
|
||||
return ret;
|
||||
end function;
|
||||
|
||||
begin
|
||||
|
||||
-- Unit Under Test
|
||||
@ -69,10 +91,10 @@ begin
|
||||
);
|
||||
|
||||
stimulus_prc : process
|
||||
variable sub, sub_p : RTPS_SUBMESSAGE_TYPE := DEFAULT_RTPS_SUBMESSAGE;
|
||||
variable sub, sub_p, sub_s : RTPS_SUBMESSAGE_TYPE := DEFAULT_RTPS_SUBMESSAGE;
|
||||
variable RV : RandomPType;
|
||||
variable p0, p1, participant: PARTICIPANT_DATA_TYPE := DEFAULT_PARTICIPANT_DATA;
|
||||
variable e0, endpoint : ENDPOINT_DATA_TYPE := DEFAULT_ENDPOINT_DATA;
|
||||
variable p0, participant : PARTICIPANT_DATA_TYPE := DEFAULT_PARTICIPANT_DATA;
|
||||
variable e0, e1, endpoint : ENDPOINT_DATA_TYPE := DEFAULT_ENDPOINT_DATA;
|
||||
variable p_sn, p_snp : SEQUENCENUMBER_TYPE := FIRST_SEQUENCENUMBER;
|
||||
variable wr_sig : std_logic_vector(0 to NUM_ENDPOINTS-1) := (others => '0');
|
||||
|
||||
@ -135,14 +157,13 @@ begin
|
||||
start <= '1';
|
||||
wait until rising_edge(clk);
|
||||
start <= '0';
|
||||
mem_check <= '0';
|
||||
wait until rising_edge(clk);
|
||||
end procedure;
|
||||
begin
|
||||
|
||||
assert (TEST_STRING = "TEST_CONFIG_1") report "user_config incompatible with testbench." severity FAILURE;
|
||||
|
||||
SetAlertLogName("rtps_builtin_endpoint - Level 0 - Memory Handling");
|
||||
SetAlertLogName("rtps_builtin_endpoint - Level 0 - Sequence Number Handling");
|
||||
SetAlertEnable(FAILURE, TRUE);
|
||||
SetAlertEnable(ERROR, TRUE);
|
||||
SetAlertEnable(WARNING, TRUE);
|
||||
@ -165,6 +186,13 @@ begin
|
||||
sub_p.readerId := ENTITYID_SEDP_BUILTIN_PUBLICATIONS_DETECTOR;
|
||||
sub_p.flags(SUBMESSAGE_DATA_FLAG_POS) := '1';
|
||||
|
||||
-- Subscriber Endpoint RTPS Submessage
|
||||
sub_s := DEFAULT_RTPS_SUBMESSAGE;
|
||||
sub_s.submessageID := SID_DATA;
|
||||
sub_s.writerId := ENTITYID_SEDP_BUILTIN_SUBSCRIPTIONS_ANNOUNCER;
|
||||
sub_s.readerId := ENTITYID_SEDP_BUILTIN_SUBSCRIPTIONS_DETECTOR;
|
||||
sub_s.flags(SUBMESSAGE_DATA_FLAG_POS) := '1';
|
||||
|
||||
-- Participant 0
|
||||
p0.guidPrefix := gen_rand_guid_prefix;
|
||||
p0.nr := 0;
|
||||
@ -174,20 +202,19 @@ begin
|
||||
p0.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_DETECTOR) := '1';
|
||||
p0.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_ANNOUNCER) := '1';
|
||||
|
||||
p1.guidPrefix := gen_rand_guid_prefix;
|
||||
p1.nr := MAX_REMOTE_PARTICIPANTS;
|
||||
p1.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
p1.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_DETECTOR) := '1';
|
||||
p1.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_ANNOUNCER):= '1';
|
||||
p1.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_DETECTOR) := '1';
|
||||
p1.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_ANNOUNCER) := '1';
|
||||
|
||||
e0.participant := p0;
|
||||
e0.topic_name := ENDPOINT_TOPIC(2);
|
||||
e0.type_name := ENDPOINT_TYPE(2);
|
||||
e0.reader := FALSE;
|
||||
e0.entityId := gen_rand_entityid_2(FALSE);
|
||||
|
||||
e1.participant := p0;
|
||||
e1.topic_name := ENDPOINT_TOPIC(2);
|
||||
e1.type_name := ENDPOINT_TYPE(2);
|
||||
e1.reader := TRUE;
|
||||
e1.entityId := gen_rand_entityid_2(FALSE);
|
||||
|
||||
Log("Initiating Test", INFO);
|
||||
mem_check <= '1';
|
||||
stim_done <= '0';
|
||||
start <= '0';
|
||||
reset <= '1';
|
||||
@ -195,92 +222,209 @@ begin
|
||||
wait until rising_edge(clk);
|
||||
reset <= '0';
|
||||
|
||||
Log("Match Participant 0", INFO);
|
||||
sub.writerSN := p_sn;
|
||||
-- *PARTICIPANT*
|
||||
|
||||
Log("Match Participant 0 [SN 1]", INFO);
|
||||
sub.writerSN := gen_sn(1);
|
||||
participant := p0;
|
||||
participant.nr := 0;
|
||||
participant.match := MATCH;
|
||||
gen_participant_data(participant, sub.data);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
p_sn := p_sn + 1;
|
||||
|
||||
for i in 1 to MAX_REMOTE_PARTICIPANTS-1 loop
|
||||
Log("Match Participant " & to_string(i), INFO);
|
||||
sub.writerSN := p_sn;
|
||||
p0.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
|
||||
Log("Update Participant 0 [SN 2]", INFO);
|
||||
sub.writerSN := gen_sn(2);
|
||||
participant := p0;
|
||||
participant.guidPrefix := gen_rand_guid_prefix;
|
||||
participant.nr := i;
|
||||
participant.nr := 0;
|
||||
participant.match := MATCH;
|
||||
gen_participant_data(participant, sub.data);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
p_sn := p_sn + 1;
|
||||
end loop;
|
||||
|
||||
Log("Ignore Participant" & to_string(MAX_REMOTE_PARTICIPANTS) & " [No memory available]", INFO);
|
||||
sub.writerSN := p_sn;
|
||||
participant := p1;
|
||||
p0.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
|
||||
Log("Update Participant 0 [SN 5]", INFO);
|
||||
sub.writerSN := gen_sn(5);
|
||||
participant := p0;
|
||||
participant.nr := 0;
|
||||
participant.match := MATCH;
|
||||
gen_participant_data(participant, sub.data);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
p_sn := p_sn + 1;
|
||||
|
||||
|
||||
Log("Ignore Endpoint 0 Participant 1 [No matching Participant]", INFO);
|
||||
sub_p.writerSN := p_snp;
|
||||
endpoint := e0;
|
||||
endpoint.participant:= p1;
|
||||
endpoint.reader := FALSE;
|
||||
endpoint.entityId := gen_rand_entityid_2(FALSE);
|
||||
gen_endpoint_data(endpoint, sub_p.data);
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
Log("Ignore Update Participant 0 [SN 3]", INFO);
|
||||
sub.writerSN := gen_sn(3);
|
||||
participant := p0;
|
||||
participant.nr := 0;
|
||||
participant.match := MATCH;
|
||||
participant.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
gen_participant_data(participant, sub.data);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(p0));
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
|
||||
Log("Match Endpoint 0 Participant 0", INFO);
|
||||
sub_p.writerSN := p_snp;
|
||||
-- *PUBLISHER*
|
||||
|
||||
Log("Match Writer Participant 0 [SN 1]", INFO);
|
||||
sub_p.writerSN := gen_sn(1);
|
||||
endpoint := e0;
|
||||
endpoint.participant:= p0;
|
||||
endpoint.reader := FALSE;
|
||||
endpoint.entityId := gen_rand_entityid_2(FALSE);
|
||||
gen_endpoint_data(endpoint, sub_p.data);
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
wr_sig := (2 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
p_snp := p_snp + 1;
|
||||
|
||||
e0.unicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
|
||||
Log("Update Writer Participant 0 [SN 2]", INFO);
|
||||
sub_p.writerSN := gen_sn(2);
|
||||
endpoint := e0;
|
||||
endpoint.participant:= p0;
|
||||
gen_endpoint_data(endpoint, sub_p.data);
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
wr_sig := (2 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
|
||||
Log("Ignore Update Writer Participant 0 [SN 5]", INFO);
|
||||
sub_p.writerSN := gen_sn(5);
|
||||
endpoint := e0;
|
||||
endpoint.participant:= p0;
|
||||
gen_endpoint_data(endpoint, sub_p.data);
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
|
||||
Log("Ignore Update Writer Participant 0 [SN 1]", INFO);
|
||||
sub_p.writerSN := gen_sn(1);
|
||||
endpoint := e0;
|
||||
endpoint.participant:= p0;
|
||||
gen_endpoint_data(endpoint, sub_p.data);
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
|
||||
-- *SUBSCRIBER*
|
||||
|
||||
Log("Match Reader Participant 0 [SN 1]", INFO);
|
||||
sub_s.writerSN := gen_sn(1);
|
||||
endpoint := e1;
|
||||
endpoint.participant:= p0;
|
||||
gen_endpoint_data(endpoint, sub_s.data);
|
||||
gen_sentinel(sub_s.data);
|
||||
gen_rtps_handler_out(sub_s, endpoint, stimulus);
|
||||
wr_sig := (NUM_READERS+2 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_s.data := EMPTY_TEST_PACKET;
|
||||
|
||||
e1.unicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
|
||||
Log("Update Reader Participant 0 [SN 2]", INFO);
|
||||
sub_s.writerSN := gen_sn(2);
|
||||
endpoint := e1;
|
||||
endpoint.participant:= p0;
|
||||
gen_endpoint_data(endpoint, sub_s.data);
|
||||
gen_sentinel(sub_s.data);
|
||||
gen_rtps_handler_out(sub_s, endpoint, stimulus);
|
||||
wr_sig := (NUM_READERS+2 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_s.data := EMPTY_TEST_PACKET;
|
||||
|
||||
Log("Ignore Update Reader Participant 0 [SN 5]", INFO);
|
||||
sub_s.writerSN := gen_sn(5);
|
||||
endpoint := e1;
|
||||
endpoint.participant:= p0;
|
||||
gen_endpoint_data(endpoint, sub_s.data);
|
||||
gen_sentinel(sub_s.data);
|
||||
gen_rtps_handler_out(sub_s, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_s.data := EMPTY_TEST_PACKET;
|
||||
|
||||
Log("Ignore Update Reader Participant 0 [SN 1]", INFO);
|
||||
sub_s.writerSN := gen_sn(1);
|
||||
endpoint := e1;
|
||||
endpoint.participant:= p0;
|
||||
gen_endpoint_data(endpoint, sub_s.data);
|
||||
gen_sentinel(sub_s.data);
|
||||
gen_rtps_handler_out(sub_s, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_sent;
|
||||
wait_on_mem_check;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_s.data := EMPTY_TEST_PACKET;
|
||||
|
||||
stim_done <= '1';
|
||||
wait_on_complete;
|
||||
TranscriptOpen(RESULTS_FILE, APPEND_MODE);
|
||||
SetTranscriptMirror;
|
||||
stim_done <= '1';
|
||||
wait until check_done = '1';
|
||||
AlertIf((not SB_out.empty) or (not SB_mem.empty), "Incomplete test run");
|
||||
ReportAlerts;
|
||||
TranscriptClose;
|
||||
std.env.stop;
|
||||
@ -355,39 +499,59 @@ begin
|
||||
|
||||
output_check_prc : process(all)
|
||||
begin
|
||||
check_done <= '0';
|
||||
if rising_edge(clk) then
|
||||
if (endpoint_wr /= (0 to NUM_ENDPOINTS-1 => '0')) then
|
||||
SB_out.Check(endpoint_wr & last_word_out & data_out);
|
||||
end if;
|
||||
if (stim_done = '1' and SB_out.empty) then
|
||||
check_done <= '1';
|
||||
else
|
||||
check_done <= '0';
|
||||
end if;
|
||||
end if;
|
||||
end process;
|
||||
|
||||
done_proc : process(clk)
|
||||
begin
|
||||
if rising_edge(clk) then
|
||||
if (stim_done = '1' and SB_mem.empty and check_done = '1') then
|
||||
test_done <= '1';
|
||||
else
|
||||
test_done <= '0';
|
||||
end if;
|
||||
end if;
|
||||
end process;
|
||||
|
||||
mem_check_prc : process
|
||||
alias mem is <<signal uut.ram_inst.mem : TEST_RAM_TYPE>>;
|
||||
alias mem is <<signal uut.mem_ctrl_inst.ram_inst.mem : TEST_RAM_TYPE>>;
|
||||
alias mem_op_done is <<signal uut.mem_op_done : std_logic>>;
|
||||
alias idle_sig is <<signal uut.idle_sig : std_logic>>;
|
||||
variable reference : TEST_PARTICIPANT_MEMORY_FRAME_TYPE;
|
||||
begin
|
||||
mem_check_done <= '0';
|
||||
-- SAFEGUARD: (Prevent Fall-through Behavior)
|
||||
if (reset /= '0') then
|
||||
wait until reset = '0';
|
||||
end if;
|
||||
-- NOTE: The first read after the packet is sent signifies that the State Machine has begun processing the next packet.
|
||||
-- The memory operation that could still be in progress is the last one concerning the last sent packet.
|
||||
wait on packet_sent until (packet_sent = '1' and mem_check = '1');
|
||||
wait until rising_edge(rd_sig);
|
||||
-- Wait for Packet to be sent
|
||||
wait until rising_edge(packet_sent);
|
||||
-- Wait for UUT IDLE state
|
||||
if (idle_sig /= '1') then
|
||||
wait until idle_sig = '1';
|
||||
end if;
|
||||
-- Wait for ongoing memory operation
|
||||
if (mem_op_done /= '1') then
|
||||
wait until mem_op_done = '1';
|
||||
end if;
|
||||
if (not SB_mem.empty) then
|
||||
while (not SB_mem.empty) loop
|
||||
SB_mem.Pop(reference);
|
||||
for i in 0 to reference'length-1 loop
|
||||
AffirmIf(?? (mem(reference(i).addr) ?= reference(i).data), "Address: " & integer'image(reference(i).addr) & " Received: " & to_hstring(mem(reference(i).addr)) & " Expected: " & to_hstring(reference(i).data));
|
||||
end loop;
|
||||
end if;
|
||||
end loop;
|
||||
-- Toggle High for one clock cycle
|
||||
mem_check_done <= '1';
|
||||
wait until rising_edge(clk);
|
||||
end process;
|
||||
|
||||
watchdog : process
|
||||
|
||||
@ -10,7 +10,10 @@ use work.user_config.all;
|
||||
use work.rtps_config_package.all;
|
||||
use work.rtps_test_package.all;
|
||||
|
||||
-- This testbench tests the sequence number handling of the participant, subscriber, and publisher DATA Submessages.
|
||||
-- This testbench tests the stale participant handling of the rtps_builtin_endpoint. It does so by checking for the Participant Unmatch Frame.
|
||||
-- It first matches 3 Participants: Participant 0 with default lease duration 100s, Participant 1 with lease duration 10s, and Participant 2 with lease duration 30s.
|
||||
-- After matching the time is artificially progressed to 15s (from 0s), and the removal of Participant 1 is checked. Than the time is again artificially progressed to 101s
|
||||
-- and the removal of Participant 0 and 2 is checked (in that order).
|
||||
|
||||
entity L0_rtps_builtin_endpoint_test5 is
|
||||
end entity;
|
||||
@ -18,7 +21,7 @@ end entity;
|
||||
architecture testbench of L0_rtps_builtin_endpoint_test5 is
|
||||
|
||||
-- *CONSTANT DECLARATION*
|
||||
constant MAX_REMOTE_PARTICIPANTS : natural := 1;
|
||||
constant MAX_REMOTE_PARTICIPANTS : natural := 3;
|
||||
|
||||
-- *TYPE DECLARATION*
|
||||
type TEST_STAGE_TYPE is (IDLE, BUSY);
|
||||
@ -35,11 +38,18 @@ architecture testbench of L0_rtps_builtin_endpoint_test5 is
|
||||
signal cnt_stim : natural := 0;
|
||||
signal start : std_logic := '0';
|
||||
shared variable SB_out : work.ScoreBoardPkg_builtin_endpoint.ScoreBoardPType;
|
||||
shared variable SB_mem : work.ScoreBoardPkg_MemoryTest.ScoreBoardPType;
|
||||
signal stim_done, check_done, mem_check : std_logic := '0';
|
||||
signal stim_done, check_done, test_done : std_logic := '0';
|
||||
signal test_time : TIME_TYPE := TIME_ZERO;
|
||||
|
||||
-- *FUNCTION DECLARATION*
|
||||
procedure wait_on_complete is
|
||||
begin
|
||||
if (test_done /= '1') then
|
||||
wait until test_done = '1';
|
||||
end if;
|
||||
end procedure;
|
||||
|
||||
procedure wait_on_sent is
|
||||
begin
|
||||
wait until rising_edge(packet_sent);
|
||||
end procedure;
|
||||
@ -67,7 +77,7 @@ begin
|
||||
data_in => data_in,
|
||||
data_out => data_out,
|
||||
last_word_in => last_word_in,
|
||||
time => TIME_ZERO,
|
||||
time => test_time,
|
||||
endpoint_full => endpoint_full,
|
||||
endpoint_wr => endpoint_wr,
|
||||
rtps_wr => open,
|
||||
@ -77,12 +87,14 @@ begin
|
||||
);
|
||||
|
||||
stimulus_prc : process
|
||||
variable sub, sub_p, sub_s : RTPS_SUBMESSAGE_TYPE := DEFAULT_RTPS_SUBMESSAGE;
|
||||
variable sub : RTPS_SUBMESSAGE_TYPE := DEFAULT_RTPS_SUBMESSAGE;
|
||||
variable RV : RandomPType;
|
||||
variable p0, participant : PARTICIPANT_DATA_TYPE := DEFAULT_PARTICIPANT_DATA;
|
||||
variable e0, e1, endpoint : ENDPOINT_DATA_TYPE := DEFAULT_ENDPOINT_DATA;
|
||||
variable p_sn, p_snp : SEQUENCENUMBER_TYPE := FIRST_SEQUENCENUMBER;
|
||||
variable p_sn : SEQUENCENUMBER_TYPE := FIRST_SEQUENCENUMBER;
|
||||
variable wr_sig : std_logic_vector(0 to NUM_ENDPOINTS-1) := (others => '0');
|
||||
variable p0, p1, p2, participant : PARTICIPANT_DATA_TYPE := DEFAULT_PARTICIPANT_DATA;
|
||||
|
||||
alias idle_sig is <<signal uut.idle_sig : std_logic>>;
|
||||
alias mem_op_done is <<signal uut.mem_op_done : std_logic>>;
|
||||
|
||||
-- Wrapper to use procedure as function
|
||||
impure function gen_rand_loc_2 return LOCATOR_TYPE is
|
||||
@ -99,28 +111,6 @@ begin
|
||||
return ret;
|
||||
end function;
|
||||
|
||||
procedure push_endpoint_reference is
|
||||
begin
|
||||
-- MATCH
|
||||
if (wr_sig /= (wr_sig'range => '0')) then
|
||||
endpoint.match := MATCH;
|
||||
gen_endpoint_match_frame(endpoint, reference);
|
||||
for i in 0 to reference.length-1 loop
|
||||
SB_out.Push(wr_sig & reference.last(i) & reference.data(i));
|
||||
end loop;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
end if;
|
||||
-- UNMATCH
|
||||
if ((not wr_sig) /= (wr_sig'range => '0')) then
|
||||
endpoint.match := UNMATCH;
|
||||
gen_endpoint_match_frame(endpoint, reference);
|
||||
for i in 0 to reference.length-1 loop
|
||||
SB_out.Push((not wr_sig) & reference.last(i) & reference.data(i));
|
||||
end loop;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
end if;
|
||||
end procedure;
|
||||
|
||||
procedure push_participant_reference is
|
||||
variable wr_sig : std_logic_vector(NUM_ENDPOINTS-1 downto 0) := (others => '1');
|
||||
begin
|
||||
@ -143,14 +133,30 @@ begin
|
||||
start <= '1';
|
||||
wait until rising_edge(clk);
|
||||
start <= '0';
|
||||
mem_check <= '0';
|
||||
wait until rising_edge(clk);
|
||||
end procedure;
|
||||
|
||||
-- NOTE: This procedure waits until the idle_sig is high for at least
|
||||
-- two consecutive clock cycles.
|
||||
procedure wait_on_idle is
|
||||
variable first : boolean := TRUE;
|
||||
begin
|
||||
loop
|
||||
if (idle_sig /= '1' or mem_op_done /= '1') then
|
||||
wait until idle_sig = '1' and mem_op_done = '1';
|
||||
elsif (not first) then
|
||||
exit;
|
||||
end if;
|
||||
wait until rising_edge(clk);
|
||||
wait until rising_edge(clk);
|
||||
first := FALSE;
|
||||
end loop;
|
||||
end procedure;
|
||||
begin
|
||||
|
||||
assert (TEST_STRING = "TEST_CONFIG_1") report "user_config incompatible with testbench." severity FAILURE;
|
||||
|
||||
SetAlertLogName("rtps_builtin_endpoint - Level 0 - Sequence Number Handling");
|
||||
SetAlertLogName("rtps_builtin_endpoint - Level 0 - Stale Participant Handling");
|
||||
SetAlertEnable(FAILURE, TRUE);
|
||||
SetAlertEnable(ERROR, TRUE);
|
||||
SetAlertEnable(WARNING, TRUE);
|
||||
@ -166,21 +172,7 @@ begin
|
||||
sub.readerId := ENTITYID_SPDP_BUILTIN_PARTICIPANT_DETECTOR;
|
||||
sub.flags(SUBMESSAGE_DATA_FLAG_POS) := '1';
|
||||
|
||||
-- Publisher Endpoint RTPS Submessage
|
||||
sub_p := DEFAULT_RTPS_SUBMESSAGE;
|
||||
sub_p.submessageID := SID_DATA;
|
||||
sub_p.writerId := ENTITYID_SEDP_BUILTIN_PUBLICATIONS_ANNOUNCER;
|
||||
sub_p.readerId := ENTITYID_SEDP_BUILTIN_PUBLICATIONS_DETECTOR;
|
||||
sub_p.flags(SUBMESSAGE_DATA_FLAG_POS) := '1';
|
||||
|
||||
-- Subscriber Endpoint RTPS Submessage
|
||||
sub_s := DEFAULT_RTPS_SUBMESSAGE;
|
||||
sub_s.submessageID := SID_DATA;
|
||||
sub_s.writerId := ENTITYID_SEDP_BUILTIN_SUBSCRIPTIONS_ANNOUNCER;
|
||||
sub_s.readerId := ENTITYID_SEDP_BUILTIN_SUBSCRIPTIONS_DETECTOR;
|
||||
sub_s.flags(SUBMESSAGE_DATA_FLAG_POS) := '1';
|
||||
|
||||
-- Participant 0
|
||||
-- Participant 0 (Default Lease Time 100 s)
|
||||
p0.guidPrefix := gen_rand_guid_prefix;
|
||||
p0.nr := 0;
|
||||
p0.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
@ -189,20 +181,28 @@ begin
|
||||
p0.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_DETECTOR) := '1';
|
||||
p0.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_ANNOUNCER) := '1';
|
||||
|
||||
e0.participant := p0;
|
||||
e0.topic_name := ENDPOINT_TOPIC(2);
|
||||
e0.type_name := ENDPOINT_TYPE(2);
|
||||
e0.reader := FALSE;
|
||||
e0.entityId := gen_rand_entityid_2(FALSE);
|
||||
-- Participant 1 (Lease Duration 10 s)
|
||||
p1.guidPrefix := gen_rand_guid_prefix;
|
||||
p1.nr := 1;
|
||||
p1.leaseDuration := gen_duration(10,0);
|
||||
p1.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
p1.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_DETECTOR) := '1';
|
||||
p1.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_ANNOUNCER):= '1';
|
||||
p1.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_DETECTOR) := '1';
|
||||
p1.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_ANNOUNCER) := '1';
|
||||
|
||||
e1.participant := p0;
|
||||
e1.topic_name := ENDPOINT_TOPIC(2);
|
||||
e1.type_name := ENDPOINT_TYPE(2);
|
||||
e1.reader := TRUE;
|
||||
e1.entityId := gen_rand_entityid_2(FALSE);
|
||||
-- Participant 2 (Lease Duration 30 s)
|
||||
p2.guidPrefix := gen_rand_guid_prefix;
|
||||
p2.nr := 2;
|
||||
p2.leaseDuration := gen_duration(30,0);
|
||||
p2.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
p2.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_DETECTOR) := '1';
|
||||
p2.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_ANNOUNCER):= '1';
|
||||
p2.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_DETECTOR) := '1';
|
||||
p2.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_ANNOUNCER) := '1';
|
||||
|
||||
Log("Initiating Test", INFO);
|
||||
mem_check <= '1';
|
||||
test_time <= TIME_ZERO;
|
||||
stim_done <= '0';
|
||||
start <= '0';
|
||||
reset <= '1';
|
||||
@ -211,201 +211,71 @@ begin
|
||||
reset <= '0';
|
||||
|
||||
-- *PARTICIPANT*
|
||||
|
||||
Log("Match Participant 0 [SN 1]", INFO);
|
||||
sub.writerSN := gen_sn(1);
|
||||
Log("Current Time: 0s", INFO);
|
||||
Log("Match Participant 0 [Default Lease 100s]", INFO);
|
||||
sub.writerSN := p_sn;
|
||||
participant := p0;
|
||||
participant.nr := 0;
|
||||
participant.match := MATCH;
|
||||
gen_participant_data(participant, sub.data);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_idle;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
p_sn := p_sn + 1;
|
||||
|
||||
p0.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
|
||||
Log("Update Participant 0 [SN 2]", INFO);
|
||||
sub.writerSN := gen_sn(2);
|
||||
participant := p0;
|
||||
participant.nr := 0;
|
||||
participant.match := MATCH;
|
||||
Log("Match Participant 1 [Lease 10s]", INFO);
|
||||
sub.writerSN := p_sn;
|
||||
participant := p1;
|
||||
gen_participant_data(participant, sub.data);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_idle;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
p_sn := p_sn + 1;
|
||||
|
||||
p0.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
|
||||
Log("Update Participant 0 [SN 5]", INFO);
|
||||
sub.writerSN := gen_sn(5);
|
||||
participant := p0;
|
||||
participant.nr := 0;
|
||||
participant.match := MATCH;
|
||||
Log("Match Participant 2 [Lease 30s]", INFO);
|
||||
sub.writerSN := p_sn;
|
||||
participant := p2;
|
||||
gen_participant_data(participant, sub.data);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
wait_on_complete;
|
||||
wait_on_sent;
|
||||
wait_on_idle;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
p_sn := p_sn + 1;
|
||||
|
||||
Log("Ignore Update Participant 0 [SN 3]", INFO);
|
||||
sub.writerSN := gen_sn(3);
|
||||
|
||||
Log("Current Time: 15 s", INFO);
|
||||
test_time <= gen_duration(15,0);
|
||||
participant := p1;
|
||||
participant.match := UNMATCH;
|
||||
push_participant_reference;
|
||||
wait_on_idle;
|
||||
|
||||
Log("Current Time: 101 s", INFO);
|
||||
test_time <= (unsigned(int(101, CDR_LONG_WIDTH)), unsigned(int(0, CDR_LONG_WIDTH)));
|
||||
participant := p2;
|
||||
participant.match := UNMATCH;
|
||||
push_participant_reference;
|
||||
participant := p0;
|
||||
participant.nr := 0;
|
||||
participant.match := MATCH;
|
||||
participant.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
gen_participant_data(participant, sub.data);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(p0));
|
||||
start_test;
|
||||
mem_check <= '1';
|
||||
participant.match := UNMATCH;
|
||||
push_participant_reference;
|
||||
wait_on_idle;
|
||||
|
||||
stim_done <= '1';
|
||||
wait_on_complete;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
|
||||
-- *PUBLISHER*
|
||||
|
||||
Log("Match Writer Participant 0 [SN 1]", INFO);
|
||||
sub_p.writerSN := gen_sn(1);
|
||||
endpoint := e0;
|
||||
endpoint.participant:= p0;
|
||||
gen_endpoint_data(endpoint, sub_p.data);
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
wr_sig := (2 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
|
||||
e0.unicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
|
||||
Log("Update Writer Participant 0 [SN 2]", INFO);
|
||||
sub_p.writerSN := gen_sn(2);
|
||||
endpoint := e0;
|
||||
endpoint.participant:= p0;
|
||||
gen_endpoint_data(endpoint, sub_p.data);
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
wr_sig := (2 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
|
||||
Log("Ignore Update Writer Participant 0 [SN 5]", INFO);
|
||||
sub_p.writerSN := gen_sn(5);
|
||||
endpoint := e0;
|
||||
endpoint.participant:= p0;
|
||||
gen_endpoint_data(endpoint, sub_p.data);
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
|
||||
Log("Ignore Update Writer Participant 0 [SN 1]", INFO);
|
||||
sub_p.writerSN := gen_sn(1);
|
||||
endpoint := e0;
|
||||
endpoint.participant:= p0;
|
||||
gen_endpoint_data(endpoint, sub_p.data);
|
||||
gen_sentinel(sub_p.data);
|
||||
gen_rtps_handler_out(sub_p, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_p.data := EMPTY_TEST_PACKET;
|
||||
|
||||
-- *SUBSCRIBER*
|
||||
|
||||
Log("Match Reader Participant 0 [SN 1]", INFO);
|
||||
sub_s.writerSN := gen_sn(1);
|
||||
endpoint := e1;
|
||||
endpoint.participant:= p0;
|
||||
gen_endpoint_data(endpoint, sub_s.data);
|
||||
gen_sentinel(sub_s.data);
|
||||
gen_rtps_handler_out(sub_s, endpoint, stimulus);
|
||||
wr_sig := (NUM_READERS+2 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_s.data := EMPTY_TEST_PACKET;
|
||||
|
||||
e1.unicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
|
||||
Log("Update Reader Participant 0 [SN 2]", INFO);
|
||||
sub_s.writerSN := gen_sn(2);
|
||||
endpoint := e1;
|
||||
endpoint.participant:= p0;
|
||||
gen_endpoint_data(endpoint, sub_s.data);
|
||||
gen_sentinel(sub_s.data);
|
||||
gen_rtps_handler_out(sub_s, endpoint, stimulus);
|
||||
wr_sig := (NUM_READERS+2 => '1', others => '0');
|
||||
push_endpoint_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_s.data := EMPTY_TEST_PACKET;
|
||||
|
||||
Log("Ignore Update Reader Participant 0 [SN 5]", INFO);
|
||||
sub_s.writerSN := gen_sn(5);
|
||||
endpoint := e1;
|
||||
endpoint.participant:= p0;
|
||||
gen_endpoint_data(endpoint, sub_s.data);
|
||||
gen_sentinel(sub_s.data);
|
||||
gen_rtps_handler_out(sub_s, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_s.data := EMPTY_TEST_PACKET;
|
||||
|
||||
Log("Ignore Update Reader Participant 0 [SN 1]", INFO);
|
||||
sub_s.writerSN := gen_sn(1);
|
||||
endpoint := e1;
|
||||
endpoint.participant:= p0;
|
||||
gen_endpoint_data(endpoint, sub_s.data);
|
||||
gen_sentinel(sub_s.data);
|
||||
gen_rtps_handler_out(sub_s, endpoint, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub_s.data := EMPTY_TEST_PACKET;
|
||||
|
||||
TranscriptOpen(RESULTS_FILE, APPEND_MODE);
|
||||
SetTranscriptMirror;
|
||||
stim_done <= '1';
|
||||
wait until check_done = '1';
|
||||
AlertIf((not SB_out.empty) or (not SB_mem.empty), "Incomplete test run");
|
||||
ReportAlerts;
|
||||
TranscriptClose;
|
||||
std.env.stop;
|
||||
@ -480,38 +350,26 @@ begin
|
||||
|
||||
output_check_prc : process(all)
|
||||
begin
|
||||
check_done <= '0';
|
||||
if rising_edge(clk) then
|
||||
if (endpoint_wr /= (0 to NUM_ENDPOINTS-1 => '0')) then
|
||||
SB_out.Check(endpoint_wr & last_word_out & data_out);
|
||||
end if;
|
||||
if (stim_done = '1' and SB_out.empty) then
|
||||
check_done <= '1';
|
||||
else
|
||||
check_done <= '0';
|
||||
end if;
|
||||
end if;
|
||||
end process;
|
||||
|
||||
mem_check_prc : process
|
||||
alias mem is <<signal uut.ram_inst.mem : TEST_RAM_TYPE>>;
|
||||
alias mem_op_done is <<signal uut.mem_op_done : std_logic>>;
|
||||
variable reference : TEST_PARTICIPANT_MEMORY_FRAME_TYPE;
|
||||
done_proc : process(clk)
|
||||
begin
|
||||
-- SAFEGUARD: (Prevent Fall-through Behavior)
|
||||
if (reset /= '0') then
|
||||
wait until reset = '0';
|
||||
if rising_edge(clk) then
|
||||
if (stim_done = '1' and check_done = '1') then
|
||||
test_done <= '1';
|
||||
else
|
||||
test_done <= '0';
|
||||
end if;
|
||||
-- NOTE: The first read after the packet is sent signifies that the State Machine has begun processing the next packet.
|
||||
-- The memory operation that could still be in progress is the last one concerning the last sent packet.
|
||||
wait on packet_sent until (packet_sent = '1' and mem_check = '1');
|
||||
wait until rising_edge(rd_sig);
|
||||
if (mem_op_done /= '1') then
|
||||
wait until mem_op_done = '1';
|
||||
end if;
|
||||
if (not SB_mem.empty) then
|
||||
SB_mem.Pop(reference);
|
||||
for i in 0 to reference'length-1 loop
|
||||
AffirmIf(?? (mem(reference(i).addr) ?= reference(i).data), "Address: " & integer'image(reference(i).addr) & " Received: " & to_hstring(mem(reference(i).addr)) & " Expected: " & to_hstring(reference(i).data));
|
||||
end loop;
|
||||
end if;
|
||||
end process;
|
||||
|
||||
|
||||
@ -10,23 +10,17 @@ use work.user_config.all;
|
||||
use work.rtps_config_package.all;
|
||||
use work.rtps_test_package.all;
|
||||
|
||||
-- This testbench tests the stale participant handling of the rtps_builtin_endpoint.
|
||||
-- It first matches 3 Participants: Participant 0 with default lease duration 100s, Participant 1 with lease duration 10s, and Participant 2 with lease duration 30s.
|
||||
-- After matching the time is artificially progressed to 15s (from 0s), and the removal of Participant 1 is checked. Than the time is again artificially progressed to 101s
|
||||
-- and the removal of Participant 0 and 2 is checked (in that order).
|
||||
-- Note that dummy packets are sent in between to trigger the memory contents checks, since the stale checks are done in between packet processing.
|
||||
-- This testbench tests the handling of remote Liveliness Assertions
|
||||
-- The testbench matches 2 remote Participants, P0 and P1. P0 sends an automatic liveliness assertion, while P1 sends a manual liveliness assertion.
|
||||
-- P0 also sends a manual liveliness assertion with extra Bytes.
|
||||
|
||||
entity L0_rtps_builtin_endpoint_test6 is
|
||||
end entity;
|
||||
|
||||
architecture testbench of L0_rtps_builtin_endpoint_test6 is
|
||||
|
||||
-- *CONSTANT DECLARATION*
|
||||
constant MAX_REMOTE_PARTICIPANTS : natural := 3;
|
||||
|
||||
-- *TYPE DECLARATION*
|
||||
type TEST_STAGE_TYPE is (IDLE, BUSY);
|
||||
type TEST_RAM_TYPE is array (0 to (MAX_REMOTE_PARTICIPANTS*PARTICIPANT_FRAME_SIZE)-1) of std_logic_vector(WORD_WIDTH-1 downto 0);
|
||||
|
||||
-- *SIGNAL DECLARATION*
|
||||
signal clk, in_empty, rd_sig, last_word_in, last_word_out: std_logic := '0';
|
||||
@ -39,9 +33,7 @@ architecture testbench of L0_rtps_builtin_endpoint_test6 is
|
||||
signal cnt_stim : natural := 0;
|
||||
signal start : std_logic := '0';
|
||||
shared variable SB_out : work.ScoreBoardPkg_builtin_endpoint.ScoreBoardPType;
|
||||
shared variable SB_mem : work.ScoreBoardPkg_MemoryTest.ScoreBoardPType;
|
||||
signal stim_done, check_done, mem_check : std_logic := '0';
|
||||
signal test_time : TIME_TYPE := TIME_ZERO;
|
||||
|
||||
-- *FUNCTION DECLARATION*
|
||||
procedure wait_on_complete is
|
||||
@ -62,7 +54,7 @@ begin
|
||||
-- Unit Under Test
|
||||
uut : entity work.rtps_builtin_endpoint(arch)
|
||||
generic map (
|
||||
MAX_REMOTE_PARTICIPANTS => MAX_REMOTE_PARTICIPANTS
|
||||
MAX_REMOTE_PARTICIPANTS => 2
|
||||
)
|
||||
port map (
|
||||
clk => clk,
|
||||
@ -72,7 +64,7 @@ begin
|
||||
data_in => data_in,
|
||||
data_out => data_out,
|
||||
last_word_in => last_word_in,
|
||||
time => test_time,
|
||||
time => TIME_ZERO,
|
||||
endpoint_full => endpoint_full,
|
||||
endpoint_wr => endpoint_wr,
|
||||
rtps_wr => open,
|
||||
@ -84,9 +76,9 @@ begin
|
||||
stimulus_prc : process
|
||||
variable sub : RTPS_SUBMESSAGE_TYPE := DEFAULT_RTPS_SUBMESSAGE;
|
||||
variable RV : RandomPType;
|
||||
variable p_sn : SEQUENCENUMBER_TYPE := FIRST_SEQUENCENUMBER;
|
||||
variable p0, p1, participant: PARTICIPANT_DATA_TYPE := DEFAULT_PARTICIPANT_DATA;
|
||||
variable wr_sig : std_logic_vector(0 to NUM_ENDPOINTS-1) := (others => '0');
|
||||
variable p0, p1, p2, participant : PARTICIPANT_DATA_TYPE := DEFAULT_PARTICIPANT_DATA;
|
||||
variable rand_data : TEST_PACKET_TYPE := EMPTY_TEST_PACKET;
|
||||
|
||||
-- Wrapper to use procedure as function
|
||||
impure function gen_rand_loc_2 return LOCATOR_TYPE is
|
||||
@ -96,23 +88,6 @@ begin
|
||||
return ret;
|
||||
end function;
|
||||
|
||||
impure function gen_rand_entityid_2(reader : boolean) return std_logic_vector is
|
||||
variable ret : std_logic_vector(ENTITYID_WIDTH-1 downto 0) := (others => '0');
|
||||
begin
|
||||
gen_rand_entityid(RV, reader, ret);
|
||||
return ret;
|
||||
end function;
|
||||
|
||||
procedure push_participant_reference is
|
||||
variable wr_sig : std_logic_vector(NUM_ENDPOINTS-1 downto 0) := (others => '1');
|
||||
begin
|
||||
gen_participant_match_frame(participant, reference);
|
||||
for i in 0 to reference.length-1 loop
|
||||
SB_out.Push(wr_sig & reference.last(i) & reference.data(i));
|
||||
end loop;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
end procedure;
|
||||
|
||||
impure function gen_rand_guid_prefix return GUIDPREFIX_TYPE is
|
||||
variable ret : GUIDPREFIX_TYPE;
|
||||
begin
|
||||
@ -120,6 +95,13 @@ begin
|
||||
return ret;
|
||||
end function;
|
||||
|
||||
procedure push_reference is
|
||||
begin
|
||||
for i in 0 to reference.length-1 loop
|
||||
SB_out.Push(wr_sig & reference.last(i) & reference.data(i));
|
||||
end loop;
|
||||
end procedure;
|
||||
|
||||
procedure start_test is
|
||||
begin
|
||||
start <= '1';
|
||||
@ -131,7 +113,7 @@ begin
|
||||
|
||||
assert (TEST_STRING = "TEST_CONFIG_1") report "user_config incompatible with testbench." severity FAILURE;
|
||||
|
||||
SetAlertLogName("rtps_builtin_endpoint - Level 0 - Stale Participant Handling");
|
||||
SetAlertLogName("rtps_builtin_endpoint - Level 0 - Remote Liveliness Assertion Handling");
|
||||
SetAlertEnable(FAILURE, TRUE);
|
||||
SetAlertEnable(ERROR, TRUE);
|
||||
SetAlertEnable(WARNING, TRUE);
|
||||
@ -147,7 +129,7 @@ begin
|
||||
sub.readerId := ENTITYID_SPDP_BUILTIN_PARTICIPANT_DETECTOR;
|
||||
sub.flags(SUBMESSAGE_DATA_FLAG_POS) := '1';
|
||||
|
||||
-- Participant 0 (Default Lease Time 100 s)
|
||||
-- Participant 0
|
||||
p0.guidPrefix := gen_rand_guid_prefix;
|
||||
p0.nr := 0;
|
||||
p0.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
@ -156,28 +138,21 @@ begin
|
||||
p0.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_DETECTOR) := '1';
|
||||
p0.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_ANNOUNCER) := '1';
|
||||
|
||||
-- Participant 1 (Lease Duration 10 s)
|
||||
-- Participant 1
|
||||
p1.guidPrefix := gen_rand_guid_prefix;
|
||||
p1.nr := 1;
|
||||
p1.leaseDuration := gen_duration(10,0);
|
||||
p1.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
p1.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_DETECTOR) := '1';
|
||||
p1.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_ANNOUNCER):= '1';
|
||||
p1.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_DETECTOR) := '1';
|
||||
p1.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_ANNOUNCER) := '1';
|
||||
|
||||
-- Participant 2 (Lease Duration 30 s)
|
||||
p2.guidPrefix := gen_rand_guid_prefix;
|
||||
p2.nr := 2;
|
||||
p2.leaseDuration := gen_duration(30,0);
|
||||
p2.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
p2.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_DETECTOR) := '1';
|
||||
p2.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_ANNOUNCER):= '1';
|
||||
p2.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_DETECTOR) := '1';
|
||||
p2.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_ANNOUNCER) := '1';
|
||||
for i in 0 to RV.RandInt(1,10) loop
|
||||
rand_data.data(i) := RV.RandSlv(WORD_WIDTH);
|
||||
rand_data.length := rand_data.length + 1;
|
||||
end loop;
|
||||
|
||||
Log("Initiating Test", INFO);
|
||||
test_time <= TIME_ZERO;
|
||||
stim_done <= '0';
|
||||
start <= '0';
|
||||
reset <= '1';
|
||||
@ -187,92 +162,97 @@ begin
|
||||
|
||||
-- *PARTICIPANT*
|
||||
Log("Current Time: 0s", INFO);
|
||||
Log("Match Participant 0 [Default Lease 100s]", INFO);
|
||||
sub.writerSN := p_sn;
|
||||
Log("Match Participant 0", INFO);
|
||||
sub := DEFAULT_RTPS_SUBMESSAGE;
|
||||
sub.submessageID := SID_DATA;
|
||||
sub.writerId := ENTITYID_SPDP_BUILTIN_PARTICIPANT_ANNOUNCER;
|
||||
sub.readerId := ENTITYID_SPDP_BUILTIN_PARTICIPANT_DETECTOR;
|
||||
sub.writerSN := gen_sn(1);
|
||||
sub.flags(SUBMESSAGE_DATA_FLAG_POS) := '1';
|
||||
participant := p0;
|
||||
gen_participant_data(participant, sub.data);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
p_sn := p_sn + 1;
|
||||
|
||||
Log("Match Participant 1 [Lease 10s]", INFO);
|
||||
sub.writerSN := p_sn;
|
||||
Log("Match Participant 1", INFO);
|
||||
sub := DEFAULT_RTPS_SUBMESSAGE;
|
||||
sub.submessageID := SID_DATA;
|
||||
sub.writerId := ENTITYID_SPDP_BUILTIN_PARTICIPANT_ANNOUNCER;
|
||||
sub.readerId := ENTITYID_SPDP_BUILTIN_PARTICIPANT_DETECTOR;
|
||||
sub.writerSN := gen_sn(1);
|
||||
sub.flags(SUBMESSAGE_DATA_FLAG_POS) := '1';
|
||||
participant := p1;
|
||||
gen_participant_data(participant, sub.data);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
p_sn := p_sn + 1;
|
||||
|
||||
Log("Match Participant 2 [Lease 30s]", INFO);
|
||||
sub.writerSN := p_sn;
|
||||
participant := p2;
|
||||
gen_participant_data(participant, sub.data);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
p_sn := p_sn + 1;
|
||||
|
||||
-- DUMMY PACKET (Trigger last mem check)
|
||||
-- Mark Packet as non-standard Payload, in order to trigger the packet to be skipped (as early as possible)
|
||||
sub.data := EMPTY_TEST_PACKET;
|
||||
sub.flags(SUBMESSAGE_NON_STANDARD_PAYLOAD_FLAG_POS):= '1';
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
|
||||
participant := p1;
|
||||
participant.match := UNMATCH;
|
||||
push_participant_reference;
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
|
||||
Log("Current Time: 15 s", INFO);
|
||||
start_test;
|
||||
-- Progress Time (15 s)
|
||||
test_time <= (unsigned(int(15, CDR_LONG_WIDTH)), unsigned(int(0, CDR_LONG_WIDTH)));
|
||||
wait_on_complete;
|
||||
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
|
||||
Log("Current Time: 101 s", INFO);
|
||||
test_time <= (unsigned(int(101, CDR_LONG_WIDTH)), unsigned(int(0, CDR_LONG_WIDTH)));
|
||||
|
||||
Log("Participant 0 Automatic Liveliness Assertion", INFO);
|
||||
sub := DEFAULT_RTPS_SUBMESSAGE;
|
||||
sub.submessageID := SID_DATA;
|
||||
sub.writerId := ENTITYID_P2P_BUILTIN_PARTICIPANT_MESSAGE_WRITER;
|
||||
sub.readerId := ENTITYID_P2P_BUILTIN_PARTICIPANT_MESSAGE_READER;
|
||||
sub.writerSN := gen_sn(1);
|
||||
sub.flags(SUBMESSAGE_DATA_FLAG_POS) := '1';
|
||||
participant := p0;
|
||||
participant.match := UNMATCH;
|
||||
push_participant_reference;
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
|
||||
gen_liveliness_assertion(p0, FALSE, sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
gen_liveliness_update_frame(p0, reference);
|
||||
wr_sig := AUTOMATIC_LIVELINESS_READERS;
|
||||
push_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
|
||||
participant := p2;
|
||||
participant.match := UNMATCH;
|
||||
push_participant_reference;
|
||||
SB_mem.Push(gen_participant_mem_frame(participant));
|
||||
|
||||
Log("Participant 1 Manual Liveliness Assertion", INFO);
|
||||
sub := DEFAULT_RTPS_SUBMESSAGE;
|
||||
sub.submessageID := SID_DATA;
|
||||
sub.writerId := ENTITYID_P2P_BUILTIN_PARTICIPANT_MESSAGE_WRITER;
|
||||
sub.readerId := ENTITYID_P2P_BUILTIN_PARTICIPANT_MESSAGE_READER;
|
||||
sub.writerSN := gen_sn(1);
|
||||
sub.flags(SUBMESSAGE_DATA_FLAG_POS) := '1';
|
||||
participant := p1;
|
||||
gen_liveliness_assertion(p1, TRUE, sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
gen_liveliness_update_frame(p1, reference);
|
||||
wr_sig := MANUAL_BY_PARTICIPANT_LIVELINESS_READERS;
|
||||
push_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
|
||||
Log("Participant 0 Manual Liveliness Assertion [+DATA Bytes]", INFO);
|
||||
sub := DEFAULT_RTPS_SUBMESSAGE;
|
||||
sub.submessageID := SID_DATA;
|
||||
sub.writerId := ENTITYID_P2P_BUILTIN_PARTICIPANT_MESSAGE_WRITER;
|
||||
sub.readerId := ENTITYID_P2P_BUILTIN_PARTICIPANT_MESSAGE_READER;
|
||||
sub.writerSN := gen_sn(2);
|
||||
sub.flags(SUBMESSAGE_DATA_FLAG_POS) := '1';
|
||||
participant := p0;
|
||||
gen_liveliness_assertion(p0, TRUE, rand_data, sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
gen_liveliness_update_frame(p0, reference);
|
||||
wr_sig := MANUAL_BY_PARTICIPANT_LIVELINESS_READERS;
|
||||
push_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
|
||||
TranscriptOpen(RESULTS_FILE, APPEND_MODE);
|
||||
SetTranscriptMirror;
|
||||
stim_done <= '1';
|
||||
wait until check_done = '1';
|
||||
AlertIf((not SB_out.empty) or (not SB_mem.empty), "Incomplete test run");
|
||||
AlertIf(not SB_out.empty, "Incomplete test run");
|
||||
ReportAlerts;
|
||||
TranscriptClose;
|
||||
std.env.stop;
|
||||
@ -358,30 +338,6 @@ begin
|
||||
end if;
|
||||
end process;
|
||||
|
||||
mem_check_prc : process
|
||||
alias mem is <<signal uut.ram_inst.mem : TEST_RAM_TYPE>>;
|
||||
alias mem_op_done is <<signal uut.mem_op_done : std_logic>>;
|
||||
variable reference : TEST_PARTICIPANT_MEMORY_FRAME_TYPE;
|
||||
begin
|
||||
-- SAFEGUARD: (Prevent Fall-through Behavior)
|
||||
if (reset /= '0') then
|
||||
wait until reset = '0';
|
||||
end if;
|
||||
-- NOTE: The first read after the packet is sent signifies that the State Machine has begun processing the next packet.
|
||||
-- The memory operation that could still be in progress is the last one concerning the last sent packet.
|
||||
wait until packet_sent = '1';
|
||||
wait until rising_edge(rd_sig);
|
||||
if (mem_op_done /= '1') then
|
||||
wait until mem_op_done = '1';
|
||||
end if;
|
||||
if (not SB_mem.empty) then
|
||||
SB_mem.Pop(reference);
|
||||
for i in 0 to reference'length-1 loop
|
||||
AffirmIf(?? (mem(reference(i).addr) ?= reference(i).data), "Address: " & integer'image(reference(i).addr) & " Received: " & to_hstring(mem(reference(i).addr)) & " Expected: " & to_hstring(reference(i).data));
|
||||
end loop;
|
||||
end if;
|
||||
end process;
|
||||
|
||||
watchdog : process
|
||||
begin
|
||||
wait for 1 ms;
|
||||
|
||||
@ -1,348 +0,0 @@
|
||||
library ieee;
|
||||
use ieee.std_logic_1164.all;
|
||||
use ieee.numeric_std.all;
|
||||
|
||||
library osvvm; -- Utility Library
|
||||
context osvvm.OsvvmContext;
|
||||
|
||||
use work.rtps_package.all;
|
||||
use work.user_config.all;
|
||||
use work.rtps_config_package.all;
|
||||
use work.rtps_test_package.all;
|
||||
|
||||
-- This testbench tests the handling of remote Liveliness Assertions
|
||||
-- The testbench matches 2 remote Participants, P0 and P1. P0 sends an automatic liveliness assertion, while P1 sends a manual liveliness assertion.
|
||||
-- P0 also sends a manual liveliness assertion with extra Bytes.
|
||||
|
||||
entity L0_rtps_builtin_endpoint_test7 is
|
||||
end entity;
|
||||
|
||||
architecture testbench of L0_rtps_builtin_endpoint_test7 is
|
||||
|
||||
-- *TYPE DECLARATION*
|
||||
type TEST_STAGE_TYPE is (IDLE, BUSY);
|
||||
|
||||
-- *SIGNAL DECLARATION*
|
||||
signal clk, in_empty, rd_sig, last_word_in, last_word_out: std_logic := '0';
|
||||
signal reset : std_logic := '1';
|
||||
signal endpoint_wr, endpoint_full : std_logic_vector(0 to NUM_ENDPOINTS-1) := (others => '0');
|
||||
signal data_in, data_out : std_logic_vector(WORD_WIDTH-1 downto 0) := (others => '0');
|
||||
signal stim_stage : TEST_STAGE_TYPE := IDLE;
|
||||
shared variable stimulus, reference : TEST_PACKET_TYPE := EMPTY_TEST_PACKET;
|
||||
signal packet_sent : std_logic := '0';
|
||||
signal cnt_stim : natural := 0;
|
||||
signal start : std_logic := '0';
|
||||
shared variable SB_out : work.ScoreBoardPkg_builtin_endpoint.ScoreBoardPType;
|
||||
signal stim_done, check_done, mem_check : std_logic := '0';
|
||||
|
||||
-- *FUNCTION DECLARATION*
|
||||
procedure wait_on_complete is
|
||||
begin
|
||||
wait until rising_edge(packet_sent);
|
||||
end procedure;
|
||||
|
||||
function gen_sn(input : natural) return SEQUENCENUMBER_TYPE is
|
||||
variable ret : SEQUENCENUMBER_TYPE;
|
||||
begin
|
||||
ret(0) := (others => '0');
|
||||
ret(1) := unsigned(int(input, WORD_WIDTH));
|
||||
return ret;
|
||||
end function;
|
||||
|
||||
begin
|
||||
|
||||
-- Unit Under Test
|
||||
uut : entity work.rtps_builtin_endpoint(arch)
|
||||
generic map (
|
||||
MAX_REMOTE_PARTICIPANTS => 2
|
||||
)
|
||||
port map (
|
||||
clk => clk,
|
||||
reset => reset,
|
||||
empty => in_empty or packet_sent,
|
||||
rd => rd_sig,
|
||||
data_in => data_in,
|
||||
data_out => data_out,
|
||||
last_word_in => last_word_in,
|
||||
time => TIME_ZERO,
|
||||
endpoint_full => endpoint_full,
|
||||
endpoint_wr => endpoint_wr,
|
||||
rtps_wr => open,
|
||||
rtps_full => '0',
|
||||
last_word_out => last_word_out,
|
||||
alive => (others => '0')
|
||||
);
|
||||
|
||||
stimulus_prc : process
|
||||
variable sub : RTPS_SUBMESSAGE_TYPE := DEFAULT_RTPS_SUBMESSAGE;
|
||||
variable RV : RandomPType;
|
||||
variable p0, p1, participant: PARTICIPANT_DATA_TYPE := DEFAULT_PARTICIPANT_DATA;
|
||||
variable wr_sig : std_logic_vector(0 to NUM_ENDPOINTS-1) := (others => '0');
|
||||
variable rand_data : TEST_PACKET_TYPE := EMPTY_TEST_PACKET;
|
||||
|
||||
-- Wrapper to use procedure as function
|
||||
impure function gen_rand_loc_2 return LOCATOR_TYPE is
|
||||
variable ret : LOCATOR_TYPE := EMPTY_LOCATOR;
|
||||
begin
|
||||
gen_rand_loc(RV, ret);
|
||||
return ret;
|
||||
end function;
|
||||
|
||||
impure function gen_rand_guid_prefix return GUIDPREFIX_TYPE is
|
||||
variable ret : GUIDPREFIX_TYPE;
|
||||
begin
|
||||
ret := (0 => RV.RandSlv(WORD_WIDTH), 1 => RV.RandSlv(WORD_WIDTH), 2 => RV.RandSlv(WORD_WIDTH));
|
||||
return ret;
|
||||
end function;
|
||||
|
||||
procedure push_reference is
|
||||
begin
|
||||
for i in 0 to reference.length-1 loop
|
||||
SB_out.Push(wr_sig & reference.last(i) & reference.data(i));
|
||||
end loop;
|
||||
end procedure;
|
||||
|
||||
procedure start_test is
|
||||
begin
|
||||
start <= '1';
|
||||
wait until rising_edge(clk);
|
||||
start <= '0';
|
||||
wait until rising_edge(clk);
|
||||
end procedure;
|
||||
begin
|
||||
|
||||
assert (TEST_STRING = "TEST_CONFIG_1") report "user_config incompatible with testbench." severity FAILURE;
|
||||
|
||||
SetAlertLogName("rtps_builtin_endpoint - Level 0 - Remote Liveliness Assertion Handling");
|
||||
SetAlertEnable(FAILURE, TRUE);
|
||||
SetAlertEnable(ERROR, TRUE);
|
||||
SetAlertEnable(WARNING, TRUE);
|
||||
SetLogEnable(DEBUG, FALSE);
|
||||
SetLogEnable(PASSED, FALSE);
|
||||
SetLogEnable(INFO, TRUE);
|
||||
RV.InitSeed(RV'instance_name);
|
||||
|
||||
-- Participant RTPS Submessage
|
||||
sub := DEFAULT_RTPS_SUBMESSAGE;
|
||||
sub.submessageID := SID_DATA;
|
||||
sub.writerId := ENTITYID_SPDP_BUILTIN_PARTICIPANT_ANNOUNCER;
|
||||
sub.readerId := ENTITYID_SPDP_BUILTIN_PARTICIPANT_DETECTOR;
|
||||
sub.flags(SUBMESSAGE_DATA_FLAG_POS) := '1';
|
||||
|
||||
-- Participant 0
|
||||
p0.guidPrefix := gen_rand_guid_prefix;
|
||||
p0.nr := 0;
|
||||
p0.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
p0.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_DETECTOR) := '1';
|
||||
p0.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_ANNOUNCER):= '1';
|
||||
p0.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_DETECTOR) := '1';
|
||||
p0.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_ANNOUNCER) := '1';
|
||||
|
||||
-- Participant 1
|
||||
p1.guidPrefix := gen_rand_guid_prefix;
|
||||
p1.nr := 1;
|
||||
p1.defaultUnicastLocatorList := (numLocators => int(1,CDR_LONG_WIDTH), locator => (0 => gen_rand_loc_2, others => EMPTY_LOCATOR));
|
||||
p1.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_DETECTOR) := '1';
|
||||
p1.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_SUBSCRIPTIONS_ANNOUNCER):= '1';
|
||||
p1.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_DETECTOR) := '1';
|
||||
p1.availableBuiltinEndpoints(DISC_BUILTIN_ENDPOINT_PUBLICATIONS_ANNOUNCER) := '1';
|
||||
|
||||
for i in 0 to RV.RandInt(1,10) loop
|
||||
rand_data.data(i) := RV.RandSlv(WORD_WIDTH);
|
||||
rand_data.length := rand_data.length + 1;
|
||||
end loop;
|
||||
|
||||
Log("Initiating Test", INFO);
|
||||
stim_done <= '0';
|
||||
start <= '0';
|
||||
reset <= '1';
|
||||
wait until rising_edge(clk);
|
||||
wait until rising_edge(clk);
|
||||
reset <= '0';
|
||||
|
||||
-- *PARTICIPANT*
|
||||
Log("Current Time: 0s", INFO);
|
||||
Log("Match Participant 0", INFO);
|
||||
sub := DEFAULT_RTPS_SUBMESSAGE;
|
||||
sub.submessageID := SID_DATA;
|
||||
sub.writerId := ENTITYID_SPDP_BUILTIN_PARTICIPANT_ANNOUNCER;
|
||||
sub.readerId := ENTITYID_SPDP_BUILTIN_PARTICIPANT_DETECTOR;
|
||||
sub.writerSN := gen_sn(1);
|
||||
sub.flags(SUBMESSAGE_DATA_FLAG_POS) := '1';
|
||||
participant := p0;
|
||||
gen_participant_data(participant, sub.data);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
|
||||
Log("Match Participant 1", INFO);
|
||||
sub := DEFAULT_RTPS_SUBMESSAGE;
|
||||
sub.submessageID := SID_DATA;
|
||||
sub.writerId := ENTITYID_SPDP_BUILTIN_PARTICIPANT_ANNOUNCER;
|
||||
sub.readerId := ENTITYID_SPDP_BUILTIN_PARTICIPANT_DETECTOR;
|
||||
sub.writerSN := gen_sn(1);
|
||||
sub.flags(SUBMESSAGE_DATA_FLAG_POS) := '1';
|
||||
participant := p1;
|
||||
gen_participant_data(participant, sub.data);
|
||||
gen_sentinel(sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
|
||||
Log("Participant 0 Automatic Liveliness Assertion", INFO);
|
||||
sub := DEFAULT_RTPS_SUBMESSAGE;
|
||||
sub.submessageID := SID_DATA;
|
||||
sub.writerId := ENTITYID_P2P_BUILTIN_PARTICIPANT_MESSAGE_WRITER;
|
||||
sub.readerId := ENTITYID_P2P_BUILTIN_PARTICIPANT_MESSAGE_READER;
|
||||
sub.writerSN := gen_sn(1);
|
||||
sub.flags(SUBMESSAGE_DATA_FLAG_POS) := '1';
|
||||
participant := p0;
|
||||
gen_liveliness_assertion(p0, FALSE, sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
gen_liveliness_update_frame(p0, reference);
|
||||
wr_sig := AUTOMATIC_LIVELINESS_READERS;
|
||||
push_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
|
||||
Log("Participant 1 Manual Liveliness Assertion", INFO);
|
||||
sub := DEFAULT_RTPS_SUBMESSAGE;
|
||||
sub.submessageID := SID_DATA;
|
||||
sub.writerId := ENTITYID_P2P_BUILTIN_PARTICIPANT_MESSAGE_WRITER;
|
||||
sub.readerId := ENTITYID_P2P_BUILTIN_PARTICIPANT_MESSAGE_READER;
|
||||
sub.writerSN := gen_sn(1);
|
||||
sub.flags(SUBMESSAGE_DATA_FLAG_POS) := '1';
|
||||
participant := p1;
|
||||
gen_liveliness_assertion(p1, TRUE, sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
gen_liveliness_update_frame(p1, reference);
|
||||
wr_sig := MANUAL_BY_PARTICIPANT_LIVELINESS_READERS;
|
||||
push_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
|
||||
Log("Participant 0 Manual Liveliness Assertion [+DATA Bytes]", INFO);
|
||||
sub := DEFAULT_RTPS_SUBMESSAGE;
|
||||
sub.submessageID := SID_DATA;
|
||||
sub.writerId := ENTITYID_P2P_BUILTIN_PARTICIPANT_MESSAGE_WRITER;
|
||||
sub.readerId := ENTITYID_P2P_BUILTIN_PARTICIPANT_MESSAGE_READER;
|
||||
sub.writerSN := gen_sn(2);
|
||||
sub.flags(SUBMESSAGE_DATA_FLAG_POS) := '1';
|
||||
participant := p0;
|
||||
gen_liveliness_assertion(p0, TRUE, rand_data, sub.data);
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
gen_liveliness_update_frame(p0, reference);
|
||||
wr_sig := MANUAL_BY_PARTICIPANT_LIVELINESS_READERS;
|
||||
push_reference;
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
reference := EMPTY_TEST_PACKET;
|
||||
|
||||
TranscriptOpen(RESULTS_FILE, APPEND_MODE);
|
||||
SetTranscriptMirror;
|
||||
stim_done <= '1';
|
||||
wait until check_done = '1';
|
||||
AlertIf(not SB_out.empty, "Incomplete test run");
|
||||
ReportAlerts;
|
||||
TranscriptClose;
|
||||
std.env.stop;
|
||||
wait;
|
||||
end process;
|
||||
|
||||
clock_prc : process
|
||||
begin
|
||||
clk <= '0';
|
||||
wait for 25 ns;
|
||||
clk <= '1';
|
||||
wait for 25 ns;
|
||||
end process;
|
||||
|
||||
in_empty_prc : process
|
||||
begin
|
||||
in_empty <= '0';
|
||||
wait until rd_sig = '1';
|
||||
wait until rising_edge(clk);
|
||||
in_empty <= '1';
|
||||
wait until rising_edge(clk);
|
||||
end process;
|
||||
|
||||
endpoint_full_prc : process
|
||||
begin
|
||||
endpoint_full <= (others => '0');
|
||||
wait until (or endpoint_wr) = '1';
|
||||
wait until rising_edge(clk);
|
||||
endpoint_full <= (others => '1');
|
||||
wait until rising_edge(clk);
|
||||
end process;
|
||||
|
||||
alert_prc : process(all)
|
||||
begin
|
||||
if rising_edge(clk) then
|
||||
alertif(in_empty = '1' and rd_sig = '1', "Input FIFO read signal high while empty signal high", ERROR);
|
||||
alertif(endpoint_full /= (0 to NUM_ENDPOINTS-1 => '0') and (endpoint_wr /= (0 to NUM_ENDPOINTS-1 => '0')), "Endpoint FIFO write signal high while full signal high", ERROR);
|
||||
end if;
|
||||
end process;
|
||||
|
||||
input_prc : process(all)
|
||||
begin
|
||||
data_in <= stimulus.data(cnt_stim);
|
||||
last_word_in <= stimulus.last(cnt_stim);
|
||||
|
||||
if rising_edge(clk) then
|
||||
if (reset = '1') then
|
||||
cnt_stim <= 0;
|
||||
stim_stage <= IDLE;
|
||||
packet_sent <= '1';
|
||||
else
|
||||
case (stim_stage) is
|
||||
when IDLE =>
|
||||
if (start = '1' and stimulus.length /= 0) then
|
||||
stim_stage <= BUSY;
|
||||
packet_sent <= '0';
|
||||
end if;
|
||||
when BUSY =>
|
||||
if (rd_sig = '1') then
|
||||
if (cnt_stim = stimulus.length-1) then
|
||||
stim_stage <= IDLE;
|
||||
packet_sent <= '1';
|
||||
cnt_stim <= 0;
|
||||
else
|
||||
cnt_stim <= cnt_stim + 1;
|
||||
end if;
|
||||
end if;
|
||||
end case;
|
||||
end if;
|
||||
end if;
|
||||
end process;
|
||||
|
||||
output_check_prc : process(all)
|
||||
begin
|
||||
check_done <= '0';
|
||||
if rising_edge(clk) then
|
||||
if (endpoint_wr /= (0 to NUM_ENDPOINTS-1 => '0')) then
|
||||
SB_out.Check(endpoint_wr & last_word_out & data_out);
|
||||
end if;
|
||||
if (stim_done = '1' and SB_out.empty) then
|
||||
check_done <= '1';
|
||||
end if;
|
||||
end if;
|
||||
end process;
|
||||
|
||||
watchdog : process
|
||||
begin
|
||||
wait for 1 ms;
|
||||
Alert("Test timeout", FAILURE);
|
||||
std.env.stop;
|
||||
end process;
|
||||
|
||||
end architecture;
|
||||
@ -440,9 +440,7 @@ begin
|
||||
variable RV : RandomPType;
|
||||
variable p0, participant : PARTICIPANT_DATA_TYPE := DEFAULT_PARTICIPANT_DATA;
|
||||
|
||||
-- NOTE: The stale_check variable is set everytime a Participant Stale Check is done (which is done in last priority).
|
||||
-- We use this together with mem_op_done to "synchronize" the stimulus process.
|
||||
alias stale_check is <<signal uut.stale_check : std_logic>>;
|
||||
alias idle_sig is <<signal uut.idle_sig : std_logic>>;
|
||||
alias mem_op_done is <<signal uut.mem_op_done : std_logic>>;
|
||||
|
||||
-- Wrapper to use procedure as function
|
||||
@ -474,6 +472,24 @@ begin
|
||||
start <= '0';
|
||||
wait until rising_edge(clk);
|
||||
end procedure;
|
||||
|
||||
-- NOTE: This procedure waits until the idle_sig is high for at least
|
||||
-- two consecutive clock cycles.
|
||||
procedure wait_on_idle is
|
||||
variable first : boolean := TRUE;
|
||||
begin
|
||||
loop
|
||||
if (idle_sig /= '1' or mem_op_done /= '1') then
|
||||
wait until idle_sig = '1' and mem_op_done = '1';
|
||||
elsif (not first) then
|
||||
exit;
|
||||
end if;
|
||||
wait until rising_edge(clk);
|
||||
wait until rising_edge(clk);
|
||||
first := FALSE;
|
||||
end loop;
|
||||
end procedure;
|
||||
|
||||
begin
|
||||
|
||||
assert (TEST_STRING = "TEST_CONFIG_1") report "user_config incompatible with testbench." severity FAILURE;
|
||||
@ -523,10 +539,9 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_idle;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
|
||||
-- *ACKNACK*
|
||||
|
||||
Log("Send Remote Publisher Heartbeat [Empty, Final Flag] (No Response, Final Flag)", INFO);
|
||||
@ -544,10 +559,9 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_idle;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
|
||||
-- Progress time past the HEARTBEAT RESPONSE DELAY
|
||||
Log("Current Time: 0.105s", INFO);
|
||||
test_time <= gen_duration(0,105*(10**6));
|
||||
@ -566,10 +580,9 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_idle;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
|
||||
Log("Send Remote Subscriber Heartbeat [Empty, Final Flag] (No Change)", INFO);
|
||||
-- RTPS SUBMESSAGE
|
||||
sub := DEFAULT_RTPS_SUBMESSAGE;
|
||||
@ -585,10 +598,9 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_idle;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
|
||||
Log("Send Remote Message AckNack [Expecting 1] (Response)", INFO);
|
||||
-- RTPS SUBMESSAGE
|
||||
sub := DEFAULT_RTPS_SUBMESSAGE;
|
||||
@ -602,30 +614,26 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_idle;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
|
||||
Log("Current Time: 0.210s", INFO);
|
||||
test_time <= gen_duration(0,210*(10**6));
|
||||
|
||||
gen_acknack(p0, 1, gen_sn(1), gen_sn(1), gen_sn(1));
|
||||
wait_on_idle;
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
|
||||
Log("Toggle local Writer 4 Liveliness for 1 clock cycle (MANUAL_BY_PARTICIPANT_QOS)", INFO);
|
||||
alive(NUM_READERS+4) <= '1';
|
||||
wait until rising_edge(clk);
|
||||
alive <= (others => '0');
|
||||
wait_on_idle;
|
||||
|
||||
Log("Current Time: 0.310s", INFO);
|
||||
test_time <= gen_duration(0,310*(10**6));
|
||||
|
||||
gen_data(p0, FALSE, FALSE, TRUE, gen_sn(1), gen_sn(2));
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait_on_idle;
|
||||
|
||||
Log("Send Remote Publisher Heartbeat [First 1, Last 1] (No Response, Suppression Delay)", INFO);
|
||||
-- RTPS SUBMESSAGE
|
||||
@ -641,15 +649,12 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_idle;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
|
||||
Log("Current Time: 0.415s", INFO);
|
||||
test_time <= gen_duration(0,415*(10**6));
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait_on_idle;
|
||||
|
||||
Log("Send Remote Publisher Heartbeat [First 1, Last 5] (Response)", INFO);
|
||||
-- RTPS SUBMESSAGE
|
||||
@ -665,10 +670,9 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_idle;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
|
||||
Log("Send Remote Publisher AckNack [Expecting 1] (No Response, Suppression Delay)", INFO);
|
||||
-- RTPS SUBMESSAGE
|
||||
sub := DEFAULT_RTPS_SUBMESSAGE;
|
||||
@ -682,15 +686,12 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_idle;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
|
||||
Log("Current Time: 0.450s", INFO);
|
||||
test_time <= gen_duration(0,450*(10**6));
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait_on_idle;
|
||||
|
||||
Log("Send Remote Subscriber Heartbeat [First 2, Last 5] (Update Response)", INFO);
|
||||
-- RTPS SUBMESSAGE
|
||||
@ -706,17 +707,13 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_idle;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
|
||||
Log("Current Time: 0.520s", INFO);
|
||||
test_time <= gen_duration(0,520*(10**6));
|
||||
|
||||
gen_acknack(p0, 2, gen_sn(1), gen_sn(2), gen_sn(1));
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait_on_idle;
|
||||
|
||||
Log("Send Remote Publisher AckNack [Expecting 1] (Response)", INFO);
|
||||
-- RTPS SUBMESSAGE
|
||||
@ -731,12 +728,12 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_idle;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
|
||||
Log("Current Time: 0.620s", INFO);
|
||||
test_time <= gen_duration(0,620*(10**6));
|
||||
wait_on_idle;
|
||||
|
||||
Log("Send Remote Subscriber AckNack [Expecting 1] (Update Response)", INFO);
|
||||
-- RTPS SUBMESSAGE
|
||||
@ -751,25 +748,18 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_idle;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
|
||||
Log("Current Time: 0.725s", INFO);
|
||||
test_time <= gen_duration(0,725*(10**6));
|
||||
|
||||
gen_data(p0, TRUE, TRUE, FALSE, SEQUENCENUMBER_UNKNOWN, SEQUENCENUMBER_UNKNOWN);
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait_on_idle;
|
||||
|
||||
Log("Current Time: 1s", INFO);
|
||||
test_time <= gen_duration(1,0);
|
||||
|
||||
gen_heartbeat(p0, 3, gen_sn(3), gen_sn(4));
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait_on_idle;
|
||||
|
||||
Log("Send Remote Subscriber AckNack [Expecting 8] (Response)", INFO);
|
||||
-- RTPS SUBMESSAGE
|
||||
@ -784,23 +774,17 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_idle;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
|
||||
Log("Current Time: 1.205s", INFO);
|
||||
test_time <= gen_duration(1,205*(10**6));
|
||||
|
||||
gen_data(p0, TRUE, FALSE, FALSE, SEQUENCENUMBER_UNKNOWN, SEQUENCENUMBER_UNKNOWN);
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait_on_idle;
|
||||
|
||||
Log("Current Time: 1.500s", INFO);
|
||||
test_time <= gen_duration(1,500*(10**6));
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait_on_idle;
|
||||
|
||||
Log("Send Remote Publisher AckNack [Expecting 18] (No Response)", INFO);
|
||||
-- RTPS SUBMESSAGE
|
||||
@ -815,21 +799,17 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_idle;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
|
||||
Log("Current Time: 1.705s", INFO);
|
||||
test_time <= gen_duration(1,705*(10**6));
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait_on_idle;
|
||||
|
||||
Log("Current Time: 2s", INFO);
|
||||
test_time <= gen_duration(2,0);
|
||||
|
||||
gen_heartbeat(p0, 4, gen_sn(3), gen_sn(5));
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait_on_idle;
|
||||
|
||||
Log("Send Remote Message AckNack [Expecting 5] (Response)", INFO);
|
||||
-- RTPS SUBMESSAGE
|
||||
@ -844,10 +824,9 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_idle;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
|
||||
Log("Send Remote Publisher AckNack [Expecting 2] (No Response)", INFO);
|
||||
-- RTPS SUBMESSAGE
|
||||
sub := DEFAULT_RTPS_SUBMESSAGE;
|
||||
@ -861,10 +840,9 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_idle;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
|
||||
Log("Send Remote Subscriber AckNack [Expecting 8] (Response)", INFO);
|
||||
-- RTPS SUBMESSAGE
|
||||
sub := DEFAULT_RTPS_SUBMESSAGE;
|
||||
@ -878,28 +856,23 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_idle;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
|
||||
Log("Current Time: 2.205s", INFO);
|
||||
test_time <= gen_duration(2,205*(10**6));
|
||||
|
||||
gen_data(p0, TRUE, TRUE, TRUE, gen_sn(3), gen_sn(5));
|
||||
wait_on_idle;
|
||||
|
||||
Log("Toggle local Writer 0 Liveliness for 1 clock cycle (AUTOMATIC_QOS)", INFO);
|
||||
alive(NUM_READERS) <= '1';
|
||||
wait until rising_edge(clk);
|
||||
alive <= (others => '0');
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait_on_idle;
|
||||
|
||||
Log("Current Time: 2.500s", INFO);
|
||||
test_time <= gen_duration(2,500*(10**6));
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait_on_idle;
|
||||
|
||||
Log("Send Remote Message AckNack [Expecting 6] (No Response)", INFO);
|
||||
-- RTPS SUBMESSAGE
|
||||
@ -914,30 +887,23 @@ begin
|
||||
gen_rtps_handler_out(sub, participant, stimulus);
|
||||
start_test;
|
||||
wait_on_complete;
|
||||
wait_on_idle;
|
||||
stimulus := EMPTY_TEST_PACKET;
|
||||
|
||||
Log("Current Time: 2.705s", INFO);
|
||||
test_time <= gen_duration(2,705*(10**6));
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait_on_idle;
|
||||
|
||||
Log("Current Time: 3s", INFO);
|
||||
test_time <= gen_duration(3,0);
|
||||
|
||||
gen_heartbeat(p0, 5, gen_sn(6), gen_sn(7));
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait_on_idle;
|
||||
|
||||
Log("Current Time: 31s", INFO);
|
||||
test_time <= gen_duration(31,0);
|
||||
|
||||
gen_announcement;
|
||||
gen_heartbeat(p0, 6, gen_sn(6), gen_sn(8));
|
||||
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait on mem_op_done until rising_edge(mem_op_done) and stale_check = '1';
|
||||
wait_on_idle;
|
||||
|
||||
TranscriptOpen(RESULTS_FILE, APPEND_MODE);
|
||||
SetTranscriptMirror;
|
||||
@ -1007,6 +973,7 @@ begin
|
||||
if (cnt_stim = stimulus.length-1) then
|
||||
stim_stage <= IDLE;
|
||||
packet_sent <= '1';
|
||||
cnt_stim <= 0;
|
||||
else
|
||||
cnt_stim <= cnt_stim + 1;
|
||||
end if;
|
||||
|
||||
@ -20,128 +20,126 @@ analyze ../rtps_reader.vhd
|
||||
analyze ../rtps_writer.vhd
|
||||
analyze ../dds_writer.vhd
|
||||
analyze ../dds_reader.vhd
|
||||
#analyze Level_0/L0_rtps_handler_test1.vhd
|
||||
#analyze Level_0/L0_rtps_handler_test2.vhd
|
||||
#analyze Level_0/L0_rtps_builtin_endpoint_test1.vhd
|
||||
#analyze Level_0/L0_rtps_builtin_endpoint_test2.vhd
|
||||
#analyze Level_0/L0_rtps_builtin_endpoint_test3.vhd
|
||||
#analyze Level_0/L0_rtps_builtin_endpoint_test4.vhd
|
||||
#analyze Level_0/L0_rtps_builtin_endpoint_test5.vhd
|
||||
#analyze Level_0/L0_rtps_builtin_endpoint_test6.vhd
|
||||
#analyze Level_0/L0_rtps_builtin_endpoint_test7.vhd
|
||||
#analyze Level_0/L0_rtps_out_test1.vhd
|
||||
#analyze Level_1/L1_rtps_builtin_endpoint_test1.vhd
|
||||
#analyze Level_0/L0_mem_ctrl_test1.vhd
|
||||
#analyze Level_0/L0_rtps_reader_test1_vrk.vhd
|
||||
#analyze Level_0/L0_rtps_reader_test1_vbk.vhd
|
||||
#analyze Level_0/L0_rtps_reader_test2_vrk.vhd
|
||||
#analyze Level_0/L0_rtps_reader_test2_trk.vhd
|
||||
#analyze Level_0/L0_rtps_reader_test2_vbk.vhd
|
||||
#analyze Level_0/L0_rtps_reader_test2_tbk.vhd
|
||||
#analyze Level_0/L0_rtps_reader_test2_vrn.vhd
|
||||
#analyze Level_0/L0_rtps_reader_test3_a.vhd
|
||||
#analyze Level_0/L0_rtps_reader_test3_m.vhd
|
||||
#analyze Level_1/L1_rtps_reader_test1_vrk.vhd
|
||||
#analyze Level_1/L1_rtps_reader_test1_trk.vhd
|
||||
#analyze Level_0/L0_rtps_writer_test1_vrkdp.vhd
|
||||
#analyze Level_0/L0_rtps_writer_test1_vbkdp.vhd
|
||||
#analyze Level_1/L1_rtps_writer_test1_vrkdp.vhd
|
||||
#analyze Level_1/L1_rtps_writer_test1_trkdp.vhd
|
||||
#analyze Level_1/L1_rtps_writer_test1_tbkdp.vhd
|
||||
#analyze Level_1/L1_rtps_writer_test1_vbkdp.vhd
|
||||
#analyze Level_1/L1_rtps_writer_test1_vrndp.vhd
|
||||
#analyze Level_1/L1_rtps_writer_test1_vrksp.vhd
|
||||
#analyze Level_1/L1_rtps_writer_test1_vrkdn.vhd
|
||||
#analyze Level_1/L1_rtps_writer_test1_trkdn.vhd
|
||||
#analyze Level_1/L1_rtps_writer_test2_vrkdn.vhd
|
||||
#analyze Level_0/L0_rtps_writer_test2_vrkdp.vhd
|
||||
#analyze Level_0/L0_dds_writer_test1_aik.vhd
|
||||
#analyze Level_0/L0_dds_writer_test1_ain.vhd
|
||||
#analyze Level_0/L0_dds_writer_test1_lik.vhd
|
||||
#analyze Level_0/L0_dds_writer_test1_afk.vhd
|
||||
#analyze Level_0/L0_dds_writer_test2_aik.vhd
|
||||
#analyze Level_0/L0_dds_writer_test3_aik.vhd
|
||||
#analyze Level_0/L0_dds_writer_test3_ain.vhd
|
||||
#analyze Level_0/L0_dds_writer_test4_aik.vhd
|
||||
#analyze Level_0/L0_dds_writer_test5_afk.vhd
|
||||
#analyze Level_0/L0_dds_reader_test1_arzkriu.vhd
|
||||
#analyze Level_0/L0_dds_reader_test1_lrzkriu.vhd
|
||||
#analyze Level_0/L0_dds_reader_test1_lbzkriu.vhd
|
||||
#analyze Level_0/L0_dds_reader_test1_abzkriu.vhd
|
||||
#analyze Level_0/L0_dds_reader_test1_arznriu.vhd
|
||||
#analyze Level_0/L0_dds_reader_test1_arzksiu.vhd
|
||||
#analyze Level_0/L0_dds_reader_test2_arpkriu.vhd
|
||||
#analyze Level_0/L0_dds_reader_test3_arzkriu.vhd
|
||||
#analyze Level_0/L0_dds_reader_test3_arzkrio.vhd
|
||||
#analyze Level_0/L0_dds_reader_test3_arzkrtu.vhd
|
||||
#analyze Level_0/L0_dds_reader_test3_arzkrto.vhd
|
||||
#analyze Level_0/L0_dds_reader_test3_arznriu.vhd
|
||||
#analyze Level_0/L0_dds_reader_test3_arzksto.vhd
|
||||
#analyze Level_0/L0_dds_reader_test4_arzkriu.vhd
|
||||
#analyze Level_0/L0_dds_reader_test4_arznriu.vhd
|
||||
#analyze Level_0/L0_dds_reader_test5_arzkriu.vhd
|
||||
#analyze Level_0/L0_dds_reader_test6_arzkriu.vhd
|
||||
analyze Level_0/L0_rtps_handler_test1.vhd
|
||||
analyze Level_0/L0_rtps_handler_test2.vhd
|
||||
analyze Level_0/L0_rtps_builtin_endpoint_test1.vhd
|
||||
analyze Level_0/L0_rtps_builtin_endpoint_test2.vhd
|
||||
analyze Level_0/L0_rtps_builtin_endpoint_test3.vhd
|
||||
analyze Level_0/L0_rtps_builtin_endpoint_test4.vhd
|
||||
analyze Level_0/L0_rtps_builtin_endpoint_test5.vhd
|
||||
analyze Level_0/L0_rtps_builtin_endpoint_test6.vhd
|
||||
analyze Level_0/L0_rtps_out_test1.vhd
|
||||
analyze Level_1/L1_rtps_builtin_endpoint_test1.vhd
|
||||
analyze Level_0/L0_mem_ctrl_test1.vhd
|
||||
analyze Level_0/L0_rtps_reader_test1_vrk.vhd
|
||||
analyze Level_0/L0_rtps_reader_test1_vbk.vhd
|
||||
analyze Level_0/L0_rtps_reader_test2_vrk.vhd
|
||||
analyze Level_0/L0_rtps_reader_test2_trk.vhd
|
||||
analyze Level_0/L0_rtps_reader_test2_vbk.vhd
|
||||
analyze Level_0/L0_rtps_reader_test2_tbk.vhd
|
||||
analyze Level_0/L0_rtps_reader_test2_vrn.vhd
|
||||
analyze Level_0/L0_rtps_reader_test3_a.vhd
|
||||
analyze Level_0/L0_rtps_reader_test3_m.vhd
|
||||
analyze Level_1/L1_rtps_reader_test1_vrk.vhd
|
||||
analyze Level_1/L1_rtps_reader_test1_trk.vhd
|
||||
analyze Level_0/L0_rtps_writer_test1_vrkdp.vhd
|
||||
analyze Level_0/L0_rtps_writer_test1_vbkdp.vhd
|
||||
analyze Level_1/L1_rtps_writer_test1_vrkdp.vhd
|
||||
analyze Level_1/L1_rtps_writer_test1_trkdp.vhd
|
||||
analyze Level_1/L1_rtps_writer_test1_tbkdp.vhd
|
||||
analyze Level_1/L1_rtps_writer_test1_vbkdp.vhd
|
||||
analyze Level_1/L1_rtps_writer_test1_vrndp.vhd
|
||||
analyze Level_1/L1_rtps_writer_test1_vrksp.vhd
|
||||
analyze Level_1/L1_rtps_writer_test1_vrkdn.vhd
|
||||
analyze Level_1/L1_rtps_writer_test1_trkdn.vhd
|
||||
analyze Level_1/L1_rtps_writer_test2_vrkdn.vhd
|
||||
analyze Level_0/L0_rtps_writer_test2_vrkdp.vhd
|
||||
analyze Level_0/L0_dds_writer_test1_aik.vhd
|
||||
analyze Level_0/L0_dds_writer_test1_ain.vhd
|
||||
analyze Level_0/L0_dds_writer_test1_lik.vhd
|
||||
analyze Level_0/L0_dds_writer_test1_afk.vhd
|
||||
analyze Level_0/L0_dds_writer_test2_aik.vhd
|
||||
analyze Level_0/L0_dds_writer_test3_aik.vhd
|
||||
analyze Level_0/L0_dds_writer_test3_ain.vhd
|
||||
analyze Level_0/L0_dds_writer_test4_aik.vhd
|
||||
analyze Level_0/L0_dds_writer_test5_afk.vhd
|
||||
analyze Level_0/L0_dds_reader_test1_arzkriu.vhd
|
||||
analyze Level_0/L0_dds_reader_test1_lrzkriu.vhd
|
||||
analyze Level_0/L0_dds_reader_test1_lbzkriu.vhd
|
||||
analyze Level_0/L0_dds_reader_test1_abzkriu.vhd
|
||||
analyze Level_0/L0_dds_reader_test1_arznriu.vhd
|
||||
analyze Level_0/L0_dds_reader_test1_arzksiu.vhd
|
||||
analyze Level_0/L0_dds_reader_test2_arpkriu.vhd
|
||||
analyze Level_0/L0_dds_reader_test3_arzkriu.vhd
|
||||
analyze Level_0/L0_dds_reader_test3_arzkrio.vhd
|
||||
analyze Level_0/L0_dds_reader_test3_arzkrtu.vhd
|
||||
analyze Level_0/L0_dds_reader_test3_arzkrto.vhd
|
||||
analyze Level_0/L0_dds_reader_test3_arznriu.vhd
|
||||
analyze Level_0/L0_dds_reader_test3_arzksto.vhd
|
||||
analyze Level_0/L0_dds_reader_test4_arzkriu.vhd
|
||||
analyze Level_0/L0_dds_reader_test4_arznriu.vhd
|
||||
analyze Level_0/L0_dds_reader_test5_arzkriu.vhd
|
||||
analyze Level_0/L0_dds_reader_test6_arzkriu.vhd
|
||||
analyze Level_0/L0_dds_reader_test7_arzkriu.vhd
|
||||
|
||||
#simulate L0_rtps_handler_test1
|
||||
#simulate L0_rtps_handler_test2
|
||||
#simulate L0_rtps_builtin_endpoint_test1
|
||||
#simulate L0_rtps_builtin_endpoint_test2
|
||||
#simulate L0_rtps_builtin_endpoint_test3
|
||||
#simulate L0_rtps_builtin_endpoint_test4
|
||||
#simulate L0_rtps_builtin_endpoint_test5
|
||||
#simulate L0_rtps_builtin_endpoint_test6
|
||||
#simulate L0_rtps_builtin_endpoint_test7
|
||||
#simulate L0_rtps_out_test1
|
||||
#simulate L1_rtps_builtin_endpoint_test1
|
||||
#simulate L0_mem_ctrl_test1
|
||||
#simulate L0_rtps_reader_test1_vrk
|
||||
#simulate L0_rtps_reader_test1_vbk
|
||||
#simulate L0_rtps_reader_test2_vrk
|
||||
#simulate L0_rtps_reader_test2_trk
|
||||
#simulate L0_rtps_reader_test2_vbk
|
||||
#simulate L0_rtps_reader_test2_tbk
|
||||
#simulate L0_rtps_reader_test2_vrn
|
||||
#simulate L0_rtps_reader_test3_a
|
||||
#simulate L0_rtps_reader_test3_m
|
||||
#simulate L1_rtps_reader_test1_vrk
|
||||
#simulate L1_rtps_reader_test1_trk
|
||||
#simulate L0_rtps_writer_test1_vrkdp
|
||||
#simulate L0_rtps_writer_test1_vbkdp
|
||||
#simulate L1_rtps_writer_test1_vrkdp
|
||||
#simulate L1_rtps_writer_test1_trkdp
|
||||
#simulate L1_rtps_writer_test1_tbkdp
|
||||
#simulate L1_rtps_writer_test1_vbkdp
|
||||
#simulate L1_rtps_writer_test1_vrndp
|
||||
#simulate L1_rtps_writer_test1_vrksp
|
||||
#simulate L1_rtps_writer_test1_vrkdn
|
||||
#simulate L1_rtps_writer_test1_trkdn
|
||||
#simulate L1_rtps_writer_test2_vrkdn
|
||||
#simulate L0_rtps_writer_test2_vrkdp
|
||||
#simulate L0_dds_writer_test1_aik
|
||||
#simulate L0_dds_writer_test1_ain
|
||||
#simulate L0_dds_writer_test1_lik
|
||||
#simulate L0_dds_writer_test1_afk
|
||||
#simulate L0_dds_writer_test2_aik
|
||||
#simulate L0_dds_writer_test3_aik
|
||||
#simulate L0_dds_writer_test3_ain
|
||||
#simulate L0_dds_writer_test4_aik
|
||||
#simulate L0_dds_writer_test5_afk
|
||||
#simulate L0_dds_reader_test1_arzkriu
|
||||
#simulate L0_dds_reader_test1_lrzkriu
|
||||
#simulate L0_dds_reader_test1_lbzkriu
|
||||
#simulate L0_dds_reader_test1_abzkriu
|
||||
#simulate L0_dds_reader_test1_arznriu
|
||||
#simulate L0_dds_reader_test1_arzksiu
|
||||
#simulate L0_dds_reader_test2_arpkriu
|
||||
#simulate L0_dds_reader_test3_arzkriu
|
||||
#simulate L0_dds_reader_test3_arzkrio
|
||||
#simulate L0_dds_reader_test3_arzkrtu
|
||||
#simulate L0_dds_reader_test3_arzkrto
|
||||
#simulate L0_dds_reader_test3_arznriu
|
||||
#simulate L0_dds_reader_test3_arzksto
|
||||
#simulate L0_dds_reader_test4_arzkriu
|
||||
#simulate L0_dds_reader_test4_arznriu
|
||||
#simulate L0_dds_reader_test5_arzkriu
|
||||
#simulate L0_dds_reader_test6_arzkriu
|
||||
simulate L0_rtps_handler_test1
|
||||
simulate L0_rtps_handler_test2
|
||||
simulate L0_rtps_builtin_endpoint_test1
|
||||
simulate L0_rtps_builtin_endpoint_test2
|
||||
simulate L0_rtps_builtin_endpoint_test3
|
||||
simulate L0_rtps_builtin_endpoint_test4
|
||||
simulate L0_rtps_builtin_endpoint_test5
|
||||
simulate L0_rtps_builtin_endpoint_test6
|
||||
simulate L0_rtps_out_test1
|
||||
simulate L1_rtps_builtin_endpoint_test1
|
||||
simulate L0_mem_ctrl_test1
|
||||
simulate L0_rtps_reader_test1_vrk
|
||||
simulate L0_rtps_reader_test1_vbk
|
||||
simulate L0_rtps_reader_test2_vrk
|
||||
simulate L0_rtps_reader_test2_trk
|
||||
simulate L0_rtps_reader_test2_vbk
|
||||
simulate L0_rtps_reader_test2_tbk
|
||||
simulate L0_rtps_reader_test2_vrn
|
||||
simulate L0_rtps_reader_test3_a
|
||||
simulate L0_rtps_reader_test3_m
|
||||
simulate L1_rtps_reader_test1_vrk
|
||||
simulate L1_rtps_reader_test1_trk
|
||||
simulate L0_rtps_writer_test1_vrkdp
|
||||
simulate L0_rtps_writer_test1_vbkdp
|
||||
simulate L1_rtps_writer_test1_vrkdp
|
||||
simulate L1_rtps_writer_test1_trkdp
|
||||
simulate L1_rtps_writer_test1_tbkdp
|
||||
simulate L1_rtps_writer_test1_vbkdp
|
||||
simulate L1_rtps_writer_test1_vrndp
|
||||
simulate L1_rtps_writer_test1_vrksp
|
||||
simulate L1_rtps_writer_test1_vrkdn
|
||||
simulate L1_rtps_writer_test1_trkdn
|
||||
simulate L1_rtps_writer_test2_vrkdn
|
||||
simulate L0_rtps_writer_test2_vrkdp
|
||||
simulate L0_dds_writer_test1_aik
|
||||
simulate L0_dds_writer_test1_ain
|
||||
simulate L0_dds_writer_test1_lik
|
||||
simulate L0_dds_writer_test1_afk
|
||||
simulate L0_dds_writer_test2_aik
|
||||
simulate L0_dds_writer_test3_aik
|
||||
simulate L0_dds_writer_test3_ain
|
||||
simulate L0_dds_writer_test4_aik
|
||||
simulate L0_dds_writer_test5_afk
|
||||
simulate L0_dds_reader_test1_arzkriu
|
||||
simulate L0_dds_reader_test1_lrzkriu
|
||||
simulate L0_dds_reader_test1_lbzkriu
|
||||
simulate L0_dds_reader_test1_abzkriu
|
||||
simulate L0_dds_reader_test1_arznriu
|
||||
simulate L0_dds_reader_test1_arzksiu
|
||||
simulate L0_dds_reader_test2_arpkriu
|
||||
simulate L0_dds_reader_test3_arzkriu
|
||||
simulate L0_dds_reader_test3_arzkrio
|
||||
simulate L0_dds_reader_test3_arzkrtu
|
||||
simulate L0_dds_reader_test3_arzkrto
|
||||
simulate L0_dds_reader_test3_arznriu
|
||||
simulate L0_dds_reader_test3_arzksto
|
||||
simulate L0_dds_reader_test4_arzkriu
|
||||
simulate L0_dds_reader_test4_arznriu
|
||||
simulate L0_dds_reader_test5_arzkriu
|
||||
simulate L0_dds_reader_test6_arzkriu
|
||||
simulate L0_dds_reader_test7_arzkriu
|
||||
File diff suppressed because it is too large
Load Diff
@ -96,7 +96,7 @@ package rtps_config_package is
|
||||
end record;
|
||||
constant READER_ENDPOINT_DATA : OUTPUT_DATA_TYPE; --Deferred to package body
|
||||
constant WRITER_ENDPOINT_DATA : OUTPUT_DATA_TYPE; --Deferred to package body
|
||||
constant PARTICIPANT_DATA : OUTPUT_DATA_TYPE; --Deferred to package body
|
||||
constant LOCAL_PARTICIPANT_DATA : OUTPUT_DATA_TYPE; --Deferred to package body
|
||||
|
||||
type STRING_WORD_ARRAY_TYPE is array (0 to (256/(WORD_WIDTH/8))-1) of std_logic_vector(WORD_WIDTH-1 downto 0);
|
||||
type ENDPOINT_STRING_TYPE is array (0 to NUM_ENDPOINTS-1) of STRING_WORD_ARRAY_TYPE;
|
||||
@ -1015,7 +1015,7 @@ package body rtps_config_package is
|
||||
return ret;
|
||||
end function;
|
||||
|
||||
constant PARTICIPANT_DATA : OUTPUT_DATA_TYPE := gen_participant_data;
|
||||
constant LOCAL_PARTICIPANT_DATA : OUTPUT_DATA_TYPE := gen_participant_data;
|
||||
|
||||
|
||||
-- Direction 0 : Offered <= Requested
|
||||
|
||||
@ -17,7 +17,7 @@ package rtps_test_package is
|
||||
|
||||
-- Frame Sizes have to be specified, so that direct memory probing is possible
|
||||
-- rtps_builtin_endpoint Participant Frame Size
|
||||
constant PARTICIPANT_FRAME_SIZE : natural := 23;
|
||||
constant PARTICIPANT_FRAME_SIZE : natural := 24;
|
||||
-- rtps_reader Endpoint Frame Size (RELIABLE=TRUE)
|
||||
constant WRITER_ENDPOINT_FRAME_SIZE_A : natural := 12;
|
||||
-- rtps_reader Endpoint Frame Size (RELIABLE=FALSE)
|
||||
@ -458,6 +458,17 @@ package rtps_test_package is
|
||||
-- pos ID (Memory Position) of Source Remote Writer
|
||||
-- output Destination of generated output
|
||||
procedure gen_add_cache_change_dds(ref : in CACHE_CHANGE_TYPE; lifespan_deadline : in TIME_TYPE; pos : in natural; output : inout TEST_PACKET_TYPE);
|
||||
-- Generate a rtps_reader memory Participant Frame based on "ref". (A Version)
|
||||
function gen_reader_endpoint_mem_frame_a (ref : ENDPOINT_DATA_TYPE) return TEST_READER_ENDPOINT_MEMORY_FRAME_TYPE_A;
|
||||
-- Generate a rtps_reader memory Participant Frame based on "ref". (B Version)
|
||||
function gen_reader_endpoint_mem_frame_b (ref : ENDPOINT_DATA_TYPE) return TEST_READER_ENDPOINT_MEMORY_FRAME_TYPE_B;
|
||||
|
||||
|
||||
-- *RTPS WRITER*
|
||||
-- Generate a rtps_writer memory Participant Frame based on "ref". (A Version)
|
||||
function gen_writer_endpoint_mem_frame_a (ref : ENDPOINT_DATA_TYPE) return TEST_WRITER_ENDPOINT_MEMORY_FRAME_TYPE_A;
|
||||
-- Generate a rtps_writer memory Participant Frame based on "ref". (B Version)
|
||||
function gen_writer_endpoint_mem_frame_b (ref : ENDPOINT_DATA_TYPE) return TEST_WRITER_ENDPOINT_MEMORY_FRAME_TYPE_B;
|
||||
|
||||
|
||||
-- *RTPS_HANDLER*
|
||||
@ -478,14 +489,6 @@ package rtps_test_package is
|
||||
-- *RTPS_BUILTIN_ENDPOINT*
|
||||
-- Generate a rtps_builtin_endpoint memory Participant Frame based on "ref".
|
||||
function gen_participant_mem_frame (ref : PARTICIPANT_DATA_TYPE) return TEST_PARTICIPANT_MEMORY_FRAME_TYPE;
|
||||
-- Generate a rtps_writer memory Participant Frame based on "ref". (A Version)
|
||||
function gen_writer_endpoint_mem_frame_a (ref : ENDPOINT_DATA_TYPE) return TEST_WRITER_ENDPOINT_MEMORY_FRAME_TYPE_A;
|
||||
-- Generate a rtps_writer memory Participant Frame based on "ref". (B Version)
|
||||
function gen_writer_endpoint_mem_frame_b (ref : ENDPOINT_DATA_TYPE) return TEST_WRITER_ENDPOINT_MEMORY_FRAME_TYPE_B;
|
||||
-- Generate a rtps_reader memory Participant Frame based on "ref". (A Version)
|
||||
function gen_reader_endpoint_mem_frame_a (ref : ENDPOINT_DATA_TYPE) return TEST_READER_ENDPOINT_MEMORY_FRAME_TYPE_A;
|
||||
-- Generate a rtps_reader memory Participant Frame based on "ref". (B Version)
|
||||
function gen_reader_endpoint_mem_frame_b (ref : ENDPOINT_DATA_TYPE) return TEST_READER_ENDPOINT_MEMORY_FRAME_TYPE_B;
|
||||
-- Writes a rtps_builtin_endpoint Endpoint Match Frame based on "ref" to "output"
|
||||
procedure gen_endpoint_match_frame( ref : in ENDPOINT_DATA_TYPE; output : inout TEST_PACKET_TYPE);
|
||||
-- Writes a rtps_builtin_endpoint Participant Match Frame based on "ref" to "output"
|
||||
@ -1793,68 +1796,29 @@ package body rtps_test_package is
|
||||
ret(i).addr := start + i;
|
||||
case (i) is
|
||||
-- GUID Prefix 1/3
|
||||
when 0 =>
|
||||
if (ref.match = MATCH) then
|
||||
ret(i).data := ref.guidPrefix(0);
|
||||
else
|
||||
ret(i).data := (others => '0');
|
||||
end if;
|
||||
-- GUID Prefix 2/3
|
||||
when 1 =>
|
||||
if (ref.match = MATCH) then
|
||||
ret(i).data := ref.guidPrefix(1);
|
||||
else
|
||||
ret(i).data := (others => '0');
|
||||
end if;
|
||||
-- GUID Prefix 3/3
|
||||
ret(i).data := ref.guidPrefix(0);
|
||||
-- GUID Prefix 2/3
|
||||
when 2 =>
|
||||
if (ref.match = MATCH) then
|
||||
ret(i).data := ref.guidPrefix(2);
|
||||
else
|
||||
ret(i).data := (others => '0');
|
||||
end if;
|
||||
-- METATRAFFIC IPv4 Address
|
||||
ret(i).data := ref.guidPrefix(1);
|
||||
-- GUID Prefix 3/3
|
||||
when 3 =>
|
||||
if (ref.match = MATCH) then
|
||||
ret(i).data := meta_loc.addr(IPv4_ADDRESS_WIDTH-1 downto 0);
|
||||
else
|
||||
ret(i).data := (others => '-');
|
||||
end if;
|
||||
-- DEFAULT IPv4 Address
|
||||
ret(i).data := ref.guidPrefix(2);
|
||||
-- METATRAFFIC IPv4 Address
|
||||
when 4 =>
|
||||
if (ref.match = MATCH) then
|
||||
ret(i).data := user_loc.addr(IPv4_ADDRESS_WIDTH-1 downto 0);
|
||||
else
|
||||
ret(i).data := (others => '-');
|
||||
end if;
|
||||
-- METATRAFFIC & DEFAULT UDP Port
|
||||
ret(i).data := meta_loc.addr(IPv4_ADDRESS_WIDTH-1 downto 0);
|
||||
-- DEFAULT IPv4 Address
|
||||
when 5 =>
|
||||
if (ref.match = MATCH) then
|
||||
ret(i).data := user_loc.addr(IPv4_ADDRESS_WIDTH-1 downto 0);
|
||||
-- METATRAFFIC & DEFAULT UDP Port
|
||||
when 6 =>
|
||||
ret(i).data := meta_loc.portn(UDP_PORT_WIDTH-1 downto 0) & user_loc.portn(UDP_PORT_WIDTH-1 downto 0);
|
||||
else
|
||||
ret(i).data := (others => '-');
|
||||
end if;
|
||||
-- Lease Duration 1/2
|
||||
when 8 =>
|
||||
if (ref.match = MATCH) then
|
||||
ret(i).data := std_logic_vector(ref.leaseDuration(0));
|
||||
else
|
||||
ret(i).data := (others => '-');
|
||||
end if;
|
||||
-- Lease Duration 2/2
|
||||
when 9 =>
|
||||
if (ref.match = MATCH) then
|
||||
ret(i).data := std_logic_vector(ref.leaseDuration(0));
|
||||
-- Lease Duration 2/2
|
||||
when 10 =>
|
||||
ret(i).data := std_logic_vector(ref.leaseDuration(1));
|
||||
else
|
||||
ret(i).data := (others => '-');
|
||||
end if;
|
||||
-- EXTRA FLAGS
|
||||
when 12 =>
|
||||
if (ref.match = MATCH) then
|
||||
ret(i).data := (0 => ref.expectsInlineQoS(0), others => '-');
|
||||
else
|
||||
ret(i).data := (others => '-');
|
||||
end if;
|
||||
-- Other Fields Ignored
|
||||
when others =>
|
||||
ret(i).data := (others => '-');
|
||||
|
||||
Loading…
Reference in New Issue
Block a user