wiliot-certificate 4.5.0a2__tar.gz → 4.5.0a4__tar.gz
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.
- {wiliot_certificate-4.5.0a2/src/wiliot_certificate.egg-info → wiliot_certificate-4.5.0a4}/PKG-INFO +6 -11
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/README.md +5 -10
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/pyproject.toml +2 -2
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/cert_common.py +35 -18
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/cert_config.py +6 -6
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/cert_data_sim.py +12 -9
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/cert_defines.py +6 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/cert_gw_sim.py +3 -3
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/cert_mqtt.py +5 -4
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/cert_results.py +42 -32
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/cert_utils.py +9 -10
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/certificate.py +7 -5
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/certificate_cli.py +9 -12
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/certificate_eth_test_list.txt +3 -2
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/certificate_sanity_test_list.txt +3 -2
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/certificate_test_list.txt +3 -3
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/acl_test/acl_test.py +13 -15
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/brg_ota_test/brg_ota_test.json +1 -1
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/channel_scan_behaviour_test/channel_scan_behaviour_test.py +2 -2
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/connection_test/connection_test.py +4 -13
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/deduplication_test/deduplication_test.py +1 -2
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/downlink_test/downlink_test.py +1 -4
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/ext_adv_stress_test/ext_adv_stress_test.py +12 -6
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/registration_test/registration_test_cli.py +1 -1
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/stress_test/stress_test.py +12 -7
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/uplink_ext_adv_test/uplink_ext_adv_test.py +1 -2
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/uplink_test/uplink_test.py +26 -20
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/event_ble5_test/event_ble5_test.json +1 -1
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/event_ble5_test/event_ble5_test.py +7 -13
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/event_test/event_test.json +1 -1
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/event_test/event_test.py +5 -10
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/pacer_interval_ble5_test/pacer_interval_ble5_test.py +4 -4
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/pkt_filter_ble5_chl21_test/pkt_filter_ble5_chl21_test.py +5 -5
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/pkt_filter_ble5_test/pkt_filter_ble5_test.py +5 -5
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/pkt_filter_brg2gw_ext_adv_test/pkt_filter_brg2gw_ext_adv_test.py +10 -8
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/rx_rate_gen2_test/rx_rate_gen2_test.py +1 -1
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/energy2400/signal_indicator_ble5_test/signal_indicator_ble5_test.py +4 -3
- wiliot_certificate-4.5.0a4/src/certificate/tests/energy2400/signal_indicator_ext_adv_test/signal_indicator_ext_adv_test.json +19 -0
- wiliot_certificate-4.5.0a4/src/certificate/tests/energy2400/signal_indicator_ext_adv_test/signal_indicator_ext_adv_test.py +173 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/energy2400/signal_indicator_test/signal_indicator_test.py +1 -1
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/sensors/ext_sensor_test/ext_sensor_test.py +4 -9
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/api_if/api_validation.py +6 -0
- wiliot_certificate-4.5.0a4/src/common/web/templates/generator.html +210 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/web/web_utils.py +78 -56
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/gui_certificate/server.py +255 -70
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/gui_certificate/templates/cert_run.html +128 -98
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4/src/wiliot_certificate.egg-info}/PKG-INFO +6 -11
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/wiliot_certificate.egg-info/SOURCES.txt +0 -16
- wiliot_certificate-4.5.0a2/src/certificate/ag/wlt_types_ag_jsons/brg2brg_ota.json +0 -211
- wiliot_certificate-4.5.0a2/src/certificate/ag/wlt_types_ag_jsons/brg2gw_hb.json +0 -894
- wiliot_certificate-4.5.0a2/src/certificate/ag/wlt_types_ag_jsons/brg2gw_hb_sleep.json +0 -184
- wiliot_certificate-4.5.0a2/src/certificate/ag/wlt_types_ag_jsons/calibration.json +0 -490
- wiliot_certificate-4.5.0a2/src/certificate/ag/wlt_types_ag_jsons/custom.json +0 -614
- wiliot_certificate-4.5.0a2/src/certificate/ag/wlt_types_ag_jsons/datapath.json +0 -900
- wiliot_certificate-4.5.0a2/src/certificate/ag/wlt_types_ag_jsons/energy2400.json +0 -670
- wiliot_certificate-4.5.0a2/src/certificate/ag/wlt_types_ag_jsons/energySub1g.json +0 -691
- wiliot_certificate-4.5.0a2/src/certificate/ag/wlt_types_ag_jsons/externalSensor.json +0 -727
- wiliot_certificate-4.5.0a2/src/certificate/ag/wlt_types_ag_jsons/interface.json +0 -1095
- wiliot_certificate-4.5.0a2/src/certificate/ag/wlt_types_ag_jsons/powerManagement.json +0 -1439
- wiliot_certificate-4.5.0a2/src/certificate/ag/wlt_types_ag_jsons/side_info_sensor.json +0 -105
- wiliot_certificate-4.5.0a2/src/certificate/ag/wlt_types_ag_jsons/signal_indicator_data.json +0 -77
- wiliot_certificate-4.5.0a2/src/certificate/ag/wlt_types_ag_jsons/unified_echo_ext_pkt.json +0 -126
- wiliot_certificate-4.5.0a2/src/certificate/ag/wlt_types_ag_jsons/unified_echo_pkt.json +0 -175
- wiliot_certificate-4.5.0a2/src/certificate/ag/wlt_types_ag_jsons/unified_sensor_pkt.json +0 -65
- wiliot_certificate-4.5.0a2/src/certificate/tests/energy2400/signal_indicator_ext_adv_test/signal_indicator_ext_adv_test.json +0 -20
- wiliot_certificate-4.5.0a2/src/certificate/tests/energy2400/signal_indicator_ext_adv_test/signal_indicator_ext_adv_test.py +0 -331
- wiliot_certificate-4.5.0a2/src/common/web/templates/generator.html +0 -148
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/LICENSE +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/setup.cfg +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/__init__.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/ag/wlt_cmd_if.html +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/ag/wlt_types_ag.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/cert_prints.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/cert_protobuf.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/calibration/interval_test/interval_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/calibration/interval_test/interval_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/calibration/output_power_test/output_power_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/calibration/output_power_test/output_power_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/calibration/pattern_test/pattern_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/calibration/pattern_test/pattern_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/acl_ext_adv_test/acl_ext_adv_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/acl_ext_adv_test/acl_ext_adv_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/acl_test/acl_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/brg_ota_test/brg_ota_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/channel_scan_behaviour_test/channel_scan_behaviour_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/connection_test/connection_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/deduplication_test/deduplication_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/downlink_test/downlink_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/ext_adv_stress_test/ext_adv_stress_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/reboot_test/reboot_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/reboot_test/reboot_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/registration_test/registration_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/registration_test/registration_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/stress_test/stress_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/uplink_ext_adv_test/uplink_ext_adv_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/cloud_connectivity/uplink_test/uplink_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/aging_test/aging_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/aging_test/aging_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/num_of_tags_test/num_of_tags_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/num_of_tags_test/num_of_tags_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/output_power_test/output_power_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/output_power_test/output_power_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/pacer_interval_ble5_test/pacer_interval_ble5_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/pacer_interval_test/pacer_interval_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/pacer_interval_test/pacer_interval_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/pattern_test/pattern_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/pattern_test/pattern_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/pkt_filter_ble5_chl21_test/pkt_filter_ble5_chl21_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/pkt_filter_ble5_test/pkt_filter_ble5_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/pkt_filter_brg2gw_ext_adv_test/pkt_filter_brg2gw_ext_adv_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/pkt_filter_gen3_test/pkt_filter_gen3_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/pkt_filter_gen3_test/pkt_filter_gen3_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/pkt_filter_test/pkt_filter_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/pkt_filter_test/pkt_filter_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/rssi_threshold_test/rssi_threshold_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/rssi_threshold_test/rssi_threshold_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/rx_channel_hopping_test/rx_channel_hopping_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/rx_channel_hopping_test/rx_channel_hopping_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/rx_channel_test/rx_channel_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/rx_channel_test/rx_channel_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/rx_rate_gen2_test/rx_rate_gen2_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/rx_rate_gen3_test/rx_rate_gen3_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/rx_rate_gen3_test/rx_rate_gen3_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/stress_gen3_test/stress_gen3_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/stress_gen3_test/stress_gen3_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/stress_test/stress_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/stress_test/stress_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/tx_repetition_test/tx_repetition_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/datapath/tx_repetition_test/tx_repetition_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/edge_mgmt/action_blink_test/action_blink_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/edge_mgmt/action_blink_test/action_blink_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/edge_mgmt/action_get_battery_sensor_test/action_get_battery_sensor_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/edge_mgmt/action_get_battery_sensor_test/action_get_battery_sensor_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/edge_mgmt/action_get_module_test/action_get_module_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/edge_mgmt/action_get_module_test/action_get_module_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/edge_mgmt/action_get_pof_data_test/action_get_pof_data_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/edge_mgmt/action_get_pof_data_test/action_get_pof_data_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/edge_mgmt/action_gw_hb_test/action_gw_hb_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/edge_mgmt/action_gw_hb_test/action_gw_hb_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/edge_mgmt/action_reboot_test/action_reboot_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/edge_mgmt/action_reboot_test/action_reboot_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/edge_mgmt/action_restore_defaults_test/action_restore_defaults_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/edge_mgmt/action_restore_defaults_test/action_restore_defaults_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/edge_mgmt/action_send_hb_test/action_send_hb_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/edge_mgmt/action_send_hb_test/action_send_hb_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/edge_mgmt/periodic_msgs_test/periodic_msgs_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/edge_mgmt/periodic_msgs_test/periodic_msgs_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/energy2400/duty_cycle_test/duty_cycle_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/energy2400/duty_cycle_test/duty_cycle_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/energy2400/output_power_test/output_power_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/energy2400/output_power_test/output_power_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/energy2400/pattern_test/pattern_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/energy2400/pattern_test/pattern_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/energy2400/signal_indicator_ble5_test/signal_indicator_ble5_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/energy2400/signal_indicator_test/signal_indicator_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/energy_sub1g/duty_cycle_test/duty_cycle_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/energy_sub1g/duty_cycle_test/duty_cycle_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/energy_sub1g/pattern_test/pattern_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/energy_sub1g/pattern_test/pattern_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/pwr_mgmt/pwr_mgmt_test/pwr_mgmt_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/pwr_mgmt/pwr_mgmt_test/pwr_mgmt_test.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/tests/sensors/ext_sensor_test/ext_sensor_test.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/certificate/wlt_types.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/api_if/202/data.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/api_if/202/logs.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/api_if/202/status.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/api_if/203/data.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/api_if/203/logs.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/api_if/203/status.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/api_if/204/data.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/api_if/204/logs.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/api_if/204/status.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/api_if/205/data.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/api_if/205/logs.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/api_if/205/status.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/api_if/206/data.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/api_if/206/logs.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/api_if/206/status.json +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/api_if/__init__.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/web/templates/index.html +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/web/templates/menu.html +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/web/templates/parser.html +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/web/templates/wlt_types.html +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/wltPb_pb2.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/wltPb_pb2.pyi +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/common/wlt_logo.png +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/gui_certificate/__init__.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/gui_certificate/gui_certificate_cli.py +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/wiliot_certificate.egg-info/dependency_links.txt +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/wiliot_certificate.egg-info/entry_points.txt +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/wiliot_certificate.egg-info/requires.txt +0 -0
- {wiliot_certificate-4.5.0a2 → wiliot_certificate-4.5.0a4}/src/wiliot_certificate.egg-info/top_level.txt +0 -0
{wiliot_certificate-4.5.0a2/src/wiliot_certificate.egg-info → wiliot_certificate-4.5.0a4}/PKG-INFO
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: wiliot_certificate
|
|
3
|
-
Version: 4.5.
|
|
3
|
+
Version: 4.5.0a4
|
|
4
4
|
Summary: A library for certifying Wiliot-compliant boards
|
|
5
5
|
Author-email: Wiliot <support@wiliot.com>
|
|
6
6
|
License-Expression: MIT
|
|
@@ -30,7 +30,7 @@ Requires-Dist: reportlab>=4.3.1
|
|
|
30
30
|
Requires-Dist: google-api-python-client>=2.162.0
|
|
31
31
|
Dynamic: license-file
|
|
32
32
|
|
|
33
|
-
# wiliot-certificate
|
|
33
|
+
# wiliot-certificate
|
|
34
34
|
|
|
35
35
|
<!-- Description -->
|
|
36
36
|
wiliot-certificate is a Python library that provides tools for testing and certifying boards for compatibility with Wiliot’s ecosystem.
|
|
@@ -40,30 +40,27 @@ This python package includes the following tools:
|
|
|
40
40
|
- Tester Upgrade (`wlt-cert-tester-upgrade`)
|
|
41
41
|
- Registration Certificate (`wlt-cert-reg`)
|
|
42
42
|
|
|
43
|
-
#
|
|
44
|
-
wiliot-certificate versions 4.5.
|
|
43
|
+
# Versioning:
|
|
44
|
+
wiliot-certificate versions 4.5.x are compatible with firmware version >=4.5.0 (API VERSION: 13)
|
|
45
45
|
|
|
46
46
|
## Installing wiliot-certificate
|
|
47
|
-
Install wiliot-certificate:
|
|
48
47
|
````commandline
|
|
49
48
|
pip install wiliot-certificate
|
|
50
49
|
````
|
|
51
50
|
|
|
52
51
|
## Using wiliot-certificate
|
|
53
52
|
### Certification
|
|
54
|
-
In terminal, run:
|
|
55
53
|
````commandline
|
|
56
54
|
wlt-cert
|
|
57
55
|
````
|
|
58
56
|
This tool is the default to test and certify your device.
|
|
59
57
|
It runs a setup wizard that walks you through the initialization steps before running the tests.
|
|
60
|
-
You'll need a [validation schema](https://community.wiliot.com/customers/s/article/Validation-Schema), tester device and custom broker json file (
|
|
58
|
+
You'll need a [validation schema](https://community.wiliot.com/customers/s/article/Validation-Schema), tester device and custom broker json file (more info [here](https://community.wiliot.com/customers/s/article/Wiliot-Certification)).
|
|
61
59
|
Once set up it opens a terminal and tests your device.
|
|
62
60
|
|
|
63
61
|
|
|
64
62
|
|
|
65
63
|
### Certificate CLI
|
|
66
|
-
In terminal, run:
|
|
67
64
|
````commandline
|
|
68
65
|
wlt-cert-cli -h
|
|
69
66
|
````
|
|
@@ -71,7 +68,6 @@ CLI version of the certificate. Use -h for details on the different arguments.
|
|
|
71
68
|
|
|
72
69
|
|
|
73
70
|
### Tester Upgrade
|
|
74
|
-
In terminal, run:
|
|
75
71
|
````commandline
|
|
76
72
|
wlt-cert-tester-upgrade
|
|
77
73
|
````
|
|
@@ -79,13 +75,12 @@ Upgrades the firmware of the tester device to the version required for certifica
|
|
|
79
75
|
|
|
80
76
|
|
|
81
77
|
### Registration Certificate
|
|
82
|
-
In terminal, run:
|
|
83
78
|
````commandline
|
|
84
79
|
wlt-cert-reg
|
|
85
80
|
````
|
|
86
81
|
Certify the gateway registration process to Wiliot platform.
|
|
87
82
|
The gateway must use Wiliot production MQTT broker, and mustn't be registered to any account on Wiliot platform.
|
|
88
|
-
Use -h for details on the arguments
|
|
83
|
+
Use -h for details on the arguments (see [Registration](https://community.wiliot.com/customers/s/article/Wiliot-Certification) for more info).
|
|
89
84
|
|
|
90
85
|
|
|
91
86
|
## The following capabilities are not tested in this version
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# wiliot-certificate
|
|
1
|
+
# wiliot-certificate
|
|
2
2
|
|
|
3
3
|
<!-- Description -->
|
|
4
4
|
wiliot-certificate is a Python library that provides tools for testing and certifying boards for compatibility with Wiliot’s ecosystem.
|
|
@@ -8,30 +8,27 @@ This python package includes the following tools:
|
|
|
8
8
|
- Tester Upgrade (`wlt-cert-tester-upgrade`)
|
|
9
9
|
- Registration Certificate (`wlt-cert-reg`)
|
|
10
10
|
|
|
11
|
-
#
|
|
12
|
-
wiliot-certificate versions 4.5.
|
|
11
|
+
# Versioning:
|
|
12
|
+
wiliot-certificate versions 4.5.x are compatible with firmware version >=4.5.0 (API VERSION: 13)
|
|
13
13
|
|
|
14
14
|
## Installing wiliot-certificate
|
|
15
|
-
Install wiliot-certificate:
|
|
16
15
|
````commandline
|
|
17
16
|
pip install wiliot-certificate
|
|
18
17
|
````
|
|
19
18
|
|
|
20
19
|
## Using wiliot-certificate
|
|
21
20
|
### Certification
|
|
22
|
-
In terminal, run:
|
|
23
21
|
````commandline
|
|
24
22
|
wlt-cert
|
|
25
23
|
````
|
|
26
24
|
This tool is the default to test and certify your device.
|
|
27
25
|
It runs a setup wizard that walks you through the initialization steps before running the tests.
|
|
28
|
-
You'll need a [validation schema](https://community.wiliot.com/customers/s/article/Validation-Schema), tester device and custom broker json file (
|
|
26
|
+
You'll need a [validation schema](https://community.wiliot.com/customers/s/article/Validation-Schema), tester device and custom broker json file (more info [here](https://community.wiliot.com/customers/s/article/Wiliot-Certification)).
|
|
29
27
|
Once set up it opens a terminal and tests your device.
|
|
30
28
|
|
|
31
29
|
|
|
32
30
|
|
|
33
31
|
### Certificate CLI
|
|
34
|
-
In terminal, run:
|
|
35
32
|
````commandline
|
|
36
33
|
wlt-cert-cli -h
|
|
37
34
|
````
|
|
@@ -39,7 +36,6 @@ CLI version of the certificate. Use -h for details on the different arguments.
|
|
|
39
36
|
|
|
40
37
|
|
|
41
38
|
### Tester Upgrade
|
|
42
|
-
In terminal, run:
|
|
43
39
|
````commandline
|
|
44
40
|
wlt-cert-tester-upgrade
|
|
45
41
|
````
|
|
@@ -47,13 +43,12 @@ Upgrades the firmware of the tester device to the version required for certifica
|
|
|
47
43
|
|
|
48
44
|
|
|
49
45
|
### Registration Certificate
|
|
50
|
-
In terminal, run:
|
|
51
46
|
````commandline
|
|
52
47
|
wlt-cert-reg
|
|
53
48
|
````
|
|
54
49
|
Certify the gateway registration process to Wiliot platform.
|
|
55
50
|
The gateway must use Wiliot production MQTT broker, and mustn't be registered to any account on Wiliot platform.
|
|
56
|
-
Use -h for details on the arguments
|
|
51
|
+
Use -h for details on the arguments (see [Registration](https://community.wiliot.com/customers/s/article/Wiliot-Certification) for more info).
|
|
57
52
|
|
|
58
53
|
|
|
59
54
|
## The following capabilities are not tested in this version
|
|
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "wiliot_certificate"
|
|
7
|
-
version = "4.5.
|
|
7
|
+
version = "4.5.0a4"
|
|
8
8
|
authors = [
|
|
9
9
|
{ name="Wiliot", email="support@wiliot.com" }
|
|
10
10
|
]
|
|
@@ -54,7 +54,7 @@ exclude = ["*.ut*"]
|
|
|
54
54
|
|
|
55
55
|
[tool.setuptools.package-data]
|
|
56
56
|
common = ["wlt_logo.png", "**/*.html", "**/*.json"]
|
|
57
|
-
certificate = ["
|
|
57
|
+
certificate = ["tests/**/*.json", "*_list.txt", "**/wlt_cmd_if.html"]
|
|
58
58
|
gui_certificate = ["**/*.html"]
|
|
59
59
|
|
|
60
60
|
[tool.setuptools.exclude-package-data]
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
from certificate.cert_prints import *
|
|
2
2
|
from certificate.cert_defines import *
|
|
3
3
|
from certificate.wlt_types import *
|
|
4
|
-
from certificate.cert_utils import Phase
|
|
5
|
-
from certificate.cert_utils import *
|
|
6
4
|
import certificate.cert_utils as cert_utils
|
|
7
5
|
import certificate.cert_config as cert_config
|
|
8
6
|
import certificate.cert_mqtt as cert_mqtt
|
|
@@ -606,8 +604,8 @@ def run_event_test_phase(test, phase, datapath_module, values, scan_time, event_
|
|
|
606
604
|
scan_time_multiplier = (1 / 3)
|
|
607
605
|
fields += [BRG_RSSI_MOVEMENT_THRESHOLD]
|
|
608
606
|
|
|
609
|
-
|
|
610
|
-
|
|
607
|
+
ble5 = ble5_test and test.dut_is_bridge() # ble5 only for bridge dut (with combo we don't need to wait)
|
|
608
|
+
test = cert_config.brg_configure(test, fields=fields, values=values, module=datapath_module, ble5=ble5)[0]
|
|
611
609
|
test.set_phase_rc(phase, test.rc)
|
|
612
610
|
test.add_phase_reason(phase, test.reason)
|
|
613
611
|
if test.rc == TEST_FAILED and test.exit_on_param_failure:
|
|
@@ -776,8 +774,7 @@ def scan_for_modules(test, modules=[]):
|
|
|
776
774
|
|
|
777
775
|
|
|
778
776
|
def search_action_ack(test, action_id, **kwargs):
|
|
779
|
-
test, mgmt_pkts =
|
|
780
|
-
mgmt_type=[eval_pkt(f'{ag.ACTIONS_DICT[action_id]}{test.active_brg.api_version}')])
|
|
777
|
+
test, mgmt_pkts = scan_for_mgmt_pkts(test, mgmt_type=[eval_pkt(f'{ag.ACTIONS_DICT[action_id]}{test.active_brg.api_version}')])
|
|
781
778
|
if test.rc == TEST_FAILED:
|
|
782
779
|
return test
|
|
783
780
|
print("\nReceived ACK pkts:")
|
|
@@ -1051,8 +1048,9 @@ def get_gw_type(mqttc):
|
|
|
1051
1048
|
|
|
1052
1049
|
def get_module_if_pkt(test):
|
|
1053
1050
|
cert_config.send_brg_action(test, ag.ACTION_GET_MODULE, interface=1)
|
|
1054
|
-
|
|
1055
|
-
|
|
1051
|
+
mgmt_type = [m for m in ag.MODULES_LIST if "ModuleIf" in m.__name__]
|
|
1052
|
+
test, pkts = scan_for_mgmt_pkts(test, mgmt_type=mgmt_type)
|
|
1053
|
+
|
|
1056
1054
|
if test.rc == TEST_FAILED:
|
|
1057
1055
|
return test, NO_RESPONSE
|
|
1058
1056
|
else:
|
|
@@ -1273,10 +1271,28 @@ def output_power_supported(board_type, output_power):
|
|
|
1273
1271
|
else:
|
|
1274
1272
|
return output_power in ag.OUTPUT_POWER_2_4_SUPPORTED_VALUES
|
|
1275
1273
|
|
|
1274
|
+
|
|
1275
|
+
def validate_received_packets(pkts_array):
|
|
1276
|
+
for pkt in pkts_array:
|
|
1277
|
+
# Check all required fields are present
|
|
1278
|
+
if TIMESTAMP not in pkt:
|
|
1279
|
+
return False, "timestamp field is missing in some of the packets"
|
|
1280
|
+
if ALIAS_BRIDGE_ID not in pkt:
|
|
1281
|
+
return False, "alias_bridge_id field is missing in some of the packets"
|
|
1282
|
+
if PAYLOAD not in pkt:
|
|
1283
|
+
return False, "payload field is missing in some of the packets"
|
|
1284
|
+
if SEQUENCE_ID not in pkt:
|
|
1285
|
+
return False, "sequence_id field is missing in some of the packets"
|
|
1286
|
+
# Check that the payload length is either 62 or 74 hex characters (equevelnt to 31 or 37 bytes)
|
|
1287
|
+
if len(pkt[PAYLOAD]) != 62 and len(pkt[PAYLOAD]) !=74:
|
|
1288
|
+
return False, f"Payload length is invalid for packet {pkt[PAYLOAD]}"
|
|
1289
|
+
return True, ""
|
|
1290
|
+
|
|
1291
|
+
|
|
1276
1292
|
def wiliot_pkts_validation(test, all_messages_in_test, all_data_pkts):
|
|
1277
1293
|
PHASE_NAME = "Wiliot packets validation"
|
|
1278
1294
|
phase_run_print(PHASE_NAME)
|
|
1279
|
-
wiliot_pkts_validation_phase = Phase(PHASE_NAME, rc=TEST_PASSED)
|
|
1295
|
+
wiliot_pkts_validation_phase = cert_utils.Phase(PHASE_NAME, rc=TEST_PASSED)
|
|
1280
1296
|
|
|
1281
1297
|
if len(all_messages_in_test) == 0:
|
|
1282
1298
|
wiliot_pkts_validation_phase.rc = TEST_FAILED
|
|
@@ -1358,9 +1374,9 @@ def timestamps_validation(wiliot_pkts_validation_phase, all_messages_in_test, up
|
|
|
1358
1374
|
return wiliot_pkts_validation_phase
|
|
1359
1375
|
previous_ts = inner_pkt[TIMESTAMP]
|
|
1360
1376
|
else:
|
|
1361
|
-
if inner_pkt[TIMESTAMP]
|
|
1377
|
+
if inner_pkt[TIMESTAMP] <= previous_ts:
|
|
1362
1378
|
wiliot_pkts_validation_phase.rc = TEST_FAILED
|
|
1363
|
-
wiliot_pkts_validation_phase.reason = f'Timestamp is not incremental for inner packet {inner_pkt}'
|
|
1379
|
+
wiliot_pkts_validation_phase.reason = f'Timestamp is not incremental for inner packet {inner_pkt[PAYLOAD]}'
|
|
1364
1380
|
return wiliot_pkts_validation_phase
|
|
1365
1381
|
previous_ts = inner_pkt[TIMESTAMP]
|
|
1366
1382
|
return wiliot_pkts_validation_phase
|
|
@@ -1438,21 +1454,22 @@ def stress_analysis(test, pps, sent_pkts, received_pkts):
|
|
|
1438
1454
|
|
|
1439
1455
|
# PASS/FAIL logic
|
|
1440
1456
|
if percentage_received < 1: # If less than 1% of the packets were received, fail the test
|
|
1441
|
-
test.
|
|
1442
|
-
test.
|
|
1457
|
+
test.set_phase_rc(str(pps), TEST_FAILED)
|
|
1458
|
+
test.add_phase_reason(str(pps), "Insufficient amount of packets were scanned & uploaded by the gateway")
|
|
1443
1459
|
else:
|
|
1444
|
-
test.
|
|
1460
|
+
test.set_phase_rc(str(pps), TEST_PASSED)
|
|
1461
|
+
test.add_phase_reason(str(pps), f"received pps: {received_pps} ({percentage_received}% of packets)")
|
|
1445
1462
|
|
|
1446
1463
|
return test, received_pps
|
|
1447
1464
|
|
|
1448
1465
|
|
|
1449
1466
|
def generate_adv_payload(test_indicator, unique_pkt=False):
|
|
1450
1467
|
# Keep last 4 bytes as zeroes so for incrementing them in FW 'ble_sim'
|
|
1451
|
-
adva = hex2alias_id_get(
|
|
1452
|
-
unique_pkt_byte =
|
|
1468
|
+
adva = hex2alias_id_get(get_random_hex_str(12))
|
|
1469
|
+
unique_pkt_byte = get_random_hex_str(2) if unique_pkt == False else "00"
|
|
1453
1470
|
payload = (ag.Hdr(group_id=ag.GROUP_ID_UNIFIED_PKT_V2).dump() + test_indicator +
|
|
1454
|
-
|
|
1471
|
+
get_random_hex_str(32) + unique_pkt_byte + "00000000")
|
|
1455
1472
|
return adva + payload
|
|
1456
1473
|
|
|
1457
1474
|
def change_endianness(hex_str: str) -> str:
|
|
1458
|
-
return ''.join(f"{b:02X}" for b in bytes.fromhex(hex_str)[::-1])
|
|
1475
|
+
return ''.join(f"{b:02X}" for b in bytes.fromhex(hex_str)[::-1])
|
|
@@ -41,6 +41,8 @@ def gw_configure(test, cfg={}, version="", extended_cfg={}, ret_pkt=False, wait=
|
|
|
41
41
|
for p in cert_mqtt.get_all_status_pkts(mqttc):
|
|
42
42
|
if GW_CONF in p or GW_STATUS in p:
|
|
43
43
|
test.gw_api_version = p[GW_CONF][GW_API_VERSION] if GW_CONF in p else p[GW_STATUS][GW_API_VERSION]
|
|
44
|
+
if target == DUT and is_gw(test.dut):
|
|
45
|
+
test.dut.gw_api_version = test.gw_api_version
|
|
44
46
|
print_pkt(p)
|
|
45
47
|
utPrint("SUCCESS: Found GW cfg", "GREEN")
|
|
46
48
|
wait_time_n_print(2)
|
|
@@ -313,14 +315,14 @@ def brg_configure_ble5(test, cfg_pkt=None, module=None, fields=None, values=None
|
|
|
313
315
|
if wait is False:
|
|
314
316
|
return test, DONE
|
|
315
317
|
while not pkts_found:
|
|
316
|
-
if ((datetime.datetime.now() - start_time).seconds >
|
|
318
|
+
if ((datetime.datetime.now() - start_time).seconds > BLE5_MAX_DURATION_SEC):
|
|
317
319
|
if num_of_tries < 3:
|
|
318
320
|
num_of_tries += 1
|
|
319
321
|
start_time = datetime.datetime.now()
|
|
320
322
|
gw_downlink(test=test, raw_tx_data=cfg_pkt.dump(), max_duration=BLE5_MAX_DURATION_MS, max_retries=BLE5_MAX_RETRIES, target=target)
|
|
321
|
-
print(f"Brg configure - BLE5 mode : No pkts found after {
|
|
323
|
+
print(f"Brg configure - BLE5 mode : No pkts found after {BLE5_MAX_DURATION_SEC} seconds, in try number {num_of_tries}")
|
|
322
324
|
else:
|
|
323
|
-
test.add_reason(f"Brg configure - BLE5 mode : No pkts found after {
|
|
325
|
+
test.add_reason(f"Brg configure - BLE5 mode : No pkts found after {BLE5_MAX_DURATION_SEC} seconds, in 3 tries")
|
|
324
326
|
test.rc = TEST_FAILED
|
|
325
327
|
time.sleep(1)
|
|
326
328
|
mqttc.flush_pkts()
|
|
@@ -351,9 +353,7 @@ def get_default_brg_pkt(test, pkt_type, group_id=ag.GROUP_ID_GW2BRG, seq_id=0, t
|
|
|
351
353
|
seq_id = test.get_seq_id() if seq_id == 0 else seq_id
|
|
352
354
|
# Bypass from default sub1g ep cfg of 0 (no energizing) ONLY if not using data simulation
|
|
353
355
|
if "ModuleEnergySub1G" in pkt_type.__name__ and BRG_PATTERN not in kwargs and test.data != DATA_SIMULATION:
|
|
354
|
-
|
|
355
|
-
brg_pattern = "sub1g_energy_" + BRG_PATTERN if brg.api_version < ag.API_VERSION_V12 else BRG_PATTERN
|
|
356
|
-
kwargs.update({brg_pattern: ag.SUB1G_ENERGY_PATTERN_ISRAEL})
|
|
356
|
+
kwargs.update({BRG_PATTERN: ag.SUB1G_ENERGY_PATTERN_ISRAEL})
|
|
357
357
|
brg_pkt = WltPkt(hdr=ag.Hdr(group_id=group_id), pkt=pkt_type(brg_mac=brg.id_int if brg else 0, seq_id=seq_id, **kwargs))
|
|
358
358
|
return brg_pkt
|
|
359
359
|
|
|
@@ -23,10 +23,10 @@ SECONDARY_CHANNEL_10 = 10
|
|
|
23
23
|
SECONDARY_CHANNEL_21 = 21
|
|
24
24
|
|
|
25
25
|
# Randomize pixel simulation indicator once per run (6 hex chars)
|
|
26
|
-
PIXEL_SIM_INDICATOR
|
|
26
|
+
PIXEL_SIM_INDICATOR = get_random_hex_str(6)
|
|
27
27
|
|
|
28
28
|
def init_adva(flow_version_major=0x4, flow_version_minor=0x34):
|
|
29
|
-
return "{0:02X}".format(flow_version_major) +
|
|
29
|
+
return "{0:02X}".format(flow_version_major) + get_random_hex_str(8) + "{0:02X}".format(flow_version_minor)
|
|
30
30
|
|
|
31
31
|
random_bytes = lambda n: int.from_bytes(os.urandom(n), "big")
|
|
32
32
|
|
|
@@ -41,15 +41,16 @@ def brg_pkt_gen(num_of_pkts_per_brg, num_of_brgs, brgs_list=[], pkt_type=PIXELS_
|
|
|
41
41
|
if brgs_list:
|
|
42
42
|
brg_mac = brgs_list[i]
|
|
43
43
|
else:
|
|
44
|
-
brg_mac = cert_common.hex2alias_id_get(
|
|
44
|
+
brg_mac = cert_common.hex2alias_id_get(get_random_hex_str(12))
|
|
45
45
|
bridge_ids.append(brg_mac)
|
|
46
46
|
adva = cert_common.change_endianness(brg_mac) # Change endianness to little endian
|
|
47
|
-
|
|
47
|
+
|
|
48
48
|
for j in range(num_of_pkts_per_brg):
|
|
49
|
-
serial_pkt_id = f"{i % 256:02X}{j % 256:02X}{idx:04X}"
|
|
50
|
-
|
|
49
|
+
serial_pkt_id = f"{i % 256:02X}{j % 256:02X}{idx:04X}" # 8 hex chars - 4 bytes
|
|
50
|
+
|
|
51
51
|
if pkt_type == PIXELS_PKT:
|
|
52
|
-
payload = ag.Hdr(group_id=ag.GROUP_ID_UNIFIED_PKT_V2).dump() +
|
|
52
|
+
payload = (ag.Hdr(group_id=ag.GROUP_ID_UNIFIED_PKT_V2).dump() +
|
|
53
|
+
indicator + brg_mac + get_random_hex_str(22) + serial_pkt_id)
|
|
53
54
|
|
|
54
55
|
if pkt_type == MGMT_PKT:
|
|
55
56
|
mgmt_pkt = eval_pkt(f'GenericV{ag.API_VERSION_LATEST}')
|
|
@@ -57,10 +58,12 @@ def brg_pkt_gen(num_of_pkts_per_brg, num_of_brgs, brgs_list=[], pkt_type=PIXELS_
|
|
|
57
58
|
payload = ag.Hdr(group_id=ag.GROUP_ID_BRG2GW).dump() + body.dump()[:-14] + indicator + serial_pkt_id
|
|
58
59
|
|
|
59
60
|
if pkt_type == SENSOR_PKT:
|
|
60
|
-
payload = ag.Hdr(uuid_msb=ag.HDR_DEFAULT_BRG_SENSOR_UUID_MSB, uuid_lsb=ag.HDR_DEFAULT_BRG_SENSOR_UUID_LSB).dump() +
|
|
61
|
+
payload = (ag.Hdr(uuid_msb=ag.HDR_DEFAULT_BRG_SENSOR_UUID_MSB, uuid_lsb=ag.HDR_DEFAULT_BRG_SENSOR_UUID_LSB).dump() +
|
|
62
|
+
indicator + brg_mac + get_random_hex_str(22) + serial_pkt_id)
|
|
61
63
|
|
|
62
64
|
if pkt_type == SIDE_INFO_SENSOR_PKT:
|
|
63
|
-
payload = ag.Hdr(group_id=ag.GROUP_ID_SIDE_INFO_SENSOR).dump() +
|
|
65
|
+
payload = (ag.Hdr(group_id=ag.GROUP_ID_SIDE_INFO_SENSOR).dump() +
|
|
66
|
+
indicator + brg_mac + get_random_hex_str(22) + serial_pkt_id)
|
|
64
67
|
|
|
65
68
|
idx += 1
|
|
66
69
|
pkts += [GenericPkt(adva=adva, payload=payload)]
|
|
@@ -1,11 +1,16 @@
|
|
|
1
1
|
# Files
|
|
2
2
|
import os
|
|
3
|
+
import random
|
|
3
4
|
import datetime
|
|
4
5
|
import importlib.metadata
|
|
5
6
|
import certificate.ag.wlt_types_ag as ag
|
|
7
|
+
|
|
8
|
+
get_random_hex_str = lambda n: ''.join([random.choice('0123456789ABCDEF') for _ in range(n)])
|
|
9
|
+
|
|
6
10
|
# BASE_DIR should be initiated in the same dir as certificate.py
|
|
7
11
|
BASE_DIR = os.path.dirname(os.path.abspath(__file__))
|
|
8
12
|
ARTIFACTS_DIR = os.path.join(os.getcwd(), f"cert_artifacts_{datetime.datetime.now().strftime("%d_%m_%Y__%H_%M_%S")}")
|
|
13
|
+
|
|
9
14
|
# CERT_VERSION handling - local/PyPi
|
|
10
15
|
LOCAL_DEV = "local-dev"
|
|
11
16
|
try:
|
|
@@ -278,6 +283,7 @@ GW_LONGITUDE_DEFAULT = -117.0839
|
|
|
278
283
|
GW_API_VER_DEFAULT = "201"
|
|
279
284
|
GW_API_VER_OLD = "200"
|
|
280
285
|
GW_API_VER_LATEST = "206"
|
|
286
|
+
API_OLDEST_SUPPORTED_VERSION = ag.API_VERSION_V12
|
|
281
287
|
BRG_CFG_HAS_LEN = 2
|
|
282
288
|
CLEAR_DATA_PATH_TIMEOUT = 10
|
|
283
289
|
ACTION_LONG_TIMEOUT = 120
|
|
@@ -330,10 +330,10 @@ def handle_cmds(input, ble_serial):
|
|
|
330
330
|
GW_SIM_RESET_TS = datetime.datetime.now()
|
|
331
331
|
write_to_ble(ble_serial, RESET_GW, sleep=0)
|
|
332
332
|
if input.startswith(RX_NORDIC_RECOVER_NORESET):
|
|
333
|
-
utPrint(f"
|
|
333
|
+
utPrint(f"COM tester recovered", "CYAN")
|
|
334
334
|
write_to_ble(ble_serial, f"{CONNECTIVITY_STATUS} 1 1")
|
|
335
335
|
|
|
336
|
-
def gw_sim_run(port, gw_id, custom_broker,
|
|
336
|
+
def gw_sim_run(port, gw_id, custom_broker, disable_interference_analyzer=False):
|
|
337
337
|
|
|
338
338
|
# Init serial side
|
|
339
339
|
if not port:
|
|
@@ -378,7 +378,7 @@ def gw_sim_run(port, gw_id, custom_broker, analyze_interference=False):
|
|
|
378
378
|
write_to_ble(ble_serial, f"{CONNECTIVITY_STATUS} 1 1")
|
|
379
379
|
|
|
380
380
|
# Run interference analysis
|
|
381
|
-
if
|
|
381
|
+
if not disable_interference_analyzer:
|
|
382
382
|
print(color("BLUE", f"\nStarting interference analysis for channels {[ch[0] for ch in CHANNELS_TO_ANALYZE]}. This will take {30 * len(CHANNELS_TO_ANALYZE)} seconds (total)"))
|
|
383
383
|
interference_analysis(ble_serial)
|
|
384
384
|
|
|
@@ -198,7 +198,8 @@ def on_message_json(mqttc, userdata, message):
|
|
|
198
198
|
wlt_mqtt_pkts = userdata[PKTS]
|
|
199
199
|
data = json.loads(message.payload.decode("utf-8"))
|
|
200
200
|
wlt_mqtt_pkts.insert(WltMqttPkt(data, message.topic, userdata))
|
|
201
|
-
|
|
201
|
+
text = json.dumps(json.loads(message.payload.decode("utf-8")), indent=4)
|
|
202
|
+
write_to_mqtt_log_file("// JSON message received at {}, topic={}:\n{}\n".format(datetime.datetime.now().strftime("%d/%m/%Y, %H:%M:%S"), message.topic, text))
|
|
202
203
|
|
|
203
204
|
def on_message_protobuf(mqttc, userdata, message):
|
|
204
205
|
pb_msg = None
|
|
@@ -264,9 +265,9 @@ def load_custom_broker(broker_filepath, gw):
|
|
|
264
265
|
except FileNotFoundError:
|
|
265
266
|
raise FileNotFoundError(f"No such file: {broker_filepath}")
|
|
266
267
|
data = json.load(f)
|
|
267
|
-
data[CUSTOM_BROKER_UPDATE_TOPIC]
|
|
268
|
-
data[CUSTOM_BROKER_STATUS_TOPIC]
|
|
269
|
-
data[CUSTOM_BROKER_DATA_TOPIC]
|
|
268
|
+
data[CUSTOM_BROKER_UPDATE_TOPIC] = data[CUSTOM_BROKER_UPDATE_TOPIC].replace(f'<{GW_ID}>', gw)
|
|
269
|
+
data[CUSTOM_BROKER_STATUS_TOPIC] = data[CUSTOM_BROKER_STATUS_TOPIC].replace(f'<{GW_ID}>', gw)
|
|
270
|
+
data[CUSTOM_BROKER_DATA_TOPIC] = data[CUSTOM_BROKER_DATA_TOPIC].replace(f'<{GW_ID}>', gw)
|
|
270
271
|
return data
|
|
271
272
|
|
|
272
273
|
def mqttc_init(gw_id, custom_broker, data=DATA_REAL_TAGS):
|
|
@@ -31,6 +31,7 @@ CERT_VER = "Certificate Version"
|
|
|
31
31
|
TESTING_DEVICE_INFO = "Testing Device Information"
|
|
32
32
|
TESTED_DEVICE_INFO = "Tested Device Information"
|
|
33
33
|
SIM = "Simulator"
|
|
34
|
+
GATEWAY = "Gateway"
|
|
34
35
|
BRG = "Bridge"
|
|
35
36
|
BLE_MAC_ADDRESS = "BLE MAC Address"
|
|
36
37
|
BOARD_TYPE = "Board Type"
|
|
@@ -113,32 +114,24 @@ def get_important_tests_info():
|
|
|
113
114
|
patterns = ["DISCONNECTED", "WLT_ERROR", "free heap size", "python_mqtt_disconnect"]
|
|
114
115
|
return "".join([l.strip(' "') for l in open(os.path.join(ARTIFACTS_DIR, CERT_MQTT_LOG_FILE)).readlines() if any([p in l for p in patterns])])
|
|
115
116
|
|
|
116
|
-
def generate_results_files(
|
|
117
|
+
def generate_results_files(html=True, pdf=True, failures=0, skipped=0, start_time=datetime.datetime.now(), tests=[], error=None, non_cert_run=False):
|
|
117
118
|
print(cert_prints.SEP)
|
|
118
119
|
duration = (datetime.datetime.now()-start_time)
|
|
119
120
|
print("Tests duration: {}".format(str(duration).split(".")[0]))
|
|
120
121
|
pipeline = cert_prints.pipeline_running()
|
|
121
|
-
|
|
122
|
-
if
|
|
123
|
-
|
|
124
|
-
if isinstance(brg, cert_utils.Bridge):
|
|
125
|
-
print("Bridge version: {}".format(brg.version))
|
|
122
|
+
test = tests[-1] if tests else None
|
|
123
|
+
if test and test.dut_is_bridge():
|
|
124
|
+
print("Bridge version: {}".format(test.dut.version))
|
|
126
125
|
if not error:
|
|
127
126
|
print(generate_tests_table(tests))
|
|
128
127
|
print(tabulate.tabulate([[len(tests), len(tests)-(failures+skipped), skipped, failures, len(tests)]],
|
|
129
128
|
headers=["FINISHED", "PASSED", "SKIPPED", "FAILED", "TOTAL"], tablefmt="pretty"))
|
|
130
129
|
print(cert_prints.WIL_CERT_TEXT)
|
|
131
130
|
cert_prints.print_warn(get_important_tests_info())
|
|
131
|
+
print(f"Run artifacts saved in \"{ARTIFACTS_DIR}\" directory")
|
|
132
132
|
run_type = headline_get(non_cert_run, "").strip()
|
|
133
133
|
cert_prints.print_pass_or_fail(not failures and not error, run_type)
|
|
134
134
|
|
|
135
|
-
# Get internal_brg from dut or tester
|
|
136
|
-
internal_brg = None
|
|
137
|
-
if dut and isinstance(dut, cert_utils.Gateway) and dut.has_internal_brg():
|
|
138
|
-
internal_brg = dut.internal_brg
|
|
139
|
-
elif tester:
|
|
140
|
-
internal_brg = tester.internal_brg
|
|
141
|
-
|
|
142
135
|
# Generate HTML file
|
|
143
136
|
if html:
|
|
144
137
|
file_path = os.path.join(ARTIFACTS_DIR, UT_RESULT_FILE_HTML)
|
|
@@ -160,8 +153,8 @@ def generate_results_files(dut=None, tester=None, html=True, pdf=True, failures=
|
|
|
160
153
|
f.write(update_status + "<br><br>")
|
|
161
154
|
f.write(error + "<br><br>")
|
|
162
155
|
f.write(f"{RUN_DUR}: {str(duration).split('.')[0]} <br><br>")
|
|
163
|
-
if
|
|
164
|
-
f.write(f"{BRG} {BLE_VER}: {
|
|
156
|
+
if test and test.dut_is_bridge():
|
|
157
|
+
f.write(f"{BRG} {BLE_VER}: {test.dut.version} <br><br>")
|
|
165
158
|
elif tests:
|
|
166
159
|
if not failures and ("successfully!" in update_status or "skipped!" in update_status or not pipeline):
|
|
167
160
|
headline = headline_get(non_cert_run, "Passed!")
|
|
@@ -176,12 +169,19 @@ def generate_results_files(dut=None, tester=None, html=True, pdf=True, failures=
|
|
|
176
169
|
f.write(f"{RUN_DATETIME}: {start_time.strftime('%d/%m/%Y, %H:%M:%S')} <br><br>")
|
|
177
170
|
f.write(f"{RUN_DUR}: {str(duration).split('.')[0]} <br><br>")
|
|
178
171
|
f.write(f"{CERT_VER}: {CERT_VERSION} <br><br>")
|
|
179
|
-
if
|
|
180
|
-
f.write(f"{
|
|
181
|
-
f.write(f"{
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
172
|
+
if test and test.dut_is_gateway():
|
|
173
|
+
f.write(f"{GATEWAY} ID: {test.dut.id_str} <br><br>")
|
|
174
|
+
f.write(f"{GATEWAY} {SUP_API_VER}: {test.dut.gw_api_version} <br><br>")
|
|
175
|
+
if test.dut_is_combo():
|
|
176
|
+
f.write(f"{BRG} {BLE_MAC_ADDRESS}: {test.dut.internal_brg.id_str} <br><br>")
|
|
177
|
+
f.write(f"{BRG} {BLE_VER}: {test.dut.internal_brg.version} <br><br>")
|
|
178
|
+
if test.dut_is_bridge():
|
|
179
|
+
f.write(f"{BRG} {BLE_MAC_ADDRESS}: {test.dut.id_str} <br><br>")
|
|
180
|
+
f.write(f"{BRG} {BLE_VER}: {test.dut.version} <br><br>")
|
|
181
|
+
if test.tester:
|
|
182
|
+
f.write(f"{SIM} {BLE_MAC_ADDRESS}: {test.tester.internal_brg.id_str} <br><br>")
|
|
183
|
+
f.write(f"{SIM} {BLE_VER}: {test.tester.internal_brg.version} <br><br>")
|
|
184
|
+
|
|
185
185
|
f.write(tabulate.tabulate([[len(tests)-(failures+skipped), skipped, failures, len(tests)]], headers=["PASSED", "SKIPPED", "FAILED", "TOTAL"], tablefmt="html"))
|
|
186
186
|
f.write(generate_tests_table(tests, html=True))
|
|
187
187
|
f.write("<br><br>")
|
|
@@ -243,20 +243,26 @@ def generate_results_files(dut=None, tester=None, html=True, pdf=True, failures=
|
|
|
243
243
|
hdr_page.append(Paragraph(f"{RUN_DUR}: {str(duration).split('.')[0]}", bold_text_style))
|
|
244
244
|
hdr_page.append(Paragraph(f"{CERT_VER}: {CERT_VERSION}", bold_text_style))
|
|
245
245
|
hdr_page.append(Spacer(1, 10))
|
|
246
|
-
if
|
|
246
|
+
if test:
|
|
247
247
|
hdr_page.append(Paragraph(f"<u>{TESTED_DEVICE_INFO}:</u>", bold_text_style))
|
|
248
|
-
|
|
249
|
-
|
|
248
|
+
if test.dut_is_gateway():
|
|
249
|
+
hdr_page.append(Paragraph(f"{GATEWAY} ID: {test.dut.id_str}", bold_text_style))
|
|
250
|
+
hdr_page.append(Paragraph(f"{GATEWAY} {SUP_API_VER}: {test.dut.gw_api_version}", bold_text_style))
|
|
251
|
+
if test.dut_is_combo() or test.dut_is_bridge():
|
|
252
|
+
brg = test.dut.internal_brg if test.dut_is_combo() else test.dut
|
|
253
|
+
hdr_page.append(Paragraph(f"{BRG} {BLE_MAC_ADDRESS}: {brg.id_str}", bold_text_style))
|
|
250
254
|
hdr_page.append(Paragraph(f"{BRG} {BOARD_TYPE}: {ag.BOARD_TYPES_LIST[brg.board_type]}", bold_text_style))
|
|
251
255
|
hdr_page.append(Paragraph(f"{BRG} {BLE_VER}: {brg.version}", bold_text_style))
|
|
252
256
|
hdr_page.append(Paragraph(f"{BRG} {SUP_API_VER}: {brg.api_version}", bold_text_style))
|
|
257
|
+
hdr_page.append(Spacer(1, 10))
|
|
258
|
+
|
|
259
|
+
# In wlt-cert-reg there is no tester
|
|
260
|
+
if test.tester:
|
|
261
|
+
hdr_page.append(Paragraph(f"<u>{TESTING_DEVICE_INFO}:</u>", bold_text_style))
|
|
262
|
+
hdr_page.append(Paragraph(f"{SIM} {BLE_MAC_ADDRESS}: {test.tester.internal_brg.id_str}", bold_text_style))
|
|
263
|
+
hdr_page.append(Paragraph(f"{SIM} {BOARD_TYPE}: {ag.BOARD_TYPES_LIST[test.tester.internal_brg.board_type]}", bold_text_style))
|
|
264
|
+
hdr_page.append(Paragraph(f"{SIM} {BLE_VER}: {test.tester.internal_brg.version}", bold_text_style))
|
|
253
265
|
hdr_page.append(Spacer(1, 10))
|
|
254
|
-
if internal_brg:
|
|
255
|
-
hdr_page.append(Paragraph(f"<u>{TESTING_DEVICE_INFO}:</u>", bold_text_style))
|
|
256
|
-
hdr_page.append(Paragraph(f"{SIM} {BLE_MAC_ADDRESS}: {internal_brg.id_str}", bold_text_style))
|
|
257
|
-
hdr_page.append(Paragraph(f"{SIM} {BOARD_TYPE}: {ag.BOARD_TYPES_LIST[internal_brg.board_type]}", bold_text_style))
|
|
258
|
-
hdr_page.append(Paragraph(f"{SIM} {BLE_VER}: {internal_brg.version}", bold_text_style))
|
|
259
|
-
hdr_page.append(Paragraph(f"{SIM} {SUP_API_VER}: {internal_brg.api_version}", bold_text_style))
|
|
260
266
|
notes_file_path = os.path.join(ARTIFACTS_DIR, RESULT_NOTES_FILE)
|
|
261
267
|
if os.path.exists(notes_file_path):
|
|
262
268
|
hdr_page.append(Paragraph(f"<u>{ADD_INFO}:</u>", bold_text_style))
|
|
@@ -340,8 +346,12 @@ def generate_results_files(dut=None, tester=None, html=True, pdf=True, failures=
|
|
|
340
346
|
import io
|
|
341
347
|
from botocore.exceptions import ClientError
|
|
342
348
|
|
|
343
|
-
|
|
344
|
-
|
|
349
|
+
if test:
|
|
350
|
+
device_id = f"{test.dut.id_str}:{test.dut.internal_brg.id_str}" if test.dut_is_combo() else test.dut.id_str
|
|
351
|
+
version = test.dut.internal_brg.version if test.dut_is_combo() else test.dut.version
|
|
352
|
+
else:
|
|
353
|
+
device_id = "NO_ID"
|
|
354
|
+
version = "0.0.0"
|
|
345
355
|
json_data = {
|
|
346
356
|
"setup_name": os.environ['PIPELINE_NAME'],
|
|
347
357
|
"device_id": device_id,
|
|
@@ -26,10 +26,6 @@ ORIGINAL_AG_FILE = "wlt_types_ag.py"
|
|
|
26
26
|
TEST_MODULES_MAP = {"calibration": ag.MODULE_CALIBRATION, "datapath": ag.MODULE_DATAPATH, "energy2400": ag.MODULE_ENERGY_2400, "energy_sub1g": ag.MODULE_ENERGY_SUB1G,
|
|
27
27
|
"pwr_mgmt": ag.MODULE_PWR_MGMT, "sensors": ag.MODULE_EXT_SENSORS, "custom": ag.MODULE_CUSTOM}
|
|
28
28
|
|
|
29
|
-
# Used when mac is not really important for the test (e.g: gw_sim) or to randomize pkt data
|
|
30
|
-
def get_random_hex_str(len=12):
|
|
31
|
-
return ''.join([random.choice('0123456789ABCDEF') for i in range(len)])
|
|
32
|
-
|
|
33
29
|
def module2name(module_id):
|
|
34
30
|
for k, v in TEST_MODULES_MAP.items():
|
|
35
31
|
if module_id == v:
|
|
@@ -308,6 +304,8 @@ class Bridge:
|
|
|
308
304
|
self.cfg_hash = interface_pkt.cfg_hash if interface_pkt else cfg_hash
|
|
309
305
|
self.api_version = interface_pkt.api_version if interface_pkt else api_version
|
|
310
306
|
if import_defs:
|
|
307
|
+
if self.board_type >= len(ag.BOARD_TYPES_LIST):
|
|
308
|
+
handle_error(f"ERROR: Unknown board type {self.board_type} for bridge {self.id_str}!", datetime.datetime.now())
|
|
311
309
|
self.defines_file_name = f'{ag.BOARD_TYPES_LIST[self.board_type]}_defines.cfg'
|
|
312
310
|
overwrite_dict = {}
|
|
313
311
|
# Overwrite auto-generated defines for the specific bridge
|
|
@@ -388,7 +386,7 @@ def ut_prep_brg(args, start_time, tester, brg_id, tester_flag=False, validation_
|
|
|
388
386
|
if args.latest or args.rc:
|
|
389
387
|
return handle_prep_brg_for_latest(test, interface, brg_id, start_time)
|
|
390
388
|
elif test.rc == TEST_FAILED:
|
|
391
|
-
error = f"ERROR: Didn't get ModuleIfV{test.active_brg.api_version} from BRG:{brg.id_str}
|
|
389
|
+
error = f"ERROR: Didn't get ModuleIfV{test.active_brg.api_version} from BRG:{brg.id_str}!\n Check that the brg responded with the correct module"
|
|
392
390
|
handle_error(error, start_time)
|
|
393
391
|
version = f"{interface.major_ver}.{interface.minor_ver}.{interface.patch_ver}"
|
|
394
392
|
board_type = interface.board_type
|
|
@@ -465,7 +463,7 @@ class Gateway:
|
|
|
465
463
|
|
|
466
464
|
def get_tester_id(tester):
|
|
467
465
|
if not tester or tester == GW_SIM_PREFIX:
|
|
468
|
-
return f"GW_SIM_{get_random_hex_str()}"
|
|
466
|
+
return f"GW_SIM_{get_random_hex_str(12)}"
|
|
469
467
|
else:
|
|
470
468
|
# Allow tester to be specified as tester_id:ble_addr
|
|
471
469
|
if ':' in tester:
|
|
@@ -515,16 +513,16 @@ def prep_dut(args, tester, validation_schema, mqttc, start_time, upload_wait_tim
|
|
|
515
513
|
# Prepare gateway's internal BRG
|
|
516
514
|
if brg_flag(validation_schema):
|
|
517
515
|
dut.internal_brg = ut_prep_brg(args, start_time, tester=test.dut, brg_id=args.combo_ble_addr, validation_schema=validation_schema['modules'])
|
|
518
|
-
if dut.internal_brg.api_version
|
|
519
|
-
|
|
516
|
+
if dut.internal_brg.api_version < API_OLDEST_SUPPORTED_VERSION:
|
|
517
|
+
handle_error(f"ERROR: DUT internal brg FW api_version={dut.internal_brg.api_version} is lower then the oldest supported = {API_OLDEST_SUPPORTED_VERSION}! Please upgrade the internal brg FW!", start_time)
|
|
520
518
|
# Return Gateway object
|
|
521
519
|
return dut
|
|
522
520
|
|
|
523
521
|
elif brg_flag(validation_schema):
|
|
524
522
|
# Prepare standalone bridge using prepared tester
|
|
525
523
|
brg = ut_prep_brg(args, start_time, tester=tester, brg_id=args.dut, validation_schema=validation_schema['modules'])
|
|
526
|
-
if brg.api_version
|
|
527
|
-
handle_error(f"ERROR: DUT FW api_version={brg.api_version}
|
|
524
|
+
if brg.api_version < API_OLDEST_SUPPORTED_VERSION:
|
|
525
|
+
handle_error(f"ERROR: DUT brg FW api_version={brg.api_version} is lower then the oldest supported = {API_OLDEST_SUPPORTED_VERSION}! Please upgrade the brg FW!", start_time)
|
|
528
526
|
return brg
|
|
529
527
|
|
|
530
528
|
|
|
@@ -613,6 +611,7 @@ def prep_gw_info_action(test, start_time, brg_flag, target):
|
|
|
613
611
|
gw.gw_version = {BLE_VERSION : info[BLE_VERSION], WIFI_VERSION : info[WIFI_VERSION]}
|
|
614
612
|
if brg_flag and BLE_MAC_ADDR in info:
|
|
615
613
|
internal_brg_mac_addr = info[BLE_MAC_ADDR]
|
|
614
|
+
# For internal use only in versions update test
|
|
616
615
|
if GW_API_VERSION in info:
|
|
617
616
|
gw.gw_api_version = info[GW_API_VERSION]
|
|
618
617
|
|