summaryrefslogtreecommitdiff
path: root/system/tools/scripts
AgeCommit message (Collapse)Author
2025-03-07system/common: Remove the BluetoothMetricsLogger helper Henri Chataing
BluetoothMetricsLogger produces metrics logs that are packaged into a protobuf binary using the format system/gd/proto/metrics/bluetooth.proto This legacy logging method is no longer use in practical application and needs to be removed Bug: 401588157 Test: m com.android.bt Flag: EXEMPT, dead code removal Change-Id: I827079276082460eceb9bee728ef25771bc5b5db
2023-08-04Remove obsolete system/tools/scripts/change_types.sh David Duarte
Bug: 294615573 Test: mmm packages/modules/Bluetooth Change-Id: I82836ee5b12ee4df087a7aa69b3fa2eab576b760
2023-04-25Add more context and update metadata support Alice Kuo
1. add more context support that are supported in bt stack 2. support update metadata to re-write the metadata setting during stream, and contain the information in the file title Bug: 279356092 Test: verified with sw path audio dump Change-Id: I93d1c2e71fbe9d3c54483c547b946ca2a3981480
2023-04-24Add EATT support for dump_le_audio.py tool Alice Kuo
1. The previous version only support ATT packet parsing. Add the mechanism to get the cid for EATT, and filter the EATT packet to get the codec information 2. Modify the lint error together Bug: 279356092 Test: verified with EATT supported headset via SW path audio dump Change-Id: I46d18fbc3236857fe1710980c76e4dda47af3462
2022-10-04Add broadcast support on ISO dump tool Alice Kuo
Support Broadcast stream audio data dump from hci log Bug: 229346816 Test: python3 ./dump_le_audio.py BTSNOOP.cfa -v --header Change-Id: Ia8e535daa8033adef37d57fc1da0c50752b81dd1
2022-05-16Re-format the dump le audio.py Alice Kuo
Bug: 232731251 Test: ./dump_le_audio.py BTSNOOP.cfa -v --header Change-Id: I381652d69d6e09cf1e11747116708c87ba988898
2022-05-16Only parse ATT_READ_BY_TYPE_RSP for the charactertistic type Alice Kuo
We parse ATT_READ_BY_TYPE_RSP packet to know the ASE control point UUID, so ignore the other packet and avoid the tool crash as the packer length shorted than expected Bug: 232731251 Test: ./dump_le_audio.py BTSNOOP.cfa -v --header Change-Id: I314e8b7ff0e205a42f1f125c48b96a966191bed7
2022-04-02Update btsnooz to use python3 Chris Manton
And also provide solution when parsing fails Bug: 176292237 Test: gd/cert/run Tag: #refactor BYPASS_LONG_LINES_REASON: Bluetooth likes 120 lines Change-Id: I75cd4445cb98d5291eb2769f6797dd8e5ab31685
2022-03-09Fix crash as using ISO dump tool with python3 Alice Kuo
Bug: 204320094 Test: extract iso data from le audio media log Change-Id: Ie46f32b1613ed5f4b7bf79a84c53e195ef352a29
2022-01-27Merge "Change pre-upload hook check order for non python upload" William Escande
2022-01-22Minor improvement about the tool document and the error msg Alice Kuo
The patch includes 1. Add the document for the ase_handle assignment feature 2. Print "The iso data is empty" as the iso sdu data length is zero, it could be useful to debug the audio issue Bug: 204320094 Bug: 150670922 Test: dump ISO data with btsnoop contains the iso sdu data empty issue Change-Id: Ic0857d0e21a568ecd52c98a15f5820a8161d7a14
2022-01-19Change pre-upload hook check order for non python upload William Escande
It's currently not possible to run the pre-upload hook without having to source the build/envsetup.sh. With this change it will be allowed as long as there is no python files modified. Test: Upload this change (it's a python file) Change-Id: I0a27c777b0a0aa58d48e42650063f62cba0a4027
2022-01-19Support ase attribute handle assignment as dump ISO data Alice Kuo
Some hci log file didn't contain the pairing process, the tool could not get the correct codec paramter by parsing the packet automatically due to the ASE control point attribute handle missing. Add the feature to make it eaiser. The user can assign the ASE attibute handle used for parsing. The tool could based on it to get the correct codec parameter and generate the header for the decoder Bug: 200748923 Bug: 150670922 Test: dump ISO data with ase handle assign on the log without pairing process Change-Id: I67024709c37314a0f16e471368cfd9872c35f79b
2021-10-07Improve the document for the dump le audio tool Alice Kuo
Bug: 150670922 Bug: 200748923 Test: run dump_le_audio -h Change-Id: I7c6e3c16360f755b1ef1d196bee31d169981d42f
2021-10-06Add the header in the front of the dump data for LC3.TS v1.0.3 format Alice Kuo
The commit contains the following change, 1. Add the headeer for the LC3.TS - LC3 Conformance Interoperability Test Software Release V1.0.3 2. Correct the document 3. Fix the minor naming error Bug: 150670922 Bug: 200748923 Test: Parse the btsnoop with LE audio streo media case, use the TS to decoded the dump data to wav files, use the player to confirm the audio Change-Id: I70a47fc58ad506513abd191f9055650c109695b3
2021-09-22Add the python tool to dump le audio data from btsnoop Alice Kuo
Usage: ./dump_leaudio.py BTSNOOP.fille [-v] -v to enable the verbose log The supported specficiation: ASCS_1.0 PACS_1.0 BAP_1.0 The format: Generates a audio dump file where each frame consists of a two-byte frame length information and the coded frame Bug: 200748923 Bug: 150670922 Test: verify with single & multiple media/ringtone/conversaion btsnoop Change-Id: I7a973864276a61270051dff07c44e2366335a558
2021-02-23Fix the delta_time_ms types mismtach in btsnooz.py Alice Kuo
The delta_time_ms field in btif_debug_btsnoop.h is 32 bits. The offset count for 64 bits, and cause the decoder error. Change the offset back for 32 bits. Bug: 175283029 Test: ./btsnooz.py bugreport-WXYZ.txt Change-Id: I28324c4ff33ab817dbad5c813616a8e8c994ff2a
2021-01-18Add ISO type support on btsnooz.py script Alice Kuo
Support to decode the ISO packet from the compressed btsnoop in bugreport. Bug: 150670922 Bug: 177616528 Test: btsnooz.py bugreport-*.txt which contain ISO traffic. Tag: #feature Change-Id: I070ec3023ed2ef65c3d1fce90dcfe2b9d695a89f
2021-01-13Fix v2 format decoding in btsnooz.py Neil Mayhew
The delta_time_ms field now seems to be 64 bits instead of 32. Without this change, dumps fail to decode and the script exits with a TypeError because type_to_hci encounters an unknown packet type. Bug: 175283029 Test: ./btsnooz.py bugreport-WXYZ.txt Tag: #refactor Sponsor: optedoblivion@ Change-Id: Ib893ee63abacf5335a4cbabb1dbdfc1702da77e6
2020-10-20Inclusive Language Updates Martin Brabham
slave -> peripheral SLAVE -> PERIPHERAL Slave -> Peripheral BYPASS_INCLUSIVE_LANGUAGE_REASON=required_to_explain_the_update Bug: 170342881 Tag: #refactor Test: cert/run --host Test: atest --host bluetooth_test_common Test: atest --host bluetooth_test_gd Test: atest net_test_btif Change-Id: I4a3cccc0c1d182f172a21a6c70d569e5a89a5916 Merged-In: I4a3cccc0c1d182f172a21a6c70d569e5a89a5916
2020-10-14Inclusive Language Updates Martin Brabham
master -> central MASTER -> CENTRAL Master -> Central BYPASS_INCLUSIVE_LANGUAGE_REASON=required to explain the update Bug: 170342881 Tag: #refactor Test: cert/run --host Test: atest --host bluetooth_test_common Test: atest --host bluetooth_test_gd Test: atest net_test_btif Change-Id: I861ca756f04c06547ee9cb580029404308c678f2 Merged-In: I861ca756f04c06547ee9cb580029404308c678f2
2020-05-18Format python files with extended line length now allowed Zach Johnson
Bug: 156858180 Test: cert/run --host Tag: #gd-refactor Change-Id: I45ab86f366316246f14b24dd83f66684badf22e0
2020-04-24Exclude deleted Python files from YAPF checker Jack He
Test: upload a commit with deleted Python file Change-Id: I9cbf427eeafec992d1a8ecc0030ec5effcf9f3de
2019-12-11Python: format all Python files in system/bt using YAPF Jack He
python3 yapf -p -i $(git ls-tree --name-only -r aosp/master | grep "\.py") Bug: 146016811 Test: run Python tests Change-Id: Ic5fe6a21151d1abc8eb013f8c8070ba8238a5249
2019-12-11Add Python style checker to system/bt Jack He
* Based on Google style and ensure 4 spaces are used for indentation * http://google.github.io/styleguide/pyguide.html Bug: 146016811 Test: upload CLs Change-Id: I27b9232d59e9e9bd59ca1414ef6f9db85c41a808
2019-10-24Add tool for live btsnoop logging with Frontline BT sniffer (FTS) Vishwanath KM
* This script supports Bluetooth Virtual Sniffing via Live Import feature of Frontline Bluetooth Sniffer(FTS). * It uses APIs from LiveImportAPI.dll in FTS path to communicate with FTS sniffer and inject HCI packets for live HCI sniffing
2019-05-17Hearing Aid Dump Audio Tool: Add dump debug buffer feature weichinweng
Add dump HearingAid debug buffer feature to let the HearingAid debug information dump to debug file and make it readable. Bug: 130781854 Test: ./dump_hearingaid_audio.py -d true btsnoop_hci.log ./dump_hearingaid_audio.py -sd true btsnoop_hci.log Change-Id: I150fd897e6f197d5b853554734926ad613de4e6b
2019-03-11Hearing Aid Dump Audio Tool: Add No Start Cmd feature weichinweng
When the HCI Snoop logs wraparound, the Hearing Aid Audio Control Command "Start" is lost. For the case, we can enable No Start Cmd feature to set a fake "Start" to extract audio data. Bug: 127745964 Test: ./dump_hearingaid_audio.py -c1 1 -c2 3 -ns true btsnoop_hci.log Change-Id: Id7f67da0d5476faf38352ab57339fed8e358bac6
2019-01-29Hearing Aid: Add python script to dump audio data to file weichinweng
Bug: 121005659 Test: ./dump_hearingaid_audio.py btsnoop_hci.log ./dump_hearingaid_audio.py -f folder btsnoop_hci.log ./dump_hearingaid_audio.py -f folder -c1 1 -c2 3 btsnoop_hci.log ./dump_hearingaid_audio.py -f folder -a 121 btsnoop_hci.log Change-Id: I304531ecb5c5bd6cfc264130176d26acc60a64c2
2018-07-17Metrics: Add python script to dump metrics into ASCII format Jack He
Test: make, ./dump_metrics_ascii.py proto/bluetooth/metrics/bluetooth.proto Change-Id: Ie671fa2c2ceb9f93ed62495b592a2cf9d69ff41b
2017-01-04scripts: modify change_types.sh to skip matching "<data type>_" Ruchi Kandoi
Script erroronously modifies UINT8_TO_BE_STREAM() to uint8_t_TO_BE_STREAM(). Modidy the script to prevent that. Test: Manual; Run the script on system/nfc Change-Id: I9e130b8eb79e400282233fad7da206b4bb1301af Signed-off-by: Ruchi Kandoi <kandoiruchi@google.com>
2016-08-05Use standard types, consistent ifdef style everywhere Marie Janssen
Remove the typedefs in stack/include/bt_types.h Use standard types everywhere. Use standard style for #if statements: - #if (VAR_NAME == TRUE) - #if (VAR_NAME1 == TRUE && VAR_NAME2 == TRUE) Use __func__ instead of __FUNCTION__ Fix some debug statements to use __func__ Update script to be less disruptive to aligned assignment blocks. Change-Id: I8f8f068e6c26ce74fd3b3707e1e31fd0b919cdd0
2016-04-04Fix btsnooz.py multi-line base64 decoding Andre Eisenbach
Change-Id: Ie915c52d8a7eada10f68999c40a2b50b35f640e2
2016-03-01Btsnooz doesn't find snooplog sometimes Ajay Panicker
In the bugreport in b/27274486 comment #11, the line indicating the beginning of BTSNOOP LOGS was slightly indented thus causing btsnooz to not find the beginning of the log. Bug: 27419027 Change-Id: I3b88e6a3f6f2d6c4d3cbbadb0a93cbd7965f56c8
2016-02-23Add tool to extract and view snooz logs from a bugreport Ajay Panicker
Change-Id: I3893d094a1b1dd7853016d1f539f8998cdc84833
2016-02-01Assume input from /dev/stdin if no argument provided to btsnooz.py. Sharvil Nanavati
Change-Id: I54bd137e67eb1fc959663189bcdaac4690c2c645
2016-01-21Move btsnooz.py script from Android Wear to the BT stack project. Sharvil Nanavati
Change-Id: I8368820b5ed9325d2c3b82885b9fe934c6bc87ca
2016-01-07Add script to change data types to native C types Andre Eisenbach
Please see source code for usage information and application. Bug: 22948224 Change-Id: Ia2dbd618ddcdf13abf3c63d4649147f400e00cfe