DWM3000EVB stops responding

Sorry @iMan , I don’t know why I didn’t see your previous message.

I’m based in Europe, not sure if a recommendation will work for you.
I would suggest you to create a new post for this, maybe others closer can help.
In the meantime I’ll ask Qorvo people for a recommendation in Asia or maybe in Europe that’s suitable for you.

Cheers!

A recommendation in Europe is fine

1 Like

Hello, @iMan!

I was recommended to check Qorvo partners, available here:

Please, let me know if it worked for you! Cheers!

1 Like

Thanks @carlos.silva

1 Like

Hi @iMan.

I am having the same problem that you described here. Did you ever found out what was making the board stop and reset?

Best Regards.

Sorry to hear that @joao.azevedo.trd , I didn’t find a solution yet, and when decided to out source the design and development, non of the partners is welling to accept it due to chip shortage. I hope that @carlos.silva revive the subject

Hello @iMan!

@joao.azevedo.trd NI on the device side has a known issue, which is a wrong GAP parameter not accepted by the iPhone, the result is that after 3 attempts at 30 seconds interval the BLE connection drops (BLE_GAP_EVT_ADV_SET_TERMINATED event, which reset the board).
The simple fix is to change the wrong parameter in ble.c:

#define MIN_CONN_INTERVAL                   MSEC_TO_UNITS(25, UNIT_1_25_MS)

However, @iMan had a different issue which we couldn’t find the root cause of. So if your board is resetting after 90s of TWR session, the above fix should work and you can keep the session as long as you want.

If it is a different issue, please share it here and let’s try to find out what is happening.

Best regards!

Hi @carlos.silva!

I think you are right and that I might have a different problem. I already added the fix you suggested, it was suggested in this previous question. However, I now have a different problem where the device freezes and crashes when the connection with the iPhone via UWB is bad but still happening.

00> Here
00> {"TWR": {"R":112,"a16":"0x4c39","S":"ERR","D cm":0}}
00> Here
00> Here
00> {"TWR": {"R":113,"a16":"0x4c39","S":"ERR","D cm":0}}
00> {"TWR": {"R":125,"a16":"0x4c39","S":"ERR","D cm":0}}
00> {"TWR": {"R":126,"a16":"0x4c39","S":"ERR","D cm":0}}
00> {"TWR": {"R":127,"a16":"0x4c39","S":"ERR","D cm":0}}
00> Here
00> {"TWR": {"R":128,"a16":"0x4c39","S":"OK","D cm":377}}
00> {"TWR": {"R":129,"a16":"0x4c39","S":"OK","D cm":376}}
00> {"TWR": {"R":130,"a16":"0x4c39","S":"OK","D cm":379}}
00> {"TWR": {"R":131,"a16":"0x4c39","S":"OK","D cm":386}}
00> {"TWR": {"R":132,"a16":"0x4c39","S":"OK","D cm":390}}
00> Application: Nearby Interaction Beta
00> Target: Tag3
00> OS: FreeRTOS
00> Version: 1.0.0-221012
00> DW3XXX Device Driver Version 06.00.00
00> MAC: R8.2.3_E
00> ACCESSORY_RANGING_ROLE: Responder
00> <info> app: Fast advertising.
00> Here
00> Here

I added a heartbeat task just to make it easier to visualize if the device froze, it prints “Here” every second, but it shouldn’t have an impact on the system. If you have any idea of what’s happening please share it, I would welcome the help.

Best Regards!

Hi @joao.azevedo.trd !

freezes and crashes when the connection with the iPhone via UWB is bad but still happening.

What causes the connection to be bad? Distance? Probably you’re having the same issue with BLE, ble events in ble.c→ble_evt_handler() will take actions:

BLE_GAP_EVT_DISCONNECTED: When it happens the event calls niq_stop_uwb(), which will stop the ongoing NI session. After that is not possible to resume the session but restart from the beginning.

BLE_GAP_EVT_ADV_SET_TERMINATED: This is the one that restarts the board. When the disconnection happens the APP_ADV_DURATION may have elapsed already, which makes the board restart right after BLE_GAP_EVT_DISCONNECTED.

You can avoid reset by setting APP_ADV_DURATION to zero, this way the board shall always advertise and the BLE_GAP_EVT_ADV_SET_TERMINATED shall never happen but, If you wanna keep the NI Session running while trying to reconnect BLE you’ll have to handle these events properly, also on the iPhone side.

Please let me know if I got this right!
Best regards!

Hi @carlos.silva

The cause of the bad connection seems to be obstacles in the line of sight between the tag and the iPhone (e.g. wooden doors, desks, and other office furniture). The measurement is running until the device freezes and reboots after 20 seconds or more, I tried both with prints and with debug to see if the code enters the ble_evt_handler() before freezing but I was not successful.

I already set APP_ADV_DURATION to zero, so that shouldn’t be the source of the problem.

Hi @joao.azevedo.trd!

Seems to be a big problem, it never happened to me to freeze and restart. The only changes to your code are the BLE fixes and heartbeat printing, right? Do you know how to reproduce this behavior? I would like to give this a try.

Unfortunately, on my side, disconnection tests run smoothly, if I lost UWB I can resume approaching the device, if I lost BLE the NI session terminates on both, iPhone and device, and I can start a new session.

Best regards!

Hi @carlos.silva,

Thank you for all your help so far.

I made a couple more changes to try to identify the source of this issue, I included a patch file with all changes I made code_changes.c (13.5 KB). The only change applied when I first detected the bug was the BLE fixes and the changes in the TxPower.

The simplest way I found to reproduce this behavior, is to connect the iPhone to the Tag and then put the iPhone inside a drawer module.

The BLE connection still occurs, but the UWB measurements fail from time to time.

Best Regards!

Hi @joao.azevedo.trd
Im not familiar with the apple NI. However from the UWB perspective there are a good reasons why you have a UWB issues.

  1. You should not connect the TN to the iphone via cable. The signal might go rather trough the cable surface that via the air (you might face multipath issues). Also the iphone and the TN should ne tbe placed on the same surface (ie table).

  2. Iphone as far I know have the antennas on its back (battery side) so you need to point the iphone at the device (at least a bit) or hold the iphone in the recommended (by Apple) position. So on your picture the TAG is above the LCD display where the antenna has almost zero (or very poor) performance. It is OK that you have UWB issues in this setup.

Cheers
JK