Skip to content
This repository was archived by the owner on Jan 29, 2023. It is now read-only.

Commit 62017ef

Browse files
authored
v1.5.1 add support to new Adafruit board
### Releases v1.5.1 1. Add support to new Adafruit board QTPY_ESP32S2 2. Update examples
1 parent d42dadb commit 62017ef

File tree

19 files changed

+114
-93
lines changed

19 files changed

+114
-93
lines changed

CONTRIBUTING.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ If you don't find anything, please [open a new issue](https://github.com/khoih-p
1515
Please ensure to specify the following:
1616

1717
* Arduino IDE version (e.g. 1.8.19) or Platform.io version
18-
* `ESP32` Core Version (e.g. ESP32 core v2.0.2)
1918
* `ESP32-S2` Board type (e.g. ESP32S2_DEV Module, ESP32_S2_Saola, etc.)
2019
* Contextual information (e.g. what you were trying to achieve)
2120
* Simplest possible steps to reproduce
@@ -28,10 +27,10 @@ Please ensure to specify the following:
2827

2928
```
3029
Arduino IDE version: 1.8.19
31-
ESP32 Core Version 2.0.2
30+
ESP32 core v2.0.3
3231
ESP32S2_DEV Module
3332
OS: Ubuntu 20.04 LTS
34-
Linux xy-Inspiron-3593 5.4.0-96-generic #109-Ubuntu SMP Wed Jan 12 16:49:16 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
33+
Linux xy-Inspiron-3593 5.13.0-44-generic #49~20.04.1-Ubuntu SMP Wed May 18 18:44:28 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
3534
3635
Context:
3736
I encountered a crash while using TimerInterrupt.

README.md

Lines changed: 10 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@
66
[![contributions welcome](https://img.shields.io/badge/contributions-welcome-brightgreen.svg?style=flat)](#Contributing)
77
[![GitHub issues](https://img.shields.io/github/issues/khoih-prog/ESP32_S2_TimerInterrupt.svg)](http://github.com/khoih-prog/ESP32_S2_TimerInterrupt/issues)
88

9-
<a href="https://www.buymeacoffee.com/khoihprog6" target="_blank"><img src="https://cdn.buymeacoffee.com/buttons/v2/default-yellow.png" alt="Buy Me A Coffee" style="height: 50px !important;width: 181px !important;" ></a>
9+
<a href="https://www.buymeacoffee.com/khoihprog6" title="Donate to my libraries using BuyMeACoffee"><img src="https://cdn.buymeacoffee.com/buttons/v2/default-yellow.png" alt="Donate to my libraries using BuyMeACoffee" style="height: 50px !important;width: 181px !important;" ></a>
10+
<a href="https://www.buymeacoffee.com/khoihprog6" title="Donate to my libraries using BuyMeACoffee"><img src="https://img.shields.io/badge/buy%20me%20a%20coffee-donate-orange.svg?logo=buy-me-a-coffee&logoColor=FFDD00" style="height: 20px !important;width: 200px !important;" ></a>
1011

1112
---
1213
---
@@ -113,7 +114,7 @@ The catch is **your function is now part of an ISR (Interrupt Service Routine),
113114

114115
### Currently supported Boards
115116

116-
1. ESP32-S2-based boards, such as ESP32_S2_DEV, ESP32_S2 Saola, etc
117+
1. ESP32S2-based boards, such as `ESP32S2_DEV`, `ESP32_S2 Saola`, Adafruit `QTPY_ESP32S2`, etc.
117118

118119
---
119120

@@ -130,7 +131,7 @@ The catch is **your function is now part of an ISR (Interrupt Service Routine),
130131
## Prerequisites
131132

132133
1. [`Arduino IDE 1.8.19+` for Arduino](https://github.com/arduino/Arduino). [![GitHub release](https://img.shields.io/github/release/arduino/Arduino.svg)](https://github.com/arduino/Arduino/releases/latest)
133-
2. [`ESP32 Core 2.0.2+`](https://github.com/espressif/arduino-esp32) for ESP32-S2-based boards. [![Latest release](https://img.shields.io/github/release/espressif/arduino-esp32.svg)](https://github.com/espressif/arduino-esp32/releases/latest/).
134+
2. [`ESP32 Core 2.0.3+`](https://github.com/espressif/arduino-esp32) for ESP32-S2-based boards. [![Latest release](https://img.shields.io/github/release/espressif/arduino-esp32.svg)](https://github.com/espressif/arduino-esp32/releases/latest/).
134135

135136
---
136137
---
@@ -155,7 +156,7 @@ Another way to install is to:
155156

156157
1. Install [VS Code](https://code.visualstudio.com/)
157158
2. Install [PlatformIO](https://platformio.org/platformio-ide)
158-
3. Install [**ESP32_S2_TimerInterrupt** library](https://platformio.org/lib/show/12127/ESP32_S2_TimerInterrupt) by using [Library Manager](https://platformio.org/lib/show/12127/ESP32_S2_TimerInterrupt/installation). Search for **ESP32_S2_TimerInterrupt** in [Platform.io Author's Libraries](https://platformio.org/lib/search?query=author:%22Khoi%20Hoang%22)
159+
3. Install [**ESP32_S2_TimerInterrupt** library](https://registry.platformio.org/libraries/khoih-prog/ESP32_S2_TimerInterrupt) by using [Library Manager](https://registry.platformio.org/libraries/khoih-prog/ESP32_S2_TimerInterrupt/installation). Search for **ESP32_S2_TimerInterrupt** in [Platform.io Author's Libraries](https://platformio.org/lib/search?query=author:%22Khoi%20Hoang%22)
159160
4. Use included [platformio.ini](platformio/platformio.ini) file from examples to ensure that all dependent libraries will installed automatically. Please visit documentation for the other options and examples at [Project Configuration File](https://docs.platformio.org/page/projectconf.html)
160161

161162

@@ -304,12 +305,6 @@ Before using any Timer, you have to make sure the Timer has not been used by any
304305
### Example [ISR_16_Timers_Array_Complex](examples/ISR_16_Timers_Array_Complex)
305306

306307
```
307-
#if !( ARDUINO_ESP32S2_DEV || ARDUINO_FEATHERS2 || ARDUINO_ESP32S2_THING_PLUS || ARDUINO_MICROS2 || \
308-
ARDUINO_METRO_ESP32S2 || ARDUINO_MAGTAG29_ESP32S2 || ARDUINO_FUNHOUSE_ESP32S2 || \
309-
ARDUINO_ADAFRUIT_FEATHER_ESP32S2_NOPSRAM )
310-
#error This code is intended to run on the ESP32-S2 platform! Please check your Tools->Board setting.
311-
#endif
312-
313308
// These define's must be placed at the beginning before #include "ESP32TimerInterrupt.h"
314309
// _TIMERINTERRUPT_LOGLEVEL_ from 0 to 4
315310
// Don't define _TIMERINTERRUPT_LOGLEVEL_ > 0. Only for special ISR debugging only. Can hang the system.
@@ -651,9 +646,8 @@ void loop()
651646
The following is the sample terminal output when running example [TimerInterruptTest](examples/TimerInterruptTest) to demonstrate how to start/stop Hardware Timers.
652647

