This article provide help about how to use the STM32 Sniffer for Bluetooth® LE with Wireshark. It is supposed that you've already installed the sniffer, if it is not the case, you can follow this guide.
1. Starting the capture
Plug your sniffer board and open Wireshark.
1.1. Optional configuration
- In Wireshark, click on the wheel on the left of the STM32 sniffer interface to open the interface configuration menu.
- The channel index parameter is the channel on which the sniffer will listen when started. It can be changed later on the fly. By default it is channel index 39.
- This is the channel index, not the frequency index. e.g (primary adverstising channels indexes are 37, 38 and 39).
Optional parameter |
---|
1.2. Launching the capture
To start the capture:
or
Optional parameter |
---|
1.3. Sniffer started
You should now see the advertising packets on the channel you configured.
Optional parameter |
---|
2. Following a connection
Once the sniffer is started is reports advertising, scan requests and scan requests of all devices. You can then set the BD address of your target device that you want to follow when a connection to it occur.
Setting a target to follow |
---|
Now you should only see:
- Advertising and scan responses packets from the target
- Scan requests to the target
- Connection packets from and to the target
Target set |
---|
If after setting the target there is no more packets incoming either:
- There is no device with this BD address advertising on this channel
- The sniffer has not received the command, set again the target (you will need to make a change to be able to apply changes. Just delete the last number and reenter it)
Now if a device connect to your target and the sniffer intercept the CONNECT_IND packet you will start to see the communications between the two devices.
Connection intercepted |
---|
Now you have some additional data:
- The direction column indicates the direction of the packets
- The color of the lines is alternating for each connection event
If the connection is terminated or if the sniffer loose it, it will return to the advertising channel you have configured before.