Tutorial: How to Use DW3 QM33 SDK for One to Many FiRa Ranging

Last Updated: December 30, 2024

Prerequisites

Background

It is often required to be able to range to multiple devices in one session. This is possible using FiRa One to Many (O2M) which supports up to 8 responders in 1 session.

Here we will review setting up FiRa O2M using both the pre-built CLI and UCI examples from the SDK.

Example Setup

For the purposes of this tutorial, we are using 1x QM33120WDK1 (2 boards) and 1x DWM3001CDK for a total of 3 boards.


CLI

This section shows how to do O2M ranging with 3 boards using the Command Line Interface (CLI) application.

Steps

  1. Flash each board with the corresponding prebuilt CLI example from the SDK. This is found in SDK\Binaries. Refer to the respective Developer Manual found in SDK\Documentation\Developer Manual referring to section 4.4.2 Flashing the development kit.
  2. Open a serial terminal corresponding to each board.
  3. Board 1: initf -multi -paddr=[1,2]
  4. Board 2: respf -multi -addr=1
  5. Board 3: respf -multi -addr=2

Example

The following screenshot involves the use of 3 boards as described above using TeraTerm as the serial port emulator.

Tips

  1. Connect each board one at a time to the computer to make sure you are correctly programming and identifying the serial port for each board.
  2. ? will give a list of all supported commands in the CLI. help followed by the command will give a brief description of the command and its parameters, e.g., help initf.
  3. Running diag 1 before starting ranging will enable diagnostic mode to enable printing of RSSI and other parameters.

UCI

This section how to do O2M ranging with 3 boards using the UWB Command Interface (UCI) application. The UCI application can be run with the QorvoOne GUI (found in SDK\Tools\GUI) or with the UWB Qorvo Tools (UQT, found in SDK\Tools\uwb-qorvo-tools). Here we focus on the UQT method as the GUI method is relatively straightforward.

  1. Flash each board with the corresponding prebuilt UCI example from the SDK. This is found in SDK\Binaries. Refer to the respective Developer Manual found in SDK\Documentation\Developer Manual referring to section 4.4.2 Flashing the development kit.
  2. Follow section 1.2 and 1.3 in UWB-Qorvo-Tools-guide.pdf found in SDK\Tools\uwb-qorvo-tools to setup environment for UQT.
  3. Open a shell that you will use for each board in the uwb-qorvo-tools folder.
  4. In each shell, activate the Python virtual environment (see section 1.3.2 for more details).
  5. In each shell, set the default port corresponding to the serial port of the board you wish to use with that shell (see section 1.4.1 for more details).
  6. Board 1: run_fira_twr -t -1 --node onetomany --dest-mac '[0x1, 0x2]' --n_controlees 2
  7. Board 2: run_fira_twr -t -1 --node onetomany --mac 0x1 --controlee
  8. Board 3: run_fira_twr -t -1 --node onetomany --mac 0x2 --controlee

Note The -t -1 option will let the scripts run forever until the return/enter key is pressed.

Example

The following screenshots involve the use of 3 boards as described above using Windows PowerShell.

Tips

  1. Use a release of Python 3.10. The latest release of 3.10 is 3.10.16 found here. We are not supporting newer (or older) versions of Python at this time.
  2. Make sure no other applications are using the serial ports. If you followed the CLI example earlier, the port would be the same so please disconnect the port from your serial terminal.
  3. mode command in Windows PowerShell lists the available serial ports.
  4. -h option with run_fira_twr (i.e., run_fira_twr -h) will print the help for the command including all of the parameters supported.

Closing

If you have a question regarding the tutorial here or you find that there is an issue with the steps, please reply in this thread. We also welcome any suggestions for other tutorial topics for the DW3 QM33 SDK.

Otherwise, please open a new topic with your question and reference this tutorial if needed in your post.

4 Likes

Hello, I have a question about the timing.
If I have one initiator and two responder, and if I set parameters like this:
Block duration: 200ms
Slot duration: 2400rstu (2ms)
Round duration: 25 slots (50ms)

Then, in initiator’s block, there will be two rounds for each responder like this


I wonder about the sequence of each slots.
([ SLOT 1 ] for round 1, [ SLOT 2 ] for round 2)
If the sequence looks like
[ SLOT 1 ][ SLOT 2 ][ SLOT 1 ][ SLOT 2 ] …
then, the two range data in one block are gathered simultaneously.
However, if the sequence looks like
[ SLOT 1 ][ SLOT 1 ][ SLOT 1 ] …[ SLOT 1 ] [ SLOT 2 ][ SLOT 2 ]…[ SLOT 2 ]
└───count: 25 (50ms)β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜β””β”€β”€β”€β”€count: 25 (50ms)β”€β”€β”€β”€β”˜
then, the two range data has a time gap of 50ms.

I want to make a 2D location estimating system, so I want to get simultaneous ranging result.