From 4667c26448e644cd9ae178eec800201fac925723 Mon Sep 17 00:00:00 2001 From: jgromes Date: Sun, 13 Nov 2022 22:12:34 +0100 Subject: [PATCH] [SX128x] Removed slowdown macro (#158) --- src/BuildOpt.h | 14 -------------- src/modules/SX128x/SX128x.cpp | 7 ------- 2 files changed, 21 deletions(-) diff --git a/src/BuildOpt.h b/src/BuildOpt.h index ed55362e..c86f6167 100644 --- a/src/BuildOpt.h +++ b/src/BuildOpt.h @@ -82,11 +82,6 @@ // the following must be defined if the Arduino core does not support tone function //#define RADIOLIB_TONE_UNSUPPORTED - // some platforms seem to have issues with SPI modules that use a command interface - // this can be mitigated by adding delays into SPI communication - // (see https://github.com/jgromes/RadioLib/issues/158 for details) - //#define RADIOLIB_SPI_SLOWDOWN - // some of RadioLib drivers may be excluded, to prevent collisions with platforms (or to speed up build process) // the following is a complete list of all possible exclusion macros, uncomment any of them to disable that driver // NOTE: Some of the exclusion macros are dependent on each other. For example, it is not possible to exclude RF69 @@ -235,9 +230,6 @@ #define RADIOLIB_NONVOLATILE_READ_BYTE(addr) pgm_read_byte(addr) #define RADIOLIB_TYPE_ALIAS(type, alias) using alias = type; - // slow down SX126x/8x SPI on this platform - #define RADIOLIB_SPI_SLOWDOWN - // Arduino API callbacks #define RADIOLIB_CB_ARGS_PIN_MODE (void, pinMode, uint32_t dwPin, uint32_t dwMode) #define RADIOLIB_CB_ARGS_DIGITAL_WRITE (void, digitalWrite, uint32_t dwPin, uint32_t dwVal) @@ -273,9 +265,6 @@ #define RADIOLIB_NONVOLATILE_READ_BYTE(addr) pgm_read_byte(addr) #define RADIOLIB_TYPE_ALIAS(type, alias) using alias = type; - // slow down SX126x/8x SPI on this platform - #define RADIOLIB_SPI_SLOWDOWN - // Arduino API callbacks #define RADIOLIB_CB_ARGS_PIN_MODE (void, pinMode, uint32_t dwPin, uint32_t dwMode) #define RADIOLIB_CB_ARGS_DIGITAL_WRITE (void, digitalWrite, uint32_t dwPin, uint32_t dwVal) @@ -487,9 +476,6 @@ #define RADIOLIB_NONVOLATILE_READ_BYTE(addr) pgm_read_byte(addr) #define RADIOLIB_TYPE_ALIAS(type, alias) using alias = type; - // slow down SX126x/8x SPI on this platform - #define RADIOLIB_SPI_SLOWDOWN - // Arduino API callbacks #define RADIOLIB_CB_ARGS_PIN_MODE (void, pinMode, pin_size_t pinName, Arduino_PinMode pinMode) #define RADIOLIB_CB_ARGS_DIGITAL_WRITE (void, digitalWrite, pin_size_t pinName, PinStatus val) diff --git a/src/modules/SX128x/SX128x.cpp b/src/modules/SX128x/SX128x.cpp index 188fe127..3e084090 100644 --- a/src/modules/SX128x/SX128x.cpp +++ b/src/modules/SX128x/SX128x.cpp @@ -1612,13 +1612,6 @@ int16_t SX128x::SPItransfer(uint8_t* cmd, uint8_t cmdLen, bool write, uint8_t* d RADIOLIB_VERBOSE_PRINTLN(); } RADIOLIB_VERBOSE_PRINTLN(); - #else - // some faster platforms require a short delay here - // not sure why, but it seems that long enough SPI transaction - // (e.g. setPacketParams for GFSK) will fail without it - #if defined(RADIOLIB_SPI_SLOWDOWN) - _mod->delay(1); - #endif #endif // parse status