653648
```
654-
655649
Starting TimerInterruptTest on ESP32S2_DEV
656-
ESP32_S2_TimerInterrupt v1.5.0
650+
ESP32_S2_TimerInterrupt v1.5.1
657651
CPU Frequency = 240 MHz
658652
[TISR] ESP32_S2_TimerInterrupt: _timerNo = 0, TIM_CLOCK_FREQ = 1000000.00
659653
[TISR] TIMER_BASE_CLK = 80000000, TIMER_DIVIDER = 80
@@ -686,7 +680,7 @@ The following is the sample terminal output when running example [Change_Interva
686680

687681
```
688682
Starting Change_Interval on ESP32S2_DEV
689-
ESP32_S2_TimerInterrupt v1.5.0
683+
ESP32_S2_TimerInterrupt v1.5.1
690684
CPU Frequency = 240 MHz
691685
[TISR] ESP32_S2_TimerInterrupt: _timerNo = 0, TIM_CLOCK_FREQ = 1000000.00
692686
[TISR] TIMER_BASE_CLK = 80000000, TIMER_DIVIDER = 80
@@ -724,7 +718,7 @@ The following is the sample terminal output when running example [Argument_None]
724718

725719
```
726720
Starting Argument_None on ESP32S2_DEV
727-
ESP32_S2_TimerInterrupt v1.5.0
721+
ESP32_S2_TimerInterrupt v1.5.1
728722
CPU Frequency = 240 MHz
729723
[TISR] ESP32_S2_TimerInterrupt: _timerNo = 0, TIM_CLOCK_FREQ = 1000000.00
730724
[TISR] TIMER_BASE_CLK = 80000000, TIMER_DIVIDER = 80
@@ -748,7 +742,7 @@ The following is the sample terminal output when running example [ISR_16_Timers_
748742

749743
```
750744
Starting ISR_16_Timers_Array_Complex on ESP32S2_DEV
751-
ESP32_S2_TimerInterrupt v1.5.0
745+
ESP32_S2_TimerInterrupt v1.5.1
752746
CPU Frequency = 240 MHz
753747
[TISR] ESP32_S2_TimerInterrupt: _timerNo = 1, TIM_CLOCK_FREQ = 1000000.00
754748
[TISR] TIMER_BASE_CLK = 80000000, TIMER_DIVIDER = 80
@@ -903,7 +897,7 @@ The following is the sample terminal output when running example [ISR_16_Timers_
903897

904898
```
905899
Starting ISR_16_Timers_Array on ESP32S2_DEV
906-
ESP32_S2_TimerInterrupt v1.5.0
900+
ESP32_S2_TimerInterrupt v1.5.1
907901
CPU Frequency = 240 MHz
908902
[TISR] ESP32_S2_TimerInterrupt: _timerNo = 1, TIM_CLOCK_FREQ = 1000000.00
909903
[TISR] TIMER_BASE_CLK = 80000000, TIMER_DIVIDER = 80

changelog.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
## Table of Contents
1313

1414
* [Changelog](#changelog)
15+
* [Releases v1.5.1](#releases-v151)
1516
* [Releases v1.5.0](#releases-v150)
1617
* [Releases v1.4.0](#releases-v140)
1718
* [Releases v1.3.0](#releases-v130)
@@ -21,6 +22,11 @@
2122

2223
## Changelog
2324

25+
### Releases v1.5.1
26+
27+
1. Add support to new Adafruit board QTPY_ESP32S2
28+
2. Update examples
29+
2430
### Releases v1.5.0
2531

2632
1. Fix `multiple-definitions` linker error. Drop `src_cpp` and `src_h` directories

examples/Argument_None/Argument_None.ino

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,6 @@
3030
or the entire sequence of your code which accesses the data.
3131
*/
3232

33-
#if !( ARDUINO_ESP32S2_DEV || ARDUINO_FEATHERS2 || ARDUINO_ESP32S2_THING_PLUS || ARDUINO_MICROS2 || \
34-
ARDUINO_METRO_ESP32S2 || ARDUINO_MAGTAG29_ESP32S2 || ARDUINO_FUNHOUSE_ESP32S2 || \
35-
ARDUINO_ADAFRUIT_FEATHER_ESP32S2_NOPSRAM )
36-
#error This code is intended to run on the ESP32-S2 platform! Please check your Tools->Board setting.
37-
#endif
38-
3933
// These define's must be placed at the beginning before #include "TimerInterrupt_Generic.h"
4034
// _TIMERINTERRUPT_LOGLEVEL_ from 0 to 4
4135
// Don't define _TIMERINTERRUPT_LOGLEVEL_ > 0. Only for special ISR debugging only. Can hang the system.

examples/Change_Interval/Change_Interval.ino

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,6 @@
3030
or the entire sequence of your code which accesses the data.
3131
*/
3232

33-
#if !( ARDUINO_ESP32S2_DEV || ARDUINO_FEATHERS2 || ARDUINO_ESP32S2_THING_PLUS || ARDUINO_MICROS2 || \
34-
ARDUINO_METRO_ESP32S2 || ARDUINO_MAGTAG29_ESP32S2 || ARDUINO_FUNHOUSE_ESP32S2 || \
35-
ARDUINO_ADAFRUIT_FEATHER_ESP32S2_NOPSRAM )
36-
#error This code is intended to run on the ESP32-S2 platform! Please check your Tools->Board setting.
37-
#endif
38-
3933
// These define's must be placed at the beginning before #include "TimerInterrupt_Generic.h"
4034
// _TIMERINTERRUPT_LOGLEVEL_ from 0 to 4
4135
// Don't define _TIMERINTERRUPT_LOGLEVEL_ > 0. Only for special ISR debugging only. Can hang the system.

examples/ISR_16_Timers_Array/ISR_16_Timers_Array.ino

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -46,13 +46,6 @@
4646
written
4747
*/
4848

49-
#if !( ARDUINO_ESP32S2_DEV || ARDUINO_FEATHERS2 || ARDUINO_ESP32S2_THING_PLUS || ARDUINO_MICROS2 || \
50-
ARDUINO_METRO_ESP32S2 || ARDUINO_MAGTAG29_ESP32S2 || ARDUINO_FUNHOUSE_ESP32S2 || \
51-
ARDUINO_ADAFRUIT_FEATHER_ESP32S2_NOPSRAM )
52-
#error This code is intended to run on the ESP32-S2 platform! Please check your Tools->Board setting.
53-
#endif
54-
55-
5649
// These define's must be placed at the beginning before #include "ESP32TimerInterrupt.h"
5750
// _TIMERINTERRUPT_LOGLEVEL_ from 0 to 4
5851
// Don't define _TIMERINTERRUPT_LOGLEVEL_ > 0. Only for special ISR debugging only. Can hang the system.

examples/ISR_16_Timers_Array_Complex/ISR_16_Timers_Array_Complex.ino

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -37,12 +37,6 @@
3737
written
3838
*/
3939

40-
#if !( ARDUINO_ESP32S2_DEV || ARDUINO_FEATHERS2 || ARDUINO_ESP32S2_THING_PLUS || ARDUINO_MICROS2 || \
41-
ARDUINO_METRO_ESP32S2 || ARDUINO_MAGTAG29_ESP32S2 || ARDUINO_FUNHOUSE_ESP32S2 || \
42-
ARDUINO_ADAFRUIT_FEATHER_ESP32S2_NOPSRAM )
43-
#error This code is intended to run on the ESP32-S2 platform! Please check your Tools->Board setting.
44-
#endif
45-
4640
// These define's must be placed at the beginning before #include "ESP32TimerInterrupt.h"
4741
// _TIMERINTERRUPT_LOGLEVEL_ from 0 to 4
4842
// Don't define _TIMERINTERRUPT_LOGLEVEL_ > 0. Only for special ISR debugging only. Can hang the system.

examples/RPM_Measure/RPM_Measure.ino

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -38,12 +38,6 @@
3838
You can also use interrupt to detect whenever the SW is active, set a flag then use timer to count the time between active state
3939
*/
4040

41-
#if !( ARDUINO_ESP32S2_DEV || ARDUINO_FEATHERS2 || ARDUINO_ESP32S2_THING_PLUS || ARDUINO_MICROS2 || \
42-
ARDUINO_METRO_ESP32S2 || ARDUINO_MAGTAG29_ESP32S2 || ARDUINO_FUNHOUSE_ESP32S2 || \
43-
ARDUINO_ADAFRUIT_FEATHER_ESP32S2_NOPSRAM )
44-
#error This code is intended to run on the ESP32-S2 platform! Please check your Tools->Board setting.
45-
#endif
46-
4741
// These define's must be placed at the beginning before #include "TimerInterrupt_Generic.h"
4842
// _TIMERINTERRUPT_LOGLEVEL_ from 0 to 4
4943
// Don't define _TIMERINTERRUPT_LOGLEVEL_ > 0. Only for special ISR debugging only. Can hang the system.

examples/SwitchDebounce/SwitchDebounce.ino

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -35,12 +35,6 @@
3535
SW is released.
3636
*/
3737

38-
#if !( ARDUINO_ESP32S2_DEV || ARDUINO_FEATHERS2 || ARDUINO_ESP32S2_THING_PLUS || ARDUINO_MICROS2 || \
39-
ARDUINO_METRO_ESP32S2 || ARDUINO_MAGTAG29_ESP32S2 || ARDUINO_FUNHOUSE_ESP32S2 || \
40-
ARDUINO_ADAFRUIT_FEATHER_ESP32S2_NOPSRAM )
41-
#error This code is intended to run on the ESP32-S2 platform! Please check your Tools->Board setting.
42-
#endif
43-
4438
//These define's must be placed at the beginning before #include "TimerInterrupt.h"
4539
// Don't define TIMER_INTERRUPT_DEBUG > 2. Only for special ISR debugging only. Can hang the system.
4640
#define TIMER_INTERRUPT_DEBUG 1

examples/TimerInterruptTest/TimerInterruptTest.ino

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,12 +29,6 @@
2929
or the entire sequence of your code which accesses the data.
3030
*/
3131

32-
#if !( ARDUINO_ESP32S2_DEV || ARDUINO_FEATHERS2 || ARDUINO_ESP32S2_THING_PLUS || ARDUINO_MICROS2 || \
33-
ARDUINO_METRO_ESP32S2 || ARDUINO_MAGTAG29_ESP32S2 || ARDUINO_FUNHOUSE_ESP32S2 || \
34-
ARDUINO_ADAFRUIT_FEATHER_ESP32S2_NOPSRAM )
35-
#error This code is intended to run on the ESP32-S2 platform! Please check your Tools->Board setting.
36-
#endif
37-
3832
// These define's must be placed at the beginning before #include "TimerInterrupt_Generic.h"
3933
// _TIMERINTERRUPT_LOGLEVEL_ from 0 to 4
4034
// Don't define _TIMERINTERRUPT_LOGLEVEL_ > 0. Only for special ISR debugging only. Can hang the system.

0 commit comments

Comments
 (0)