This commit is contained in:
ladyada 2021-07-01 11:40:28 -04:00
parent 63853d619d
commit f28f3ae7f0
5 changed files with 10 additions and 7 deletions

View File

@ -1,6 +1,7 @@
#include <Adafruit_BusIO_Register.h> #include <Adafruit_BusIO_Register.h>
#if !defined(SPI_INTERFACES_COUNT) || (defined(SPI_INTERFACES_COUNT) && (SPI_INTERFACES_COUNT > 0)) #if !defined(SPI_INTERFACES_COUNT) || \
(defined(SPI_INTERFACES_COUNT) && (SPI_INTERFACES_COUNT > 0))
/*! /*!
* @brief Create a register we access over an I2C Device (which defines the * @brief Create a register we access over an I2C Device (which defines the
@ -361,5 +362,4 @@ void Adafruit_BusIO_Register::setAddressWidth(uint16_t address_width) {
_addrwidth = address_width; _addrwidth = address_width;
} }
#endif // SPI exists #endif // SPI exists

View File

@ -2,7 +2,8 @@
#include <Adafruit_SPIDevice.h> #include <Adafruit_SPIDevice.h>
#include <Arduino.h> #include <Arduino.h>
#if !defined(SPI_INTERFACES_COUNT) || (defined(SPI_INTERFACES_COUNT) && (SPI_INTERFACES_COUNT > 0)) #if !defined(SPI_INTERFACES_COUNT) || \
(defined(SPI_INTERFACES_COUNT) && (SPI_INTERFACES_COUNT > 0))
#ifndef Adafruit_BusIO_Register_h #ifndef Adafruit_BusIO_Register_h
#define Adafruit_BusIO_Register_h #define Adafruit_BusIO_Register_h

View File

@ -56,7 +56,7 @@ bool Adafruit_I2CDevice::detected(void) {
return true; return true;
} }
#ifdef DEBUG_SERIAL #ifdef DEBUG_SERIAL
DEBUG_SERIAL.println(F("Not detected")); DEBUG_SERIAL.println(F("Not detected"));
#endif #endif
return false; return false;
} }

View File

@ -1,7 +1,8 @@
#include <Arduino.h>
#include <Adafruit_SPIDevice.h> #include <Adafruit_SPIDevice.h>
#include <Arduino.h>
#if !defined(SPI_INTERFACES_COUNT) || (defined(SPI_INTERFACES_COUNT) && (SPI_INTERFACES_COUNT > 0)) #if !defined(SPI_INTERFACES_COUNT) || \
(defined(SPI_INTERFACES_COUNT) && (SPI_INTERFACES_COUNT > 0))
//#define DEBUG_SERIAL Serial //#define DEBUG_SERIAL Serial

View File

@ -1,4 +1,5 @@
#if !defined(SPI_INTERFACES_COUNT) || (defined(SPI_INTERFACES_COUNT) && (SPI_INTERFACES_COUNT > 0)) #if !defined(SPI_INTERFACES_COUNT) || \
(defined(SPI_INTERFACES_COUNT) && (SPI_INTERFACES_COUNT > 0))
#include <SPI.h> #include <SPI.h>