nccgroup / BLESuite

BLESuite is a Python package that provides an easier way to test Bluetooth Low Energy (BLE) device
MIT License
180 stars 40 forks source link

Various issues #7

Open parkerlreed opened 5 years ago

parkerlreed commented 5 years ago

Using pyshark-legacy since newest pyshark doesn't support Python 2...

[parker@stealth BLESuite]$ ble-replay -p ~/btsnoop_hci.log -of replaydata.json
loading file
Btsnoop capture file version 1, type 1002
loading file
Btsnoop capture file version 1, type 1002
[parker@stealth BLESuite]$ cat replaydata.json 
[parker@stealth BLESuite]$ 

Everything seems to run twice and I can't get my hci log converted to the readable format.

Does interface want the hci0 or MAC address? I try both and get a similar error

[parker@stealth BLESuite]$ ble-replay -i hci0 -d 70:26:05:CF:67:25  -r -p btsnoop_hci.log 
loading file
Error: 

Traceback (most recent call last):
  File "/usr/bin/ble-replay", line 7, in <module>
    import blesuite.cli.ble_replay as ble_replay
  File "/usr/lib/python2.7/site-packages/blesuite/cli/ble_replay.py", line 88, in <module>
    main()
  File "/usr/lib/python2.7/site-packages/blesuite/cli/ble_replay.py", line 78, in main
    blesuite.replay.util.gatt_writes(int(args.iface), args.address, args.address_type, replay_data,
ValueError: invalid literal for int() with base 10: 'hci0'
[parker@stealth BLESuite]$ ble-replay -i 9C:B6:D0:0E:0D:CE -d 70:26:05:CF:67:25  -r -p btsnoop_hci.log 
loading file
Error: 

Traceback (most recent call last):
  File "/usr/bin/ble-replay", line 7, in <module>
    import blesuite.cli.ble_replay as ble_replay
  File "/usr/lib/python2.7/site-packages/blesuite/cli/ble_replay.py", line 88, in <module>
    main()
  File "/usr/lib/python2.7/site-packages/blesuite/cli/ble_replay.py", line 78, in main
    blesuite.replay.util.gatt_writes(int(args.iface), args.address, args.address_type, replay_data,
ValueError: invalid literal for int() with base 10: '9C:B6:D0:0E:0D:CE'
parkerlreed commented 5 years ago

Ok I see device was expecting just 0. Tried that and it seems to try to process but has an immediate loading file error when starting.

https://gist.github.com/parkerlreed/03157482e62abf3277ae881c288ebd13

parkerlreed commented 5 years ago

Ok user error for the file load. Wasn't in the current folder. I thought it was based on the feedback from the device.

Still seems to be doing the running twice thing.