Skip to content

Commit

Permalink
libs update
Browse files Browse the repository at this point in the history
  • Loading branch information
sblantipodi committed Jan 3, 2023
1 parent 36703a1 commit b8ff382
Show file tree
Hide file tree
Showing 816 changed files with 22,016 additions and 22,820 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,3 +30,4 @@ jobs:

- name: Test the code on supported platforms
run: python3 ci/build_platform.py main_platforms zero feather32u4

2 changes: 1 addition & 1 deletion .pio/libdeps/watchwinder_1/Adafruit BusIO/.piopm
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"type": "library", "name": "Adafruit BusIO", "version": "1.12.0", "spec": {"owner": "adafruit", "id": 6214, "name": "Adafruit BusIO", "requirements": null, "uri": null}}
{"type": "library", "name": "Adafruit BusIO", "version": "1.14.1", "spec": {"owner": "adafruit", "id": 6214, "name": "Adafruit BusIO", "requirements": null, "uri": null}}
46 changes: 45 additions & 1 deletion .pio/libdeps/watchwinder_1/Adafruit BusIO/Adafruit_I2CDevice.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,8 @@ bool Adafruit_I2CDevice::read(uint8_t *buffer, size_t len, bool stop) {
bool Adafruit_I2CDevice::_read(uint8_t *buffer, size_t len, bool stop) {
#if defined(TinyWireM_h)
size_t recv = _wire->requestFrom((uint8_t)_addr, (uint8_t)len);
#elif defined(ARDUINO_ARCH_MEGAAVR)
size_t recv = _wire->requestFrom(_addr, len, stop);
#else
size_t recv = _wire->requestFrom((uint8_t)_addr, (uint8_t)len, (uint8_t)stop);
#endif
Expand Down Expand Up @@ -259,9 +261,51 @@ uint8_t Adafruit_I2CDevice::address(void) { return _addr; }
* Not necessarily that the speed was achieved!
*/
bool Adafruit_I2CDevice::setSpeed(uint32_t desiredclk) {
#if (ARDUINO >= 157) && !defined(ARDUINO_STM32_FEATHER) && !defined(TinyWireM_h)
#if defined(__AVR_ATmega328__) || \
defined(__AVR_ATmega328P__) // fix arduino core set clock
// calculate TWBR correctly

if ((F_CPU / 18) < desiredclk) {
#ifdef DEBUG_SERIAL
Serial.println(F("I2C.setSpeed too high."));
#endif
return false;
}
uint32_t atwbr = ((F_CPU / desiredclk) - 16) / 2;
if (atwbr > 16320) {
#ifdef DEBUG_SERIAL
Serial.println(F("I2C.setSpeed too low."));
#endif
return false;
}

if (atwbr <= 255) {
atwbr /= 1;
TWSR = 0x0;
} else if (atwbr <= 1020) {
atwbr /= 4;
TWSR = 0x1;
} else if (atwbr <= 4080) {
atwbr /= 16;
TWSR = 0x2;
} else { // if (atwbr <= 16320)
atwbr /= 64;
TWSR = 0x3;
}
TWBR = atwbr;

#ifdef DEBUG_SERIAL
Serial.print(F("TWSR prescaler = "));
Serial.println(pow(4, TWSR));
Serial.print(F("TWBR = "));
Serial.println(atwbr);
#endif
return true;
#elif (ARDUINO >= 157) && !defined(ARDUINO_STM32_FEATHER) && \
!defined(TinyWireM_h)
_wire->setClock(desiredclk);
return true;

#else
(void)desiredclk;
return false;
Expand Down
39 changes: 27 additions & 12 deletions .pio/libdeps/watchwinder_1/Adafruit BusIO/Adafruit_SPIDevice.cpp
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
#include "Adafruit_SPIDevice.h"

#if !defined(SPI_INTERFACES_COUNT) || \
(defined(SPI_INTERFACES_COUNT) && (SPI_INTERFACES_COUNT > 0))

//#define DEBUG_SERIAL Serial

/*!
Expand All @@ -17,6 +14,7 @@
Adafruit_SPIDevice::Adafruit_SPIDevice(int8_t cspin, uint32_t freq,
BusIOBitOrder dataOrder,
uint8_t dataMode, SPIClass *theSPI) {
#ifdef BUSIO_HAS_HW_SPI
_cs = cspin;
_sck = _mosi = _miso = -1;
_spi = theSPI;
Expand All @@ -25,6 +23,14 @@ Adafruit_SPIDevice::Adafruit_SPIDevice(int8_t cspin, uint32_t freq,
_freq = freq;
_dataOrder = dataOrder;
_dataMode = dataMode;
#else
// unused, but needed to suppress compiler warns
(void)cspin;
(void)freq;
(void)dataOrder;
(void)dataMode;
(void)theSPI;
#endif
}

/*!
Expand Down Expand Up @@ -68,14 +74,15 @@ Adafruit_SPIDevice::Adafruit_SPIDevice(int8_t cspin, int8_t sckpin,
_dataOrder = dataOrder;
_dataMode = dataMode;
_begun = false;
_spiSetting = new SPISettings(freq, dataOrder, dataMode);
_spi = nullptr;
}

/*!
* @brief Release memory allocated in constructors
*/
Adafruit_SPIDevice::~Adafruit_SPIDevice() { delete _spiSetting; }
Adafruit_SPIDevice::~Adafruit_SPIDevice() {
if (_spiSetting)
delete _spiSetting;
}

/*!
* @brief Initializes SPI bus and sets CS pin high
Expand All @@ -89,7 +96,9 @@ bool Adafruit_SPIDevice::begin(void) {
}

if (_spi) { // hardware SPI
#ifdef BUSIO_HAS_HW_SPI
_spi->begin();
#endif
} else {
pinMode(_sck, OUTPUT);

Expand Down Expand Up @@ -120,9 +129,11 @@ bool Adafruit_SPIDevice::begin(void) {
* @param len The number of bytes to transfer
*/
void Adafruit_SPIDevice::transfer(uint8_t *buffer, size_t len) {
//
// HARDWARE SPI
//
if (_spi) {
// hardware SPI is easy

#ifdef BUSIO_HAS_HW_SPI
#if defined(SPARK)
_spi->transfer(buffer, buffer, len, nullptr);
#elif defined(STM32)
Expand All @@ -133,8 +144,12 @@ void Adafruit_SPIDevice::transfer(uint8_t *buffer, size_t len) {
_spi->transfer(buffer, len);
#endif
return;
#endif
}

//
// SOFTWARE SPI
//
uint8_t startbit;
if (_dataOrder == SPI_BITORDER_LSBFIRST) {
startbit = 0x1;
Expand All @@ -145,9 +160,7 @@ void Adafruit_SPIDevice::transfer(uint8_t *buffer, size_t len) {
bool towrite, lastmosi = !(buffer[0] & startbit);
uint8_t bitdelay_us = (1000000 / _freq) / 2;

// for softSPI we'll do it by hand
for (size_t i = 0; i < len; i++) {
// software SPI
uint8_t reply = 0;
uint8_t send = buffer[i];

Expand Down Expand Up @@ -269,7 +282,9 @@ uint8_t Adafruit_SPIDevice::transfer(uint8_t send) {
*/
void Adafruit_SPIDevice::beginTransaction(void) {
if (_spi) {
#ifdef BUSIO_HAS_HW_SPI
_spi->beginTransaction(*_spiSetting);
#endif
}
}

Expand All @@ -278,7 +293,9 @@ void Adafruit_SPIDevice::beginTransaction(void) {
*/
void Adafruit_SPIDevice::endTransaction(void) {
if (_spi) {
#ifdef BUSIO_HAS_HW_SPI
_spi->endTransaction();
#endif
}
}

Expand Down Expand Up @@ -489,5 +506,3 @@ bool Adafruit_SPIDevice::write_and_read(uint8_t *buffer, size_t len) {

return true;
}

#endif // SPI exists
25 changes: 20 additions & 5 deletions .pio/libdeps/watchwinder_1/Adafruit BusIO/Adafruit_SPIDevice.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,14 @@

#if !defined(SPI_INTERFACES_COUNT) || \
(defined(SPI_INTERFACES_COUNT) && (SPI_INTERFACES_COUNT > 0))

// HW SPI available
#include <SPI.h>
#define BUSIO_HAS_HW_SPI
#else
// SW SPI ONLY
enum { SPI_MODE0, SPI_MODE1, SPI_MODE2, _SPI_MODE4 };
typedef uint8_t SPIClass;
#endif

// some modern SPI definitions don't have BitOrder enum
#if (defined(__AVR__) && !defined(ARDUINO_ARCH_MEGAAVR)) || \
Expand Down Expand Up @@ -77,10 +83,15 @@ typedef uint32_t BusIO_PortMask;
/**! The class which defines how we will talk to this device over SPI **/
class Adafruit_SPIDevice {
public:
#ifdef BUSIO_HAS_HW_SPI
Adafruit_SPIDevice(int8_t cspin, uint32_t freq = 1000000,
BusIOBitOrder dataOrder = SPI_BITORDER_MSBFIRST,
uint8_t dataMode = SPI_MODE0, SPIClass *theSPI = &SPI);

#else
Adafruit_SPIDevice(int8_t cspin, uint32_t freq = 1000000,
BusIOBitOrder dataOrder = SPI_BITORDER_MSBFIRST,
uint8_t dataMode = SPI_MODE0, SPIClass *theSPI = nullptr);
#endif
Adafruit_SPIDevice(int8_t cspin, int8_t sck, int8_t miso, int8_t mosi,
uint32_t freq = 1000000,
BusIOBitOrder dataOrder = SPI_BITORDER_MSBFIRST,
Expand All @@ -104,8 +115,13 @@ class Adafruit_SPIDevice {
void endTransactionWithDeassertingCS();

private:
SPIClass *_spi;
SPISettings *_spiSetting;
#ifdef BUSIO_HAS_HW_SPI
SPIClass *_spi = nullptr;
SPISettings *_spiSetting = nullptr;
#else
uint8_t *_spi = nullptr;
uint8_t *_spiSetting = nullptr;
#endif
uint32_t _freq;
BusIOBitOrder _dataOrder;
uint8_t _dataMode;
Expand All @@ -119,5 +135,4 @@ class Adafruit_SPIDevice {
bool _begun;
};

#endif // has SPI defined
#endif // Adafruit_SPIDevice_h
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name=Adafruit BusIO
version=1.12.0
version=1.14.1
author=Adafruit
maintainer=Adafruit <info@adafruit.com>
sentence=This is a library for abstracting away UART, I2C and SPI interfacing
Expand Down
2 changes: 1 addition & 1 deletion .pio/libdeps/watchwinder_1/Adafruit SSD1306/.piopm
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"type": "library", "name": "Adafruit SSD1306", "version": "2.5.6", "spec": {"owner": "adafruit", "id": 135, "name": "Adafruit SSD1306", "requirements": null, "uri": null}}
{"type": "library", "name": "Adafruit SSD1306", "version": "2.5.7", "spec": {"owner": "adafruit", "id": 135, "name": "Adafruit SSD1306", "requirements": null, "uri": null}}
1 change: 1 addition & 0 deletions .pio/libdeps/watchwinder_1/Adafruit SSD1306/component.mk
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
COMPONENT_ADD_INCLUDEDIRS = .
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name=Adafruit SSD1306
version=2.5.6
version=2.5.7
author=Adafruit
maintainer=Adafruit <info@adafruit.com>
sentence=SSD1306 oled driver library for monochrome 128x64 and 128x32 displays
Expand Down
2 changes: 2 additions & 0 deletions .pio/libdeps/watchwinder_1/ArduinoJson/.clang-format
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ Standard: Cpp03
AllowShortFunctionsOnASingleLine: Empty
IncludeBlocks: Preserve
IndentPPDirectives: AfterHash
DerivePointerAlignment: false

# Always break after if to get accurate coverage
AllowShortIfStatementsOnASingleLine: false
AllowShortLoopsOnASingleLine: false
2 changes: 1 addition & 1 deletion .pio/libdeps/watchwinder_1/ArduinoJson/.piopm
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"type": "library", "name": "ArduinoJson", "version": "6.19.4", "spec": {"owner": "bblanchon", "id": 64, "name": "ArduinoJson", "requirements": null, "url": null}}
{"type": "library", "name": "ArduinoJson", "version": "6.20.0", "spec": {"owner": "bblanchon", "id": 64, "name": "ArduinoJson", "requirements": null, "uri": null}}
35 changes: 35 additions & 0 deletions .pio/libdeps/watchwinder_1/ArduinoJson/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,41 @@
ArduinoJson: change log
=======================

v6.20.0 (2022-12-26)
-------

* Add `JsonVariant::shallowCopy()` (issue #1343)
* Fix `9.22337e+18 is outside the range of representable values of type 'long'`
* Fix comparison operators for `JsonArray`, `JsonArrayConst`, `JsonObject`, and `JsonObjectConst`
* Fix lax parsing of `true`, `false`, and `null` (issue #1781)
* Remove undocumented `accept()` functions
* Rename `addElement()` to `add()`
* Remove `getElement()`, `getOrAddElement()`, `getMember()`, and `getOrAddMember()`
* Remove undocumented `JsonDocument::data()` and `JsonDocument::memoryPool()`
* Remove undocumented `JsonArrayIterator::internal()` and `JsonObjectIterator::internal()`
* Rename things in `ARDUINOJSON_NAMESPACE` to match the public names
* Add documentation to most public symbols
* Remove support for naked `char` (was deprecated since 6.18.0)

> ### BREAKING CHANGES
>
> This release hides `JsonVariant`'s functions that were only intended for internal use.
> If you were using them in your programs, you must replace with `operator[]` and `to<JsonVariant>()`, like so:
>
> ```c++
> // before
> JsonVariant a = variant.getElement(idx);
> JsonVariant b = variant.getOrAddElement(idx);
> JsonVariant c = variant.getMember(key);
> JsonVariant d = variant.getOrAddMember(key);
>
> // after
> JsonVariant a = variant[idx];
> JsonVariant b = idx < variant.size() ? variant[idx] : variant[idx].to<JsonVariant>();
> JsonVariant c = variant[key];
> JsonVariant d = variant.containsKey(key) ? variant[key] : variant[key].to<JsonVariant>();
> ```
v6.19.4 (2022-04-05)
-------
Expand Down
Loading

0 comments on commit b8ff382

Please sign in to comment.