diff --git a/libraries/ADT7470/.github/FUNDING.yml b/libraries/ADT7470/.github/FUNDING.yml index 90d9ab4c..2859c159 100644 --- a/libraries/ADT7470/.github/FUNDING.yml +++ b/libraries/ADT7470/.github/FUNDING.yml @@ -1,4 +1,5 @@ # These are supported funding model platforms -github: RobTillaart +github: RobTillaart +custom: "https://www.paypal.me/robtillaart" diff --git a/libraries/ADT7470/.github/workflows/arduino-lint.yml b/libraries/ADT7470/.github/workflows/arduino-lint.yml index 8a26f14a..70d8d1c3 100644 --- a/libraries/ADT7470/.github/workflows/arduino-lint.yml +++ b/libraries/ADT7470/.github/workflows/arduino-lint.yml @@ -5,8 +5,9 @@ on: [push, pull_request] jobs: lint: runs-on: ubuntu-latest + timeout-minutes: 5 steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: arduino/arduino-lint-action@v1 with: library-manager: update diff --git a/libraries/ADT7470/.github/workflows/arduino_test_runner.yml b/libraries/ADT7470/.github/workflows/arduino_test_runner.yml index fadfa904..501768ee 100644 --- a/libraries/ADT7470/.github/workflows/arduino_test_runner.yml +++ b/libraries/ADT7470/.github/workflows/arduino_test_runner.yml @@ -1,4 +1,4 @@ ---- + name: Arduino CI on: [push, pull_request] @@ -6,9 +6,10 @@ on: [push, pull_request] jobs: runTest: runs-on: ubuntu-latest + timeout-minutes: 20 steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ruby/setup-ruby@v1 with: ruby-version: 2.6 diff --git a/libraries/ADT7470/.github/workflows/jsoncheck.yml b/libraries/ADT7470/.github/workflows/jsoncheck.yml index 37a11298..fd05f5f8 100644 --- a/libraries/ADT7470/.github/workflows/jsoncheck.yml +++ b/libraries/ADT7470/.github/workflows/jsoncheck.yml @@ -9,10 +9,11 @@ on: jobs: test: runs-on: ubuntu-latest + timeout-minutes: 5 steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: json-syntax-check - uses: limitusus/json-syntax-check@v1 + uses: limitusus/json-syntax-check@v2 with: pattern: "\\.json$" diff --git a/libraries/ADT7470/ADT7470.cpp b/libraries/ADT7470/ADT7470.cpp index e3b330ac..5e8d6884 100644 --- a/libraries/ADT7470/ADT7470.cpp +++ b/libraries/ADT7470/ADT7470.cpp @@ -1,7 +1,7 @@ // // FILE: ADT7470.cpp // AUTHOR: Rob Tillaart -// VERSION: 0.2.0 +// VERSION: 0.2.1 // PURPOSE: Arduino library for I2C ADT7470 Fan Monitoring // URL: https://github.com/RobTillaart/ADT7470 // http://forum.arduino.cc/index.php?topic=363218.0 diff --git a/libraries/ADT7470/ADT7470.h b/libraries/ADT7470/ADT7470.h index 4e7f1560..4d0e12c4 100644 --- a/libraries/ADT7470/ADT7470.h +++ b/libraries/ADT7470/ADT7470.h @@ -2,17 +2,16 @@ // // FILE: ADT7470.h // AUTHOR: Rob Tillaart -// VERSION: 0.2.0 +// VERSION: 0.2.1 // PURPOSE: Arduino library for I2C ADT7470 Fan Monitoring // URL: https://github.com/RobTillaart/ADT7470 // http://forum.arduino.cc/index.php?topic=363218.0 - #include "Arduino.h" #include "Wire.h" -#define ADT7470_LIB_VERSION (F("0.2.0")) +#define ADT7470_LIB_VERSION (F("0.2.1")) #ifndef ADT7470_TIMEOUT #define ADT7470_TIMEOUT 1000 diff --git a/libraries/ADT7470/CHANGELOG.md b/libraries/ADT7470/CHANGELOG.md index 1cb673b7..4d7dd5dc 100644 --- a/libraries/ADT7470/CHANGELOG.md +++ b/libraries/ADT7470/CHANGELOG.md @@ -6,6 +6,11 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/) and this project adheres to [Semantic Versioning](http://semver.org/). +## [0.2.1] - 2023-04-06 +- update GitHub actions +- minor edits + + ## [0.2.0] - 2023-10-13 - add support for Wire1 etc (ESP32) - add CHANGELOG.md diff --git a/libraries/ADT7470/LICENSE b/libraries/ADT7470/LICENSE index 18c804e7..3b61d73d 100644 --- a/libraries/ADT7470/LICENSE +++ b/libraries/ADT7470/LICENSE @@ -1,6 +1,6 @@ MIT License -Copyright (c) 2015-2023 Rob Tillaart +Copyright (c) 2015-2024 Rob Tillaart Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/libraries/ADT7470/README.md b/libraries/ADT7470/README.md index bde7b3f6..7d09abdc 100644 --- a/libraries/ADT7470/README.md +++ b/libraries/ADT7470/README.md @@ -41,11 +41,11 @@ inductive pulse when switched off. (see also datasheet). (from datasheet) -| Pin 11 | (ADDR) State | Address | -|:----------------------|:------------:|:---------------------------------------------:| -| High (10 kΩ to VCC) | 010 1111 | (0x5E left-justified or 0x2F right-justified) | -| Low (10 kΩ to GND) | 010 1100 | (0x58 left-justified or 0x2C right-justified) | -| Floating (no pull-up) | 010 1110 | (0x5C left-justified or 0x2E right-justified) | +| Pin 11 | (ADDR) State | Address | +|:------------------------|:------------:|:---------------------------------------------:| +| HIGH (10 kΩ to VCC) | 010 1111 | 0x5E left-justified or 0x2F right-justified | +| LOW (10 kΩ to GND) | 010 1100 | 0x58 left-justified or 0x2C right-justified | +| Floating (no pull-up) | 010 1110 | 0x5C left-justified or 0x2E right-justified | ## Interface @@ -54,10 +54,10 @@ inductive pulse when switched off. (see also datasheet). #include "ADT7470.h" ``` -The interface consists of: +Check datasheet for the details as this section needs to be elaborated. -- **ADT7470()** constructor -- **void begin()** initialize the I2C bus +- **ADT7470(uint8_t address, TwoWire \*wire = &Wire)** constructor, with default I2C bus. +- **void begin()** initialize the library - **bool isConnected()** check if the module is connected to the I2C bus - **void startMonitoring()** - **void stopMonitoring()** @@ -78,15 +78,15 @@ The interface consists of: of sensor index. Temperature sensors are daisy changed. - **int8_t getMaxTemperature()** get max temperature of connected temperature sensors. - **bool setTemperatureLimit(uint8_t index, int8_t low, int8_t high)** for ALARM function -- **int8_t getTemperatureLowLimit(uint8_t index)** -- **int8_t getTemperatureHighLimit(uint8_t index)** +- **int8_t getTemperatureLowLimit(uint8_t index)** return the set value. Default ? +- **int8_t getTemperatureHighLimit(uint8_t index)** return the set value. Default ? #### PWM - **bool setPWM(uint8_t index, uint8_t value)** set the speed of the fan at index - **uint8_t getPWM(uint8_t index)** read back the speed set. -- **bool setFanLowFreq(value = 0)** +- **bool setFanLowFreq(value = 0)** set PWM frequency. - **bool setFanHighFreq(value = 0)** - **void setInvertPWM(uint8_t index)** - **uint8_t getInvertPWM(uint8_t index)** diff --git a/libraries/ADT7470/examples/adt7470_demo/adt7470_demo.ino b/libraries/ADT7470/examples/adt7470_demo/adt7470_demo.ino index 080acaa7..74c94694 100644 --- a/libraries/ADT7470/examples/adt7470_demo/adt7470_demo.ino +++ b/libraries/ADT7470/examples/adt7470_demo/adt7470_demo.ino @@ -4,7 +4,6 @@ // PURPOSE: demo ADT7470 library -#include #include "ADT7470.h" ADT7470 ADT(ADT7470_ADDR_FLOAT); // default Wire @@ -18,8 +17,8 @@ void setup() Serial.println("ADT7470_LIB_VERSION: "); Serial.println(ADT7470_LIB_VERSION); Serial.println(); - - + + Wire.begin(); Serial.begin(115200); @@ -41,7 +40,6 @@ void setup() testTach(); testFanSpeed(); - testStop(); } Serial.println("Done"); @@ -141,7 +139,7 @@ void testTach() ADT.setPulsesPerRevolution(i, ppr[i]); bool b = (ppr[i] == ADT.getPulsesPerRevolution(i)); Serial.print("\t"); - Serial.print(b ? "T" : "F"); // expect TTTT + Serial.print(b ? "T" : "F"); // expect TTTT } Serial.println(); diff --git a/libraries/ADT7470/library.json b/libraries/ADT7470/library.json index 72b16f17..775a906f 100644 --- a/libraries/ADT7470/library.json +++ b/libraries/ADT7470/library.json @@ -15,7 +15,7 @@ "type": "git", "url": "https://github.com/RobTillaart/ADT7470.git" }, - "version": "0.2.0", + "version": "0.2.1", "license": "MIT", "frameworks": "*", "platforms": "*", diff --git a/libraries/ADT7470/library.properties b/libraries/ADT7470/library.properties index cc71eff2..ad3c44af 100644 --- a/libraries/ADT7470/library.properties +++ b/libraries/ADT7470/library.properties @@ -1,5 +1,5 @@ name=ADT7470 -version=0.2.0 +version=0.2.1 author=Rob Tillaart maintainer=Rob Tillaart sentence=ADT7470 Library