wiliot-certificate 1.5.3a1__py3-none-any.whl → 4.4.0__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/ag/energous_v0_defines.py +105 -114
- brg_certificate/ag/energous_v1_defines.py +105 -114
- brg_certificate/ag/energous_v2_defines.py +105 -114
- brg_certificate/ag/energous_v3_defines.py +105 -114
- brg_certificate/ag/energous_v4_defines.py +105 -114
- brg_certificate/ag/fanstel_lan_v0_defines.py +105 -114
- brg_certificate/ag/fanstel_lte_v0_defines.py +105 -114
- brg_certificate/ag/fanstel_wifi_v0_defines.py +105 -114
- brg_certificate/ag/minew_lte_v0_defines.py +105 -114
- brg_certificate/ag/wlt_types.html +980 -147
- brg_certificate/ag/wlt_types_ag.py +1318 -240
- brg_certificate/ag/wlt_types_ag_jsons/brg2brg_ota.json +69 -0
- brg_certificate/ag/wlt_types_ag_jsons/brg2gw_hb.json +101 -0
- brg_certificate/ag/wlt_types_ag_jsons/brg2gw_hb_sleep.json +45 -0
- brg_certificate/ag/wlt_types_ag_jsons/calibration.json +75 -0
- brg_certificate/ag/wlt_types_ag_jsons/custom.json +99 -0
- brg_certificate/ag/wlt_types_ag_jsons/datapath.json +133 -8
- brg_certificate/ag/wlt_types_ag_jsons/energy2400.json +99 -0
- brg_certificate/ag/wlt_types_ag_jsons/energySub1g.json +96 -0
- brg_certificate/ag/wlt_types_ag_jsons/externalSensor.json +113 -0
- brg_certificate/ag/wlt_types_ag_jsons/interface.json +157 -0
- brg_certificate/ag/wlt_types_ag_jsons/powerManagement.json +205 -0
- brg_certificate/certificate_bcc_test_list.txt +0 -2
- brg_certificate/certificate_test_list.txt +2 -2
- brg_certificate/tests/calibration/interval_test/interval_test.json +1 -1
- brg_certificate/tests/calibration/interval_test/interval_test.py +4 -4
- brg_certificate/tests/calibration/output_power_test/output_power_test.json +1 -1
- brg_certificate/tests/calibration/output_power_test/output_power_test.py +4 -4
- brg_certificate/tests/calibration/pattern_test/pattern_test.json +1 -1
- brg_certificate/tests/calibration/pattern_test/pattern_test.py +14 -8
- brg_certificate/tests/datapath/aging_test/aging_test.py +9 -8
- brg_certificate/tests/datapath/num_of_tags_test/num_of_tags_test.py +7 -12
- brg_certificate/tests/datapath/output_power_test/output_power_test.json +1 -1
- brg_certificate/tests/datapath/output_power_test/output_power_test.py +4 -4
- brg_certificate/tests/datapath/pacer_interval_ble5_test/pacer_interval_ble5_test.json +1 -1
- brg_certificate/tests/datapath/pacer_interval_ble5_test/pacer_interval_ble5_test.py +10 -6
- 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 +9 -9
- brg_certificate/tests/datapath/pattern_test/pattern_test.json +1 -1
- brg_certificate/tests/datapath/pattern_test/pattern_test.py +4 -5
- brg_certificate/tests/datapath/pkt_filter_ble5_test/pkt_filter_ble5_test.json +1 -1
- brg_certificate/tests/datapath/pkt_filter_ble5_test/pkt_filter_ble5_test.py +10 -9
- brg_certificate/tests/datapath/pkt_filter_gen3_test/pkt_filter_gen3_test.json +1 -1
- brg_certificate/tests/datapath/pkt_filter_gen3_test/pkt_filter_gen3_test.py +10 -9
- brg_certificate/tests/datapath/pkt_filter_test/pkt_filter_test.json +1 -1
- brg_certificate/tests/datapath/pkt_filter_test/pkt_filter_test.py +10 -9
- brg_certificate/tests/datapath/rssi_threshold_test/rssi_threshold_test.json +1 -1
- brg_certificate/tests/datapath/rssi_threshold_test/rssi_threshold_test.py +10 -9
- brg_certificate/tests/datapath/rx_channel_test/rx_channel_test.json +1 -1
- brg_certificate/tests/datapath/rx_channel_test/rx_channel_test.py +4 -5
- brg_certificate/tests/datapath/rx_rate_gen2_test/rx_rate_gen2_test.py +38 -36
- brg_certificate/tests/datapath/rx_rate_gen3_test/rx_rate_gen3_test.py +45 -45
- brg_certificate/tests/datapath/stress_gen3_test/stress_gen3_test.json +2 -3
- brg_certificate/tests/datapath/stress_gen3_test/stress_gen3_test.py +20 -16
- brg_certificate/tests/datapath/stress_test/stress_test.json +2 -3
- brg_certificate/tests/datapath/stress_test/stress_test.py +19 -16
- brg_certificate/tests/datapath/tx_repetition_test/tx_repetition_test.json +1 -1
- brg_certificate/tests/datapath/tx_repetition_test/tx_repetition_test.py +11 -9
- brg_certificate/tests/edge_mgmt/actions_test/actions_test.json +1 -1
- brg_certificate/tests/edge_mgmt/actions_test/actions_test.py +4 -4
- brg_certificate/tests/energy2400/duty_cycle_test/duty_cycle_test.json +1 -1
- brg_certificate/tests/energy2400/duty_cycle_test/duty_cycle_test.py +4 -4
- brg_certificate/tests/energy2400/output_power_test/output_power_test.json +1 -1
- brg_certificate/tests/energy2400/output_power_test/output_power_test.py +4 -4
- brg_certificate/tests/energy2400/pattern_test/pattern_test.json +1 -1
- brg_certificate/tests/energy2400/pattern_test/pattern_test.py +4 -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.json +1 -1
- brg_certificate/tests/energy_sub1g/duty_cycle_test/duty_cycle_test.py +4 -4
- brg_certificate/tests/energy_sub1g/pattern_test/pattern_test.json +1 -1
- brg_certificate/tests/energy_sub1g/pattern_test/pattern_test.py +4 -4
- brg_certificate/tests/energy_sub1g/signal_indicator_test/signal_indicator_test.json +1 -1
- brg_certificate/tests/energy_sub1g/signal_indicator_test/signal_indicator_test.py +4 -4
- brg_certificate/tests/sensors/ext_sensor_test/ext_sensor_test.json +1 -1
- brg_certificate/tests/sensors/ext_sensor_test/ext_sensor_test.py +4 -5
- brg_certificate/wltPb_pb2.py +4 -4
- brg_certificate/wltPb_pb2.pyi +2 -1
- gw_certificate/common/serialization_formatter.py +14 -1
- 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.91_app.zip} +0 -0
- gw_certificate/interface/{4.4.82_sd_bl_app.zip → 4.4.91_sd_bl_app.zip} +0 -0
- gw_certificate/interface/ble_simulator.py +5 -3
- gw_certificate/interface/flash_fw.py +90 -0
- gw_certificate/interface/uart_if.py +6 -4
- gw_certificate/tests/actions.py +1 -1
- gw_certificate/tests/downlink.py +2 -2
- gw_certificate/tests/generic.py +4 -3
- gw_certificate/tests/static/generated_packet_table.py +16 -16
- gw_certificate/tests/static/packet_table.csv +10052 -10052
- gw_certificate/tests/static/uplink_defines.py +1 -1
- gw_certificate/tests/throughput.py +3 -2
- gw_certificate/tests/uplink.py +38 -19
- {wiliot_certificate-1.5.3a1.dist-info → wiliot_certificate-4.4.0.dist-info}/METADATA +71 -30
- {wiliot_certificate-1.5.3a1.dist-info → wiliot_certificate-4.4.0.dist-info}/RECORD +99 -98
- {wiliot_certificate-1.5.3a1.dist-info → wiliot_certificate-4.4.0.dist-info}/WHEEL +1 -1
- {wiliot_certificate-1.5.3a1.dist-info → wiliot_certificate-4.4.0.dist-info}/entry_points.txt +0 -0
- {wiliot_certificate-1.5.3a1.dist-info → wiliot_certificate-4.4.0.dist-info}/licenses/LICENSE +0 -0
- {wiliot_certificate-1.5.3a1.dist-info → wiliot_certificate-4.4.0.dist-info}/top_level.txt +0 -0
|
@@ -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
|
|
33
|
+
continue # skip the current phase and continue to next param
|
|
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,19 @@ 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
|
+
test.reset_result() # reset result and continue to next param
|
|
58
64
|
else:
|
|
59
65
|
test = cert_config.brg_configure(test, fields=fields, values=[param.value], module=calib_module)[0]
|
|
60
66
|
generate_log_file(test, param.name)
|
|
61
67
|
field_functionality_pass_fail_print(test, fields[0], value=param.name)
|
|
62
68
|
test.set_phase_rc(param.name, test.rc)
|
|
63
69
|
test.add_phase_reason(param.name, test.reason)
|
|
64
|
-
if test.rc == TEST_FAILED
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
70
|
+
if test.rc == TEST_FAILED:
|
|
71
|
+
if test.exit_on_param_failure:
|
|
72
|
+
break # break the whole for loop and keep the test as failed
|
|
73
|
+
test.reset_result() # reset result and continue to next param
|
|
68
74
|
|
|
69
75
|
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,21 @@ 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 # break the whole for loop and keep the test as failed
|
|
139
|
+
test.reset_result() # reset result and continue to next param
|
|
140
|
+
|
|
140
141
|
time.sleep(5)
|
|
141
142
|
|
|
142
|
-
return cert_common.test_epilog(test, revert_brgs=True,
|
|
143
|
+
return cert_common.test_epilog(test, revert_brgs=True, modules=[datapath_module])
|
|
@@ -60,25 +60,20 @@ 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"Found {num_of_tags} pixels instead of {param.name} pixels!")
|
|
65
|
-
test.add_reason(f"Note - HB was {num_of_tags_HB}")
|
|
63
|
+
test.add_reason(f"Received {num_of_tags} pixels, expected: {param.name} pixels!")
|
|
66
64
|
|
|
67
65
|
# 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"pixels counter in HB packet is {num_of_tags_HB} instead of {param.name} pixels!")
|
|
71
|
-
test.add_reason(f"Note - tag counter field = {num_of_tags}")
|
|
72
|
-
|
|
66
|
+
if num_of_tags_HB < 0.95 * param.value or num_of_tags_HB > (param.value + 100):
|
|
67
|
+
test.add_reason(f"HB counter: {num_of_tags_HB}, expected: {param.name}!")
|
|
73
68
|
# param epilog
|
|
74
69
|
time.sleep(10)
|
|
75
70
|
generate_log_file(test, param.name)
|
|
76
71
|
field_functionality_pass_fail_print(test, "num_of_tags", value=param.name)
|
|
77
72
|
test.set_phase_rc(param.name, test.rc)
|
|
78
73
|
test.add_phase_reason(param.name, test.reason)
|
|
79
|
-
if test.rc == TEST_FAILED
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
74
|
+
if test.rc == TEST_FAILED:
|
|
75
|
+
if test.exit_on_param_failure:
|
|
76
|
+
break # break the whole for loop and keep the test as failed
|
|
77
|
+
test.reset_result() # reset result and continue to next param
|
|
83
78
|
|
|
84
79
|
return cert_common.test_epilog(test)
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
"For each supported value - configure the BRG and verify the value",
|
|
9
9
|
"Test epilog and revert to defaults"],
|
|
10
10
|
"expectedOutcome": "All values configured successfully",
|
|
11
|
-
"mandatory":
|
|
11
|
+
"mandatory": 0,
|
|
12
12
|
"multiBridgeTest": 0,
|
|
13
13
|
"gwOnlyTest": 0,
|
|
14
14
|
"internalBridge": 1,
|
|
@@ -20,9 +20,9 @@ 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
|
+
test.reset_result() # reset result and continue to next param
|
|
27
27
|
|
|
28
28
|
return cert_common.test_epilog(test, revert_brgs=True, modules=[datapath_module])
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
"For each supported value - Configure the pacer interval, Generate GEN3 pixels packets & scan for packets in the bridge, Compare pacer interval mean per pixel to the configured value",
|
|
9
9
|
"Test epilog and revert to defaults"],
|
|
10
10
|
"expectedOutcome": "All values configured successfully and actual pacing found matching to the configured values",
|
|
11
|
-
"mandatory":
|
|
11
|
+
"mandatory": 0,
|
|
12
12
|
"multiBridgeTest": 0,
|
|
13
13
|
"gwOnlyTest": 0,
|
|
14
14
|
"internalBridge": 1,
|
|
@@ -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,9 @@ 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
|
+
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
|
+
test.reset_result() # reset result and continue to next param
|
|
45
49
|
|
|
46
50
|
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,9 @@ 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
|
+
test.reset_result() # reset result and continue to next param
|
|
51
51
|
|
|
52
52
|
return cert_common.test_epilog(test, revert_brgs=True, revert_gws=test.internal_brg, modules=[datapath_module])
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
"For each supported value - configure the BRG and verify the value",
|
|
9
9
|
"Test epilog and revert to defaults"],
|
|
10
10
|
"expectedOutcome": "All values configured successfully",
|
|
11
|
-
"mandatory":
|
|
11
|
+
"mandatory": 0,
|
|
12
12
|
"multiBridgeTest": 0,
|
|
13
13
|
"gwOnlyTest": 0,
|
|
14
14
|
"internalBridge": 1,
|
|
@@ -21,9 +21,8 @@ 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
|
+
test.reset_result() # reset result and continue to next param
|
|
29
28
|
return cert_common.test_epilog(test, revert_brgs=True, modules=[datapath_module])
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
"Repeat for all given packet filter values",
|
|
12
12
|
"Test epilog and revert to defaults"],
|
|
13
13
|
"expectedOutcome": "All values configured successfully and actual pacing found matching to the configured values",
|
|
14
|
-
"mandatory":
|
|
14
|
+
"mandatory": 0,
|
|
15
15
|
"multiBridgeTest": 0,
|
|
16
16
|
"gwOnlyTest": 0,
|
|
17
17
|
"internalBridge": 1,
|
|
@@ -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,9 @@ 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
|
+
test.reset_result() # reset result and continue to next param
|
|
57
58
|
|
|
58
59
|
return cert_common.test_epilog(test, revert_brgs=True, revert_gws=test.internal_brg, modules=[datapath_module], ble5=True)
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
"Repeat for all given packet filter values",
|
|
12
12
|
"Test epilog and revert to defaults"],
|
|
13
13
|
"expectedOutcome": "All values configured successfully and actual pacing found matching to the configured values",
|
|
14
|
-
"mandatory":
|
|
14
|
+
"mandatory": 0,
|
|
15
15
|
"multiBridgeTest": 0,
|
|
16
16
|
"gwOnlyTest": 0,
|
|
17
17
|
"internalBridge": 1,
|
|
@@ -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,9 @@ 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
|
+
test.reset_result() # reset result and continue to next param
|
|
58
59
|
|
|
59
60
|
return cert_common.test_epilog(test, revert_brgs=True, revert_gws=test.internal_brg, modules=[datapath_module])
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
"Repeat for all given packet filter values",
|
|
12
12
|
"Test epilog and revert to defaults"],
|
|
13
13
|
"expectedOutcome": "All values configured successfully and actual pacing found matching to the configured values",
|
|
14
|
-
"mandatory":
|
|
14
|
+
"mandatory": 0,
|
|
15
15
|
"multiBridgeTest": 0,
|
|
16
16
|
"gwOnlyTest": 0,
|
|
17
17
|
"internalBridge": 1,
|
|
@@ -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,9 @@ 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
|
+
test.reset_result() # reset result and continue to next param
|
|
58
59
|
|
|
59
60
|
return cert_common.test_epilog(test, revert_brgs=True, revert_gws=test.internal_brg, modules=[datapath_module])
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"Checking for packets violating RSSI threshold",
|
|
10
10
|
"Test epilog and revert to defaults"],
|
|
11
11
|
"expectedOutcome": "RSSI Threshold configured successfully and no pixel packets with RSSI weaker than the threshold have been echoed.",
|
|
12
|
-
"mandatory":
|
|
12
|
+
"mandatory": 0,
|
|
13
13
|
"multiBridgeTest": 0,
|
|
14
14
|
"gwOnlyTest": 0,
|
|
15
15
|
"internalBridge": 1,
|
|
@@ -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,9 @@ 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
|
-
|
|
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
|
+
test.reset_result() # reset result and continue to next param
|
|
74
75
|
|
|
75
76
|
return cert_common.test_epilog(test, revert_brgs=True, revert_gws=test.internal_brg, modules=[datapath_module])
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
"For each supported value - configure the BRG and verify the value",
|
|
9
9
|
"Test epilog and revert to defaults"],
|
|
10
10
|
"expectedOutcome": "All values configured successfully",
|
|
11
|
-
"mandatory":
|
|
11
|
+
"mandatory": 0,
|
|
12
12
|
"multiBridgeTest": 0,
|
|
13
13
|
"gwOnlyTest": 0,
|
|
14
14
|
"internalBridge": 1,
|
|
@@ -30,16 +30,15 @@ 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
|
-
|
|
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
|
+
test.reset_result() # reset result and continue to next param
|
|
44
43
|
|
|
45
44
|
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,50 +162,46 @@ 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
|
|
|
191
189
|
def run(test):
|
|
190
|
+
|
|
192
191
|
# "Test prolog"
|
|
193
192
|
datapath_module = test.active_brg.datapath
|
|
194
|
-
test = cert_common.test_prolog(test)
|
|
195
|
-
if test.rc == TEST_FAILED:
|
|
196
|
-
return cert_common.test_epilog(test)
|
|
197
193
|
|
|
194
|
+
test = cert_common.test_prolog(test)
|
|
198
195
|
pacer_interval = 1
|
|
199
196
|
test = cert_config.brg_configure(test, fields=[BRG_PACER_INTERVAL], values=[pacer_interval], module=datapath_module)[0]
|
|
200
197
|
if test.rc == TEST_FAILED:
|
|
201
198
|
test.add_reason(f"Didn't succeed to config pacer interval {pacer_interval}")
|
|
202
|
-
|
|
199
|
+
name = test.phases[0].name
|
|
200
|
+
test.set_phase_rc(name, test.rc)
|
|
201
|
+
test.add_phase_reason(name, test.reason)
|
|
202
|
+
|
|
203
|
+
if test.rc == TEST_FAILED:
|
|
204
|
+
return cert_common.test_epilog(test)
|
|
203
205
|
|
|
204
206
|
RX_RATE_TEST_MAP = {"mid_values": mid_values, "diff_pacer": diff_pacer, "min_value": min_value,
|
|
205
207
|
"max_value": max_value, "diff_rate": diff_rate}
|
|
@@ -210,9 +212,9 @@ def run(test):
|
|
|
210
212
|
field_functionality_pass_fail_print(test, param.name)
|
|
211
213
|
test.set_phase_rc(param.name, test.rc)
|
|
212
214
|
test.add_phase_reason(param.name, test.reason)
|
|
213
|
-
if test.rc == TEST_FAILED
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
215
|
+
if test.rc == TEST_FAILED:
|
|
216
|
+
if test.exit_on_param_failure:
|
|
217
|
+
break # break the whole for loop and keep the test as failed
|
|
218
|
+
test.reset_result() # reset result and continue to next param
|
|
217
219
|
|
|
218
220
|
return cert_common.test_epilog(test)
|