thotro/arduino-dw1000

Refresh Rate Issue

Opened this issue · 0 comments

Step 1: What do you want?

  • Report an issue.
  • Improve code (and need help).

Step 2: Describe your environment

  • Arduino IDE version or Toolchain: Arduino IDE 1.8.13
  • dw1000 Library version: 2017 modified for radino32
  • Arduino device: radino32 dw1000

Step 3: Describe the problem

Refresh Rate Maximum is only at 2 Hertz.
Only every 0,5s is a measurement.

Relevant Code:

#include "IC_DW1000_Ranging_local.h"
#include <SPI.h>

#define def_short_address 0x2020
#define PIN_LED 13
#define usedAntennaDelay 32850UL

void setup() {
if (PIN_LED != 0xFF) pinLow(PIN_LED, OUTPUT);

startWatchdog();
DW1000Ranging.initCommunication();
DW1000Ranging.attachNewRange(newRange_anchor);
DW1000Ranging.attachMeasureComplete(measureComplete);
DW1000Ranging.startAsTag("7D:00:22:EA:82:60:3B:9C", DW1000.MODE_IN_CIRCUIT_1, def_short_address, IC_DW_USB_STICK_ANC);
DW1000.setManualTxPower(400);
DW1000.setAntennaDelay(usedAntennaDelay);
DW1000Ranging.lastInterruptTime = millis();
}

void loop() {
reloadWatchdog();
DW1000Ranging.dwloop();
}