|
static void | begin (uint8_t irq, uint8_t rst=0xff) |
|
static void | select (uint8_t ss) |
|
static void | reselect (uint8_t ss) |
|
static void | end () |
|
static void | reset () |
|
static void | softReset () |
|
static void | getPrintableDeviceIdentifier (char msgBuffer[]) |
|
static void | getPrintableExtendedUniqueIdentifier (char msgBuffer[]) |
|
static void | getPrintableNetworkIdAndShortAddress (char msgBuffer[]) |
|
static void | getPrintableDeviceMode (char msgBuffer[]) |
|
static void | setNetworkId (uint16_t val) |
|
static void | setDeviceAddress (uint16_t val) |
|
static void | setEUI (char eui[]) |
|
static void | setEUI (byte eui[]) |
|
static void | setReceiverAutoReenable (boolean val) |
|
static void | setInterruptPolarity (boolean val) |
|
static void | suppressFrameCheck (boolean val) |
|
static void | setDataRate (byte rate) |
|
static void | setPulseFrequency (byte freq) |
|
static byte | getPulseFrequency () |
|
static void | setPreambleLength (byte prealen) |
|
static void | setChannel (byte channel) |
|
static void | setPreambleCode (byte preacode) |
|
static void | useSmartPower (boolean smartPower) |
|
static DW1000Time | setDelay (const DW1000Time &delay) |
|
static void | receivePermanently (boolean val) |
|
static void | setData (byte data[], uint16_t n) |
|
static void | setData (const String &data) |
|
static void | getData (byte data[], uint16_t n) |
|
static void | getData (String &data) |
|
static uint16_t | getDataLength () |
|
static void | getTransmitTimestamp (DW1000Time &time) |
|
static void | getReceiveTimestamp (DW1000Time &time) |
|
static void | getSystemTimestamp (DW1000Time &time) |
|
static void | getTransmitTimestamp (byte data[]) |
|
static void | getReceiveTimestamp (byte data[]) |
|
static void | getSystemTimestamp (byte data[]) |
|
static float | getReceivePower () |
|
static float | getFirstPathPower () |
|
static float | getReceiveQuality () |
|
static void | interruptOnSent (boolean val) |
|
static void | interruptOnReceived (boolean val) |
|
static void | interruptOnReceiveFailed (boolean val) |
|
static void | interruptOnReceiveTimeout (boolean val) |
|
static void | interruptOnReceiveTimestampAvailable (boolean val) |
|
static void | interruptOnAutomaticAcknowledgeTrigger (boolean val) |
|
static void | attachErrorHandler (void(*handleError)(void)) |
|
static void | attachSentHandler (void(*handleSent)(void)) |
|
static void | attachReceivedHandler (void(*handleReceived)(void)) |
|
static void | attachReceiveFailedHandler (void(*handleReceiveFailed)(void)) |
|
static void | attachReceiveTimeoutHandler (void(*handleReceiveTimeout)(void)) |
|
static void | attachReceiveTimestampAvailableHandler (void(*handleReceiveTimestampAvailable)(void)) |
|
static void | idle () |
|
static void | newConfiguration () |
|
static void | commitConfiguration () |
|
static void | newReceive () |
|
static void | startReceive () |
|
static void | newTransmit () |
|
static void | startTransmit () |
|
static void | enableMode (const byte mode[]) |
|
static void | setDefaults () |
|
static void | getPrettyBytes (byte cmd, uint16_t offset, char msgBuffer[], uint16_t n) |
|
static void | getPrettyBytes (byte data[], char msgBuffer[], uint16_t n) |
|
static uint8_t | nibbleFromChar (char c) |
|
static void | convertToByte (char string[], byte *eui_byte) |
|
static void | getTempAndVbat (float &temp, float &vbat) |
|
static void | handleInterrupt () |
|
static void | setFrameFilter (boolean val) |
|
static void | setFrameFilterBehaveCoordinator (boolean val) |
|
static void | setFrameFilterAllowBeacon (boolean val) |
|
static void | setFrameFilterAllowData (boolean val) |
|
static void | setFrameFilterAllowAcknowledgement (boolean val) |
|
static void | setFrameFilterAllowMAC (boolean val) |
|
static void | setFrameFilterAllowReserved (boolean val) |
|
static void | setDoubleBuffering (boolean val) |
|
static void | useExtendedFrameLength (boolean val) |
|
static void | waitForResponse (boolean val) |
|
static void | tune () |
|
static boolean | isReceiveTimestampAvailable () |
|
static boolean | isTransmitDone () |
|
static boolean | isReceiveDone () |
|
static boolean | isReceiveFailed () |
|
static boolean | isReceiveTimeout () |
|
static boolean | isClockProblem () |
|
static void | clearInterrupts () |
|
static void | clearAllStatus () |
|
static void | clearReceiveStatus () |
|
static void | clearReceiveTimestampAvailableStatus () |
|
static void | clearTransmitStatus () |
|
static void | readSystemEventStatusRegister () |
|
static void | readSystemConfigurationRegister () |
|
static void | writeSystemConfigurationRegister () |
|
static void | readNetworkIdAndDeviceAddress () |
|
static void | writeNetworkIdAndDeviceAddress () |
|
static void | readSystemEventMaskRegister () |
|
static void | writeSystemEventMaskRegister () |
|
static void | readChannelControlRegister () |
|
static void | writeChannelControlRegister () |
|
static void | readTransmitFrameControlRegister () |
|
static void | writeTransmitFrameControlRegister () |
|
static void | enableClock (byte clock) |
|
static void | manageLDE () |
|
static void | correctTimestamp (DW1000Time ×tamp) |
|
static void | readBytes (byte cmd, uint16_t offset, byte data[], uint16_t n) |
|
static void | readBytesOTP (uint16_t address, byte data[]) |
|
static void | writeByte (byte cmd, uint16_t offset, byte data) |
|
static void | writeBytes (byte cmd, uint16_t offset, byte data[], uint16_t n) |
|
static void | writeValueToBytes (byte data[], int32_t val, uint16_t n) |
|
static boolean | getBit (byte data[], uint16_t n, uint16_t bit) |
|
static void | setBit (byte data[], uint16_t n, uint16_t bit, boolean val) |
|
|
static constexpr byte | TRX_RATE_110KBPS = 0x00 |
|
static constexpr byte | TRX_RATE_850KBPS = 0x01 |
|
static constexpr byte | TRX_RATE_6800KBPS = 0x02 |
|
static constexpr byte | TX_PULSE_FREQ_16MHZ = 0x01 |
|
static constexpr byte | TX_PULSE_FREQ_64MHZ = 0x02 |
|
static constexpr byte | TX_PREAMBLE_LEN_64 = 0x01 |
|
static constexpr byte | TX_PREAMBLE_LEN_128 = 0x05 |
|
static constexpr byte | TX_PREAMBLE_LEN_256 = 0x09 |
|
static constexpr byte | TX_PREAMBLE_LEN_512 = 0x0D |
|
static constexpr byte | TX_PREAMBLE_LEN_1024 = 0x02 |
|
static constexpr byte | TX_PREAMBLE_LEN_1536 = 0x06 |
|
static constexpr byte | TX_PREAMBLE_LEN_2048 = 0x0A |
|
static constexpr byte | TX_PREAMBLE_LEN_4096 = 0x03 |
|
static constexpr byte | PAC_SIZE_8 = 8 |
|
static constexpr byte | PAC_SIZE_16 = 16 |
|
static constexpr byte | PAC_SIZE_32 = 32 |
|
static constexpr byte | PAC_SIZE_64 = 64 |
|
static constexpr byte | CHANNEL_1 = 1 |
|
static constexpr byte | CHANNEL_2 = 2 |
|
static constexpr byte | CHANNEL_3 = 3 |
|
static constexpr byte | CHANNEL_4 = 4 |
|
static constexpr byte | CHANNEL_5 = 5 |
|
static constexpr byte | CHANNEL_7 = 7 |
|
static constexpr byte | PREAMBLE_CODE_16MHZ_1 = 1 |
|
static constexpr byte | PREAMBLE_CODE_16MHZ_2 = 2 |
|
static constexpr byte | PREAMBLE_CODE_16MHZ_3 = 3 |
|
static constexpr byte | PREAMBLE_CODE_16MHZ_4 = 4 |
|
static constexpr byte | PREAMBLE_CODE_16MHZ_5 = 5 |
|
static constexpr byte | PREAMBLE_CODE_16MHZ_6 = 6 |
|
static constexpr byte | PREAMBLE_CODE_16MHZ_7 = 7 |
|
static constexpr byte | PREAMBLE_CODE_16MHZ_8 = 8 |
|
static constexpr byte | PREAMBLE_CODE_64MHZ_9 = 9 |
|
static constexpr byte | PREAMBLE_CODE_64MHZ_10 = 10 |
|
static constexpr byte | PREAMBLE_CODE_64MHZ_11 = 11 |
|
static constexpr byte | PREAMBLE_CODE_64MHZ_12 = 12 |
|
static constexpr byte | PREAMBLE_CODE_64MHZ_17 = 17 |
|
static constexpr byte | PREAMBLE_CODE_64MHZ_18 = 18 |
|
static constexpr byte | PREAMBLE_CODE_64MHZ_19 = 19 |
|
static constexpr byte | PREAMBLE_CODE_64MHZ_20 = 20 |
|
static constexpr byte | FRAME_LENGTH_NORMAL = 0x00 |
|
static constexpr byte | FRAME_LENGTH_EXTENDED = 0x03 |
|
static constexpr byte | MODE_LONGDATA_RANGE_LOWPOWER [] = {TRX_RATE_110KBPS, TX_PULSE_FREQ_16MHZ, TX_PREAMBLE_LEN_2048} |
|
static constexpr byte | MODE_SHORTDATA_FAST_LOWPOWER [] = {TRX_RATE_6800KBPS, TX_PULSE_FREQ_16MHZ, TX_PREAMBLE_LEN_128} |
|
static constexpr byte | MODE_LONGDATA_FAST_LOWPOWER [] = {TRX_RATE_6800KBPS, TX_PULSE_FREQ_16MHZ, TX_PREAMBLE_LEN_1024} |
|
static constexpr byte | MODE_SHORTDATA_FAST_ACCURACY [] = {TRX_RATE_6800KBPS, TX_PULSE_FREQ_64MHZ, TX_PREAMBLE_LEN_128} |
|
static constexpr byte | MODE_LONGDATA_FAST_ACCURACY [] = {TRX_RATE_6800KBPS, TX_PULSE_FREQ_64MHZ, TX_PREAMBLE_LEN_1024} |
|
static constexpr byte | MODE_LONGDATA_RANGE_ACCURACY [] = {TRX_RATE_110KBPS, TX_PULSE_FREQ_64MHZ, TX_PREAMBLE_LEN_2048} |
|
static uint8_t | _ss |
|
static uint8_t | _rst |
|
static uint8_t | _irq |
|
static void(* | _handleError )(void) |
|
static void(* | _handleSent )(void) |
|
static void(* | _handleReceived )(void) |
|
static void(* | _handleReceiveFailed )(void) |
|
static void(* | _handleReceiveTimeout )(void) |
|
static void(* | _handleReceiveTimestampAvailable )(void) |
|
static byte | _syscfg [LEN_SYS_CFG] |
|
static byte | _sysctrl [LEN_SYS_CTRL] |
|
static byte | _sysstatus [LEN_SYS_STATUS] |
|
static byte | _txfctrl [LEN_TX_FCTRL] |
|
static byte | _sysmask [LEN_SYS_MASK] |
|
static byte | _chanctrl [LEN_CHAN_CTRL] |
|
static byte | _vmeas3v3 = 0 |
|
static byte | _tmeas23C = 0 |
|
static byte | _networkAndAddress [LEN_PANADR] |
|
static boolean | _smartPower = false |
|
static byte | _extendedFrameLength = FRAME_LENGTH_NORMAL |
|
static byte | _preambleCode = PREAMBLE_CODE_16MHZ_4 |
|
static byte | _channel = CHANNEL_5 |
|
static byte | _preambleLength = TX_PREAMBLE_LEN_128 |
|
static byte | _pulseFrequency = TX_PULSE_FREQ_16MHZ |
|
static byte | _dataRate = TRX_RATE_6800KBPS |
|
static byte | _pacSize = PAC_SIZE_8 |
|
static DW1000Time | _antennaDelay |
|
static boolean | _permanentReceive = false |
|
static boolean | _frameCheck = true |
|
static uint8_t | _deviceMode = IDLE_MODE |
|
static const byte | WRITE = 0x80 |
|
static const byte | WRITE_SUB = 0xC0 |
|
static const byte | READ = 0x00 |
|
static const byte | READ_SUB = 0x40 |
|
static const byte | RW_SUB_EXT = 0x80 |
|
static const byte | AUTO_CLOCK = 0x00 |
|
static const byte | XTI_CLOCK = 0x01 |
|
static const byte | PLL_CLOCK = 0x02 |
|
static const SPISettings | _fastSPI = SPISettings(16000000L, MSBFIRST, SPI_MODE0) |
|
static const SPISettings | _slowSPI = SPISettings(2000000L, MSBFIRST, SPI_MODE0) |
|
static const SPISettings * | _currentSPI = &_fastSPI |
|
static const byte | BIAS_500_16_ZERO = 10 |
|
static const byte | BIAS_500_64_ZERO = 8 |
|
static const byte | BIAS_900_16_ZERO = 7 |
|
static const byte | BIAS_900_64_ZERO = 7 |
|
static constexpr byte | BIAS_500_16 [] = {198, 187, 179, 163, 143, 127, 109, 84, 59, 31, 0, 36, 65, 84, 97, 106, 110, 112} |
|
static constexpr byte | BIAS_500_64 [] = {110, 105, 100, 93, 82, 69, 51, 27, 0, 21, 35, 42, 49, 62, 71, 76, 81, 86} |
|
static constexpr byte | BIAS_900_16 [] = {137, 122, 105, 88, 69, 47, 25, 0, 21, 48, 79, 105, 127, 147, 160, 169, 178, 197} |
|
static constexpr byte | BIAS_900_64 [] = {147, 133, 117, 99, 75, 50, 29, 0, 24, 45, 63, 76, 87, 98, 116, 122, 132, 142} |
|
void DW1000Class::enableMode |
( |
const byte |
mode[] | ) |
|
|
static |
Specifies the mode of operation for the DW1000. Modes of operation are pre-defined combinations of data rate, pulse repetition frequency, preamble and channel settings that properly go together. If you simply want the chips to work, choosing a mode is preferred over manual configuration.
The following modes are pre-configured and one of them needs to be chosen:
MODE_LONGDATA_RANGE_LOWPOWER
(basically this is 110 kb/s data rate, 16 MHz PRF and long preambles)
MODE_SHORTDATA_FAST_LOWPOWER
(basically this is 6.8 Mb/s data rate, 16 MHz PRF and short preambles)
MODE_LONGDATA_FAST_LOWPOWER
(basically this is 6.8 Mb/s data rate, 16 MHz PRF and long preambles)
MODE_SHORTDATA_FAST_ACCURACY
(basically this is 6.8 Mb/s data rate, 64 MHz PRF and short preambles)
MODE_LONGDATA_FAST_ACCURACY
(basically this is 6.8 Mb/s data rate, 64 MHz PRF and long preambles)
MODE_LONGDATA_RANGE_ACCURACY
(basically this is 110 kb/s data rate, 64 MHz PRF and long preambles)
Note that LOWPOWER and ACCURACY refers to the better power efficiency and improved transmission performance of 16 MHZ and 64 MHZ PRF respectively (see setPulseFrequency()
).
The default setting that is selected by setDefaults()
is MODE_LONGDATA_RANGE_LOWPOWER.
- Parameters
-
[in] | mode | The mode of operation, encoded by the above defined constants. |