DW1000 Collisions

Hi All,
Maybe someone saw this collision problem…

I use 3-5 tags with frequency of 6-7 Hz and I see a lot of missed messages. If I put only one tag I almost don’t see any missed message for a while.
Tags work as sender and anchor works as receiver. I don’t use TWR method, the communication is one way - from tag to anchor.

The computing time after interrupt is about 2-4 ms. Is it too much?

Thank you in advance!

2-4 ms per interrupt? Yes that’s a little high.
Interrupt time should be in the handful of us region, it sounds like your interrupt is taking a couple of hundred times longer than it should. Obviously it will depend a little on how fast your CPU is but for me the critical things were how much data I read from the DW1000 and how fast I run the SPI bus. Obviously if you want to read lots of registers at a low clock speed then it’s going to take a lot longer.
Eliminate any unnecessary reads, crank the bus speed up to the point where things crash and then back it off a little. Unless you’ve messed up the board design you should be able to run the SPI bus at 10 MHz as an absolute minimum.

Thank you!

I run SPI at Python on Raspberry…
I use 20Mhz clock speed for SPI.
Should compilation solve the problem?

There’s where you problem is. Linux is terrible at real time interrupt handling and python is slow.
If you want things to run quickly run a real time OS (or even better no OS) and compiled code.

Wow, thank you so much!
I see two options to fix it.
One is to connect the DW1000 to arduino and another is to continue using raspberry but to compile the code.
Is there some tips for beginners what also should I improve if I want to use RPI directly with DW1000? Some settings in OS? Some preference for interrupts? Is there such thing?
Thank you again!

Can I get the register info through the UART mode?
It means, can I connect RPI with DWM1000 and use UART protocol. Can it solve the problem?

MLEV, I’m not sure what you mean, the dwm1000 does not have UART intergface, only spi.

Using a raspberry pi as a host for DWM1000 will be too slow for a large majority of applications I’m afraid.

Ideally you need a HOST mcu connected to DWM1000 over SPI and running application with an RTOS or bare metal, as suggested by AndyA.


Personally I started off prototyping using an mbed board. Basic DW1000 drivers are available but about all they do is set up register access to the device.
It gives you Arduino like bare metal real time performance but with a lot more CPU power and not using some horrible almost c but not quite c programming language.
I ran bare metal but an RTOS is available for them.

I have been using 4 Anchor and 1 Tag for while and running SPI on RPi through Arduino and its working fine. I want my communication only one way can you please guide me on that.

Sorry, I saw you message only now.
What do you mean as one=way communication?