wiliot-certificate 1.5.3a1__py3-none-any.whl → 4.4.0a1__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- brg_certificate/certificate_test_list.txt +2 -2
- brg_certificate/tests/calibration/interval_test/interval_test.py +6 -5
- brg_certificate/tests/calibration/output_power_test/output_power_test.py +6 -5
- brg_certificate/tests/calibration/pattern_test/pattern_test.py +18 -8
- brg_certificate/tests/datapath/aging_test/aging_test.py +10 -8
- brg_certificate/tests/datapath/num_of_tags_test/num_of_tags_test.py +10 -12
- brg_certificate/tests/datapath/output_power_test/output_power_test.py +6 -4
- brg_certificate/tests/datapath/pacer_interval_ble5_test/pacer_interval_ble5_test.py +12 -7
- brg_certificate/tests/datapath/pacer_interval_tags_count_test/pacer_interval_tags_count_test.py +10 -3
- brg_certificate/tests/datapath/pacer_interval_test/pacer_interval_test.py +11 -9
- brg_certificate/tests/datapath/pattern_test/pattern_test.py +6 -5
- brg_certificate/tests/datapath/pkt_filter_ble5_test/pkt_filter_ble5_test.py +12 -9
- brg_certificate/tests/datapath/pkt_filter_gen3_test/pkt_filter_gen3_test.py +12 -9
- brg_certificate/tests/datapath/pkt_filter_test/pkt_filter_test.py +12 -10
- brg_certificate/tests/datapath/rssi_threshold_test/rssi_threshold_test.py +12 -10
- brg_certificate/tests/datapath/rx_channel_test/rx_channel_test.py +6 -6
- brg_certificate/tests/datapath/rx_rate_gen2_test/rx_rate_gen2_test.py +33 -34
- brg_certificate/tests/datapath/rx_rate_gen3_test/rx_rate_gen3_test.py +40 -43
- brg_certificate/tests/datapath/stress_gen3_test/stress_gen3_test.json +1 -2
- brg_certificate/tests/datapath/stress_gen3_test/stress_gen3_test.py +6 -8
- brg_certificate/tests/datapath/stress_test/stress_test.json +1 -2
- brg_certificate/tests/datapath/stress_test/stress_test.py +7 -9
- brg_certificate/tests/datapath/tx_repetition_test/tx_repetition_test.py +13 -10
- brg_certificate/tests/edge_mgmt/actions_test/actions_test.py +6 -4
- brg_certificate/tests/energy2400/duty_cycle_test/duty_cycle_test.py +6 -4
- brg_certificate/tests/energy2400/output_power_test/output_power_test.py +6 -4
- brg_certificate/tests/energy2400/pattern_test/pattern_test.py +6 -4
- brg_certificate/tests/energy2400/signal_indicator_test/signal_indicator_test.py +6 -4
- brg_certificate/tests/energy_sub1g/duty_cycle_test/duty_cycle_test.py +6 -5
- brg_certificate/tests/energy_sub1g/pattern_test/pattern_test.py +6 -4
- brg_certificate/tests/energy_sub1g/signal_indicator_test/signal_indicator_test.py +6 -5
- brg_certificate/tests/sensors/ext_sensor_test/ext_sensor_test.py +6 -5
- gw_certificate/common/wltPb_pb2.py +4 -4
- gw_certificate/common/wltPb_pb2.pyi +2 -1
- gw_certificate/interface/{4.4.82_app.zip → 4.4.88_app.zip} +0 -0
- gw_certificate/interface/{4.4.82_sd_bl_app.zip → 4.4.88_sd_bl_app.zip} +0 -0
- gw_certificate/interface/ble_simulator.py +5 -3
- gw_certificate/interface/uart_if.py +6 -4
- gw_certificate/tests/actions.py +1 -1
- gw_certificate/tests/static/generated_packet_table.py +16 -16
- gw_certificate/tests/static/packet_table.csv +10052 -10052
- gw_certificate/tests/throughput.py +2 -1
- {wiliot_certificate-1.5.3a1.dist-info → wiliot_certificate-4.4.0a1.dist-info}/METADATA +1 -1
- {wiliot_certificate-1.5.3a1.dist-info → wiliot_certificate-4.4.0a1.dist-info}/RECORD +48 -48
- {wiliot_certificate-1.5.3a1.dist-info → wiliot_certificate-4.4.0a1.dist-info}/WHEEL +0 -0
- {wiliot_certificate-1.5.3a1.dist-info → wiliot_certificate-4.4.0a1.dist-info}/entry_points.txt +0 -0
- {wiliot_certificate-1.5.3a1.dist-info → wiliot_certificate-4.4.0a1.dist-info}/licenses/LICENSE +0 -0
- {wiliot_certificate-1.5.3a1.dist-info → wiliot_certificate-4.4.0a1.dist-info}/top_level.txt +0 -0
|
@@ -36,8 +36,8 @@ datapath/rx_channel_test RX_CHANNEL_37 RX_CHANNEL_38 RX_CHANNEL_39 RX_CHANNEL_10
|
|
|
36
36
|
datapath/rx_rate_gen2_test mid_values diff_pacer min_value max_value diff_rate
|
|
37
37
|
datapath/rx_rate_gen3_test mid_values diff_pacer min_value max_value diff_rate
|
|
38
38
|
datapath/pacer_interval_tags_count_test 1 10 15 30
|
|
39
|
-
datapath/stress_test rep3 rep2 rep1
|
|
40
|
-
datapath/stress_gen3_test rep3 rep2 rep1
|
|
39
|
+
datapath/stress_test rep3 rep2 rep1
|
|
40
|
+
datapath/stress_gen3_test rep3 rep2 rep1
|
|
41
41
|
datapath/aging_test low_pacer high_pacer
|
|
42
42
|
datapath/num_of_tags_test 5000
|
|
43
43
|
|
|
@@ -20,9 +20,10 @@ def run(test):
|
|
|
20
20
|
field_functionality_pass_fail_print(test, fields[0], value=param.name)
|
|
21
21
|
test.set_phase_rc(param.name, test.rc)
|
|
22
22
|
test.add_phase_reason(param.name, test.reason)
|
|
23
|
-
if test.rc == TEST_FAILED
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
23
|
+
if test.rc == TEST_FAILED:
|
|
24
|
+
if test.exit_on_param_failure:
|
|
25
|
+
break # break the whole for loop and keep the test as failed
|
|
26
|
+
else:
|
|
27
|
+
test.reset_result() # reset result and continue to next param
|
|
28
|
+
continue
|
|
28
29
|
return cert_common.test_epilog(test, revert_brgs=True, modules=[calib_module])
|
|
@@ -20,9 +20,10 @@ def run(test):
|
|
|
20
20
|
field_functionality_pass_fail_print(test, fields[0], value=param.name)
|
|
21
21
|
test.set_phase_rc(param.name, test.rc)
|
|
22
22
|
test.add_phase_reason(param.name, test.reason)
|
|
23
|
-
if test.rc == TEST_FAILED
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
23
|
+
if test.rc == TEST_FAILED:
|
|
24
|
+
if test.exit_on_param_failure:
|
|
25
|
+
break # break the whole for loop and keep the test as failed
|
|
26
|
+
else:
|
|
27
|
+
test.reset_result() # reset result and continue to next param
|
|
28
|
+
continue
|
|
28
29
|
return cert_common.test_epilog(test, revert_brgs=True, modules=[calib_module])
|
|
@@ -25,6 +25,12 @@ def run(test):
|
|
|
25
25
|
# Configure the BRG, wait=False
|
|
26
26
|
test = cert_config.brg_configure(test, fields=[BRG_PATTERN, BRG_CALIB_INTERVAL],
|
|
27
27
|
values=[param.value, 1], module=calib_module, wait=False)[0]
|
|
28
|
+
if test.rc == TEST_FAILED:
|
|
29
|
+
if test.exit_on_param_failure:
|
|
30
|
+
break # break the whole for loop and keep the test as failed
|
|
31
|
+
else:
|
|
32
|
+
test.reset_result() # reset result and continue to next param
|
|
33
|
+
continue
|
|
28
34
|
cert_common.wait_time_n_print(CLEAR_DATA_PATH_TIMEOUT)
|
|
29
35
|
# MQTT scan
|
|
30
36
|
if test.data == DATA_SIMULATION:
|
|
@@ -51,19 +57,23 @@ def run(test):
|
|
|
51
57
|
field_functionality_pass_fail_print(test, fields[0], value=param.name)
|
|
52
58
|
test.set_phase_rc(param.name, test.rc)
|
|
53
59
|
test.add_phase_reason(param.name, test.reason)
|
|
54
|
-
if test.rc == TEST_FAILED
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
60
|
+
if test.rc == TEST_FAILED:
|
|
61
|
+
if test.exit_on_param_failure:
|
|
62
|
+
break # break the whole for loop and keep the test as failed
|
|
63
|
+
else:
|
|
64
|
+
test.reset_result() # reset result and continue to next param
|
|
65
|
+
continue
|
|
58
66
|
else:
|
|
59
67
|
test = cert_config.brg_configure(test, fields=fields, values=[param.value], module=calib_module)[0]
|
|
60
68
|
generate_log_file(test, param.name)
|
|
61
69
|
field_functionality_pass_fail_print(test, fields[0], value=param.name)
|
|
62
70
|
test.set_phase_rc(param.name, test.rc)
|
|
63
71
|
test.add_phase_reason(param.name, test.reason)
|
|
64
|
-
if test.rc == TEST_FAILED
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
72
|
+
if test.rc == TEST_FAILED:
|
|
73
|
+
if test.exit_on_param_failure:
|
|
74
|
+
break # break the whole for loop and keep the test as failed
|
|
75
|
+
else:
|
|
76
|
+
test.reset_result() # reset result and continue to next param
|
|
77
|
+
continue
|
|
68
78
|
|
|
69
79
|
return cert_common.test_epilog(test, revert_brgs=True, modules=[calib_module, datapath_module])
|
|
@@ -31,7 +31,7 @@ def combination_func(test, datapath_module, pacer_interval, num_of_sim_tags, agi
|
|
|
31
31
|
if test.rc == TEST_FAILED and test.reason != TEST_PASSED:
|
|
32
32
|
for i in range(2):
|
|
33
33
|
if test.rc == TEST_PASSED:
|
|
34
|
-
|
|
34
|
+
break # exist the loop and continue, if succeeded
|
|
35
35
|
test = cert_config.brg_configure(test, fields=[BRG_PACER_INTERVAL], values=[pacer_interval], module=datapath_module)[0]
|
|
36
36
|
test = test.add_reason("Didn't succeed to configure after two attempts - No pkt was found!")
|
|
37
37
|
return test
|
|
@@ -123,20 +123,22 @@ def run(test):
|
|
|
123
123
|
if test.rc == TEST_FAILED:
|
|
124
124
|
return cert_common.test_epilog(test)
|
|
125
125
|
|
|
126
|
-
|
|
126
|
+
AGING_TEST_MAP = {"low_pacer": low_pacer, "high_pacer": high_pacer}
|
|
127
127
|
num_of_pixels = 500
|
|
128
128
|
|
|
129
129
|
for param in test.params:
|
|
130
130
|
functionality_run_print(param.name)
|
|
131
|
-
test =
|
|
131
|
+
test = AGING_TEST_MAP[param.value](test, datapath_module, num_of_pixels)
|
|
132
132
|
generate_log_file(test, param.name)
|
|
133
133
|
field_functionality_pass_fail_print(test, param.name)
|
|
134
134
|
test.set_phase_rc(param.name, test.rc)
|
|
135
135
|
test.add_phase_reason(param.name, test.reason)
|
|
136
|
-
if test.rc == TEST_FAILED
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
136
|
+
if test.rc == TEST_FAILED:
|
|
137
|
+
if test.exit_on_param_failure:
|
|
138
|
+
break
|
|
139
|
+
else:
|
|
140
|
+
test.reset_result()
|
|
141
|
+
continue
|
|
140
142
|
time.sleep(5)
|
|
141
143
|
|
|
142
|
-
return cert_common.test_epilog(test, revert_brgs=True,
|
|
144
|
+
return cert_common.test_epilog(test, revert_brgs=True, modules=[datapath_module])
|
|
@@ -60,25 +60,23 @@ def run(test):
|
|
|
60
60
|
|
|
61
61
|
# compare the numbers of tags that come from the brg, success in 95% from number of tags (value) or more.
|
|
62
62
|
if num_of_tags < (param.value * 0.95):
|
|
63
|
-
test.
|
|
64
|
-
test.add_reason(f"
|
|
65
|
-
test.add_reason(f"Note - HB was {num_of_tags_HB}")
|
|
63
|
+
test.add_reason(f"Found {num_of_tags} pixels expected: {param.name} pixels!")
|
|
64
|
+
test.add_reason(f"HB: {num_of_tags_HB}, Df: {num_of_tags}")
|
|
66
65
|
|
|
67
66
|
# compare the counter tags in the HB packet
|
|
68
|
-
if num_of_tags_HB < param.value or num_of_tags_HB > (param.value + 100):
|
|
69
|
-
test.
|
|
70
|
-
test.add_reason(f"
|
|
71
|
-
test.add_reason(f"Note - tag counter field = {num_of_tags}")
|
|
72
|
-
|
|
67
|
+
if num_of_tags_HB < 0.95 * param.value or num_of_tags_HB > (param.value + 100):
|
|
68
|
+
test.add_reason(f"Found {num_of_tags_HB} pixels expected: {param.name} pixels!")
|
|
69
|
+
test.add_reason(f"HB: {num_of_tags_HB}, Df: {num_of_tags}")
|
|
73
70
|
# param epilog
|
|
74
71
|
time.sleep(10)
|
|
75
72
|
generate_log_file(test, param.name)
|
|
76
73
|
field_functionality_pass_fail_print(test, "num_of_tags", value=param.name)
|
|
77
74
|
test.set_phase_rc(param.name, test.rc)
|
|
78
75
|
test.add_phase_reason(param.name, test.reason)
|
|
79
|
-
if test.rc == TEST_FAILED
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
76
|
+
if test.rc == TEST_FAILED:
|
|
77
|
+
if test.exit_on_param_failure:
|
|
78
|
+
break
|
|
79
|
+
else:
|
|
80
|
+
test.reset_result()
|
|
83
81
|
|
|
84
82
|
return cert_common.test_epilog(test)
|
|
@@ -20,9 +20,11 @@ def run(test):
|
|
|
20
20
|
field_functionality_pass_fail_print(test, fields[0], value=param.name)
|
|
21
21
|
test.set_phase_rc(param.name, test.rc)
|
|
22
22
|
test.add_phase_reason(param.name, test.reason)
|
|
23
|
-
if test.rc == TEST_FAILED
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
23
|
+
if test.rc == TEST_FAILED:
|
|
24
|
+
if test.exit_on_param_failure:
|
|
25
|
+
break # break the whole for loop and keep the test as failed
|
|
26
|
+
else:
|
|
27
|
+
test.reset_result() # reset result and continue to next param
|
|
28
|
+
continue
|
|
27
29
|
|
|
28
30
|
return cert_common.test_epilog(test, revert_brgs=True, modules=[datapath_module])
|
|
@@ -17,8 +17,12 @@ def run(test):
|
|
|
17
17
|
for param in test.params:
|
|
18
18
|
test = cert_config.brg_configure_ble5(test, fields=fields, values=[param.value, ag.RX_CHANNEL_10_250K, ag.PKT_FILTER_TEMP_PKT],
|
|
19
19
|
module=datapath_module)[0]
|
|
20
|
-
if test.rc == TEST_FAILED
|
|
21
|
-
|
|
20
|
+
if test.rc == TEST_FAILED:
|
|
21
|
+
if test.exit_on_param_failure:
|
|
22
|
+
break # break the whole for loop and keep the test as failed
|
|
23
|
+
else:
|
|
24
|
+
test.reset_result() # reset result and continue to next param
|
|
25
|
+
continue
|
|
22
26
|
num_of_pixels = 0
|
|
23
27
|
if test.data == DATA_SIMULATION:
|
|
24
28
|
# start generating pkts and send them using data simulator
|
|
@@ -38,9 +42,10 @@ def run(test):
|
|
|
38
42
|
field_functionality_pass_fail_print(test, fields[0], value=param.name)
|
|
39
43
|
test.set_phase_rc(param.name, test.rc)
|
|
40
44
|
test.add_phase_reason(param.name, test.reason)
|
|
41
|
-
if test.rc == TEST_FAILED
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
45
|
+
if test.rc == TEST_FAILED:
|
|
46
|
+
if test.exit_on_param_failure:
|
|
47
|
+
break # break the whole for loop and keep the test as failed
|
|
48
|
+
else:
|
|
49
|
+
test.reset_result() # reset result and continue to next param
|
|
50
|
+
continue
|
|
46
51
|
return cert_common.test_epilog(test, revert_brgs=True, revert_gws=test.internal_brg, modules=[datapath_module], ble5=True)
|
brg_certificate/tests/datapath/pacer_interval_tags_count_test/pacer_interval_tags_count_test.py
CHANGED
|
@@ -30,9 +30,12 @@ def run(test):
|
|
|
30
30
|
tags_count_per_pacer = {}
|
|
31
31
|
for param in test.params:
|
|
32
32
|
test = cert_config.brg_configure(test, fields=fields, values=[param.value, 1], module=datapath_module)[0]
|
|
33
|
-
if test.rc == TEST_FAILED
|
|
34
|
-
|
|
35
|
-
|
|
33
|
+
if test.rc == TEST_FAILED:
|
|
34
|
+
if test.exit_on_param_failure:
|
|
35
|
+
break # break the whole for loop and keep the test as failed
|
|
36
|
+
else:
|
|
37
|
+
test.reset_result() # reset result and continue to next param
|
|
38
|
+
continue
|
|
36
39
|
df = cert_common.data_scan(test, scan_time=120, brg_data=True)
|
|
37
40
|
cert_common.display_data(df, nfpkt=True, tbc=True, name_prefix=f"brg_pacer_tags_count_{param.name}_", dir=test.dir)
|
|
38
41
|
tags_count_per_pacer[param.value] = df[TAG_ID].nunique()
|
|
@@ -52,6 +55,10 @@ def run(test):
|
|
|
52
55
|
print("tags_count_per_pacer: ", tags_count_per_pacer)
|
|
53
56
|
max_count = max([tags_count_per_pacer[pacer] for pacer in tags_count_per_pacer])
|
|
54
57
|
for param in test.params:
|
|
58
|
+
if param.value not in tags_count_per_pacer:
|
|
59
|
+
test.set_phase_rc(param.name, TEST_FAILED)
|
|
60
|
+
test.add_phase_reason(param.name, f"param value {param.value} not found in tags_count_per_pacer")
|
|
61
|
+
continue # Skip this param because the scan wasn't performed
|
|
55
62
|
if test.data == DATA_SIMULATION:
|
|
56
63
|
if tags_count_per_pacer[param.value] < num_of_pixels * 0.99 or tags_count_per_pacer[param.value] > num_of_pixels * 1.01:
|
|
57
64
|
test.set_phase_rc(param.name, TEST_FAILED)
|
|
@@ -19,10 +19,12 @@ def run(test):
|
|
|
19
19
|
module=datapath_module)[0]
|
|
20
20
|
test.set_phase_rc(param.name, test.rc)
|
|
21
21
|
test.add_phase_reason(param.name, test.reason)
|
|
22
|
-
if test.rc == TEST_FAILED
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
22
|
+
if test.rc == TEST_FAILED:
|
|
23
|
+
if test.exit_on_param_failure:
|
|
24
|
+
break # break the whole for loop and keep the test as failed
|
|
25
|
+
else:
|
|
26
|
+
test.reset_result() # reset result and continue to next param
|
|
27
|
+
continue
|
|
26
28
|
|
|
27
29
|
num_of_pixels = 0
|
|
28
30
|
if test.data == DATA_SIMULATION:
|
|
@@ -42,11 +44,11 @@ def run(test):
|
|
|
42
44
|
field_functionality_pass_fail_print(test, fields[0], value=param.name)
|
|
43
45
|
test.set_phase_rc(param.name, test.rc)
|
|
44
46
|
test.add_phase_reason(param.name, test.reason)
|
|
45
|
-
if test.rc == TEST_FAILED and test.exit_on_param_failure:
|
|
46
|
-
break
|
|
47
|
-
else:
|
|
48
|
-
test.reset_result()
|
|
49
47
|
if test.rc == TEST_FAILED:
|
|
50
|
-
|
|
48
|
+
if test.exit_on_param_failure:
|
|
49
|
+
break # break the whole for loop and keep the test as failed
|
|
50
|
+
else:
|
|
51
|
+
test.reset_result() # reset result and continue to next param
|
|
52
|
+
continue
|
|
51
53
|
|
|
52
54
|
return cert_common.test_epilog(test, revert_brgs=True, revert_gws=test.internal_brg, modules=[datapath_module])
|
|
@@ -21,9 +21,10 @@ def run(test):
|
|
|
21
21
|
field_functionality_pass_fail_print(test, fields[0], value=param.name)
|
|
22
22
|
test.set_phase_rc(param.name, test.rc)
|
|
23
23
|
test.add_phase_reason(param.name, test.reason)
|
|
24
|
-
if test.rc == TEST_FAILED
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
24
|
+
if test.rc == TEST_FAILED:
|
|
25
|
+
if test.exit_on_param_failure:
|
|
26
|
+
break # break the whole for loop and keep the test as failed
|
|
27
|
+
else:
|
|
28
|
+
test.reset_result() # reset result and continue to next param
|
|
29
|
+
continue
|
|
29
30
|
return cert_common.test_epilog(test, revert_brgs=True, modules=[datapath_module])
|
|
@@ -22,11 +22,12 @@ def run(test):
|
|
|
22
22
|
module=datapath_module)[0]
|
|
23
23
|
test.set_phase_rc(param.name, test.rc)
|
|
24
24
|
test.add_phase_reason(param.name, test.reason)
|
|
25
|
-
if test.rc == TEST_FAILED
|
|
26
|
-
test.
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
25
|
+
if test.rc == TEST_FAILED:
|
|
26
|
+
if test.exit_on_param_failure:
|
|
27
|
+
break # break the whole for loop and keep the test as failed
|
|
28
|
+
else:
|
|
29
|
+
test.reset_result() # reset result and continue to next param
|
|
30
|
+
continue
|
|
30
31
|
print("waiting 5 seconds for datapath to clear")
|
|
31
32
|
print_update_wait(5)
|
|
32
33
|
num_of_pixels = 0
|
|
@@ -50,9 +51,11 @@ def run(test):
|
|
|
50
51
|
field_functionality_pass_fail_print(test, fields[0], value=param.name)
|
|
51
52
|
test.set_phase_rc(param.name, test.rc)
|
|
52
53
|
test.add_phase_reason(param.name, test.reason)
|
|
53
|
-
if test.rc == TEST_FAILED
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
54
|
+
if test.rc == TEST_FAILED:
|
|
55
|
+
if test.exit_on_param_failure:
|
|
56
|
+
break # break the whole for loop and keep the test as failed
|
|
57
|
+
else:
|
|
58
|
+
test.reset_result() # reset result and continue to next param
|
|
59
|
+
continue
|
|
57
60
|
|
|
58
61
|
return cert_common.test_epilog(test, revert_brgs=True, revert_gws=test.internal_brg, modules=[datapath_module], ble5=True)
|
|
@@ -22,11 +22,12 @@ def run(test):
|
|
|
22
22
|
module=datapath_module)[0]
|
|
23
23
|
test.set_phase_rc(param.name, test.rc)
|
|
24
24
|
test.add_phase_reason(param.name, test.reason)
|
|
25
|
-
if test.rc == TEST_FAILED
|
|
26
|
-
test.
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
25
|
+
if test.rc == TEST_FAILED:
|
|
26
|
+
if test.exit_on_param_failure:
|
|
27
|
+
break # break the whole for loop and keep the test as failed
|
|
28
|
+
else:
|
|
29
|
+
test.reset_result() # reset result and continue to next param
|
|
30
|
+
continue
|
|
30
31
|
print("waiting 5 seconds for datapath to clear")
|
|
31
32
|
print_update_wait(5)
|
|
32
33
|
|
|
@@ -51,9 +52,11 @@ def run(test):
|
|
|
51
52
|
field_functionality_pass_fail_print(test, fields[0], value=param.name)
|
|
52
53
|
test.set_phase_rc(param.name, test.rc)
|
|
53
54
|
test.add_phase_reason(param.name, test.reason)
|
|
54
|
-
if test.rc == TEST_FAILED
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
55
|
+
if test.rc == TEST_FAILED:
|
|
56
|
+
if test.exit_on_param_failure:
|
|
57
|
+
break # break the whole for loop and keep the test as failed
|
|
58
|
+
else:
|
|
59
|
+
test.reset_result() # reset result and continue to next param
|
|
60
|
+
continue
|
|
58
61
|
|
|
59
62
|
return cert_common.test_epilog(test, revert_brgs=True, revert_gws=test.internal_brg, modules=[datapath_module])
|
|
@@ -22,11 +22,12 @@ def run(test):
|
|
|
22
22
|
module=datapath_module)[0]
|
|
23
23
|
test.set_phase_rc(param.name, test.rc)
|
|
24
24
|
test.add_phase_reason(param.name, test.reason)
|
|
25
|
-
if test.rc == TEST_FAILED
|
|
26
|
-
test.
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
25
|
+
if test.rc == TEST_FAILED:
|
|
26
|
+
if test.exit_on_param_failure:
|
|
27
|
+
break # break the whole for loop and keep the test as failed
|
|
28
|
+
else:
|
|
29
|
+
test.reset_result() # reset result and continue to next param
|
|
30
|
+
continue
|
|
30
31
|
print("waiting 5 seconds for datapath to clear")
|
|
31
32
|
print_update_wait(5)
|
|
32
33
|
|
|
@@ -51,9 +52,10 @@ def run(test):
|
|
|
51
52
|
field_functionality_pass_fail_print(test, fields[0], value=param.name)
|
|
52
53
|
test.set_phase_rc(param.name, test.rc)
|
|
53
54
|
test.add_phase_reason(param.name, test.reason)
|
|
54
|
-
if test.rc == TEST_FAILED
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
55
|
+
if test.rc == TEST_FAILED:
|
|
56
|
+
if test.exit_on_param_failure:
|
|
57
|
+
break # break the whole for loop and keep the test as failed
|
|
58
|
+
else:
|
|
59
|
+
test.reset_result() # reset result and continue to next param
|
|
60
|
+
continue
|
|
59
61
|
return cert_common.test_epilog(test, revert_brgs=True, revert_gws=test.internal_brg, modules=[datapath_module])
|
|
@@ -39,14 +39,15 @@ def run(test):
|
|
|
39
39
|
# Configure the BRG with RSSI threshold and check for packets violating the threshold
|
|
40
40
|
for param in test.params:
|
|
41
41
|
functionality_run_print(f"test for RSSI threshold of {param.value}")
|
|
42
|
-
|
|
43
42
|
test = cert_config.brg_configure(test, fields=fields, values=[param.value], module=datapath_module)[0]
|
|
44
43
|
test.set_phase_rc(param.name, test.rc)
|
|
45
44
|
test.add_phase_reason(param.name, test.reason)
|
|
46
|
-
if test.rc == TEST_FAILED
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
45
|
+
if test.rc == TEST_FAILED:
|
|
46
|
+
if test.exit_on_param_failure:
|
|
47
|
+
break # break the whole for loop and keep the test as failed
|
|
48
|
+
else:
|
|
49
|
+
test.reset_result() # reset result and continue to next param
|
|
50
|
+
continue
|
|
50
51
|
print("waiting 5 seconds for datapath to clear")
|
|
51
52
|
print_update_wait(5)
|
|
52
53
|
|
|
@@ -67,9 +68,10 @@ def run(test):
|
|
|
67
68
|
field_functionality_pass_fail_print(test, fields[0], value=param.name)
|
|
68
69
|
test.set_phase_rc(param.name, test.rc)
|
|
69
70
|
test.add_phase_reason(param.name, test.reason)
|
|
70
|
-
if test.rc == TEST_FAILED
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
71
|
+
if test.rc == TEST_FAILED:
|
|
72
|
+
if test.exit_on_param_failure:
|
|
73
|
+
break # break the whole for loop and keep the test as failed
|
|
74
|
+
else:
|
|
75
|
+
test.reset_result() # reset result and continue to next param
|
|
76
|
+
continue
|
|
75
77
|
return cert_common.test_epilog(test, revert_brgs=True, revert_gws=test.internal_brg, modules=[datapath_module])
|
|
@@ -30,16 +30,16 @@ def run(test):
|
|
|
30
30
|
test = cert_config.brg_configure_ble5(test, fields=fields, values=[param.value], module=datapath_module)[0]
|
|
31
31
|
else:
|
|
32
32
|
test = cert_config.brg_configure(test, fields=fields, values=[param.value], module=datapath_module)[0]
|
|
33
|
-
|
|
34
33
|
# param epilog
|
|
35
34
|
ble5_state = not is_primary_channel(param.value)
|
|
36
35
|
generate_log_file(test, param.name)
|
|
37
36
|
field_functionality_pass_fail_print(test, fields[0], value=param.name)
|
|
38
37
|
test.set_phase_rc(param.name, test.rc)
|
|
39
38
|
test.add_phase_reason(param.name, test.reason)
|
|
40
|
-
if test.rc == TEST_FAILED
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
39
|
+
if test.rc == TEST_FAILED:
|
|
40
|
+
if test.exit_on_param_failure:
|
|
41
|
+
break # break the whole for loop and keep the test as failed
|
|
42
|
+
else:
|
|
43
|
+
test.reset_result() # reset result and continue to next param
|
|
44
|
+
continue
|
|
45
45
|
return cert_common.test_epilog(test, revert_brgs=True, modules=[datapath_module], ble5=ble5_state)
|
|
@@ -34,8 +34,8 @@ def scan_and_compare(test, pacer_interval, delay, expected_address_value):
|
|
|
34
34
|
pixel_sim_thread.stop()
|
|
35
35
|
cert_mqtt.dump_pkts(test, log="rx_rate")
|
|
36
36
|
cert_common.display_data(df, tbc=True, nfpkt=True, rssi=True, dir=test.dir)
|
|
37
|
-
|
|
38
|
-
if df
|
|
37
|
+
# check if the dataframe is empty or not
|
|
38
|
+
if len(df) <= 1:
|
|
39
39
|
print("Df is empty")
|
|
40
40
|
test.rc = TEST_FAILED
|
|
41
41
|
test.add_reason("Df is empty")
|
|
@@ -48,11 +48,16 @@ def scan_and_compare(test, pacer_interval, delay, expected_address_value):
|
|
|
48
48
|
print(f"Most common tag: {most_common_tag}")
|
|
49
49
|
df = df[df[TAG_ID] == most_common_tag]
|
|
50
50
|
df = df[[TAG_ID, TBC, PACKET_TYPE, DATETIME]]
|
|
51
|
+
length = len(df)
|
|
52
|
+
mid_index = int(length // 2)
|
|
53
|
+
if mid_index == 0:
|
|
54
|
+
mid_index = 1
|
|
55
|
+
print(f"Length of df: {length}, mid index: {mid_index}")
|
|
51
56
|
print(f"df:\n {df}")
|
|
52
57
|
|
|
53
58
|
tag = df.iloc[0][TAG_ID]
|
|
54
59
|
# iloc [1:] to skip the first value of tbc_values which could be 0 sometimes.
|
|
55
|
-
actual_address_value = round(df.iloc[
|
|
60
|
+
actual_address_value = round(df.iloc[mid_index:][TBC].mean(), 2) # extract the tbc value from df
|
|
56
61
|
print(f"\nactual address value: {actual_address_value}\nexpected address value: {expected_address_value}")
|
|
57
62
|
THRESHOLD_ADDRESS_VALUE = 5
|
|
58
63
|
# check if the actual address value is in the range of -+5 of the expected address value
|
|
@@ -147,8 +152,9 @@ def diff_rate(test, datapath_module):
|
|
|
147
152
|
df = cert_common.data_scan(test, scan_time=scan_time, brg_data=(not test.internal_brg), gw_data=test.internal_brg)
|
|
148
153
|
pixel_sim_thread.stop()
|
|
149
154
|
df = df[[TAG_ID, TBC]]
|
|
155
|
+
lenght = len(df)
|
|
150
156
|
|
|
151
|
-
if df
|
|
157
|
+
if len(df) <= 1:
|
|
152
158
|
test.add_reason("Df is empty")
|
|
153
159
|
test.rc = TEST_FAILED
|
|
154
160
|
return test
|
|
@@ -156,35 +162,27 @@ def diff_rate(test, datapath_module):
|
|
|
156
162
|
print(f"Df:\n {df}")
|
|
157
163
|
# NOTE: all next rows are specific for the values: delay 0.5 and 3, and in relation address values 128 and 235
|
|
158
164
|
# check if the last tbc value is as we expected for delay 3 sec we need to get 235 according to LUT table
|
|
159
|
-
# we define tolerance of +-
|
|
165
|
+
# we define tolerance of +-10 units for address value
|
|
166
|
+
|
|
167
|
+
# Most important check, verify it converges to the correct value
|
|
160
168
|
if df.iloc[-1][TBC] not in range(232, 237):
|
|
161
169
|
test.rc = TEST_FAILED
|
|
162
170
|
test.add_reason(f"TBC value: {df.iloc[-1][TBC]}, expected value [232,236]")
|
|
163
171
|
print(f"TBC value: {df.iloc[-1][TBC]}, expected value [232,236] according to delay:{second_delay / 1000} sec")
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
# check the first change of tbc value after delay changing which is verify the calculation of alpha filter
|
|
178
|
-
second_tbc = df.iloc[index + 1][TBC]
|
|
179
|
-
expected_address_value = 200
|
|
180
|
-
# 4 is equal to 0.09 sec error
|
|
181
|
-
threshold = 4 # 2 equal to 0.04 sec error
|
|
182
|
-
if not expected_address_value - threshold <= second_tbc <= expected_address_value + threshold:
|
|
172
|
+
return test
|
|
173
|
+
# for loop that skip the first row and check if somewhere there is the expected gap 130 to 200
|
|
174
|
+
result = False
|
|
175
|
+
for i in range(0, lenght - 1):
|
|
176
|
+
prev = df.iloc[i][TBC]
|
|
177
|
+
current = df.iloc[i + 1][TBC]
|
|
178
|
+
if prev in range(120, 140) and current in range(190, 210):
|
|
179
|
+
print(f"Found the gap between {prev} and {current}")
|
|
180
|
+
print(f"row {i}: {df.iloc[i][TBC]}")
|
|
181
|
+
print(f"row {i + 1}: {df.iloc[i + 1][TBC]}")
|
|
182
|
+
result = True
|
|
183
|
+
if not result:
|
|
183
184
|
test.rc = TEST_FAILED
|
|
184
|
-
test.add_reason(
|
|
185
|
-
print(f"first change of address value is wrong.\n"
|
|
186
|
-
f"alpha filter probably is not define well\n"
|
|
187
|
-
f"TBC value: {second_tbc}, expected value [196,204]")
|
|
185
|
+
test.add_reason("Didn't find the correct gap according to alpha filter calculation")
|
|
188
186
|
return test
|
|
189
187
|
|
|
190
188
|
|
|
@@ -199,7 +197,7 @@ def run(test):
|
|
|
199
197
|
test = cert_config.brg_configure(test, fields=[BRG_PACER_INTERVAL], values=[pacer_interval], module=datapath_module)[0]
|
|
200
198
|
if test.rc == TEST_FAILED:
|
|
201
199
|
test.add_reason(f"Didn't succeed to config pacer interval {pacer_interval}")
|
|
202
|
-
return test
|
|
200
|
+
return cert_common.test_epilog(test)
|
|
203
201
|
|
|
204
202
|
RX_RATE_TEST_MAP = {"mid_values": mid_values, "diff_pacer": diff_pacer, "min_value": min_value,
|
|
205
203
|
"max_value": max_value, "diff_rate": diff_rate}
|
|
@@ -210,9 +208,10 @@ def run(test):
|
|
|
210
208
|
field_functionality_pass_fail_print(test, param.name)
|
|
211
209
|
test.set_phase_rc(param.name, test.rc)
|
|
212
210
|
test.add_phase_reason(param.name, test.reason)
|
|
213
|
-
if test.rc == TEST_FAILED
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
211
|
+
if test.rc == TEST_FAILED:
|
|
212
|
+
if test.exit_on_param_failure:
|
|
213
|
+
break # break the whole for loop and keep the test as failed
|
|
214
|
+
else:
|
|
215
|
+
test.reset_result() # reset result and continue to next param
|
|
216
|
+
continue
|
|
218
217
|
return cert_common.test_epilog(test)
|