Skip to content

Commit e3b2e54

Browse files
authored
Merge pull request #24 from bxparks/develop
merge 1.2.3 into master
2 parents 33199e5 + e605a69 commit e3b2e54

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

55 files changed

+691
-218
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,12 @@
11
# Changelog
22

33
* Unreleased
4+
* 1.2.3 (2021-01-19)
5+
* Add official support for STM32 by validating on a Blue Pill board.
6+
* Add scripts to `AutoBenchmark` to automate data collection.
7+
* Update `MemoryBenchmark` and `AutoBenchmark` tables with STM32; re-add
8+
Teensy 3.2 benchmarks now that I'm able to upload again.
9+
* No functional change in this release.
410
* 1.2.2 (2020-12-20)
511
* Add generic definition of `FPSTR()` macro for unrecognized platforms.
612
Allows code with `ARDUINO_ARCH_STM32` dependencies to compile. I will

README.md

Lines changed: 39 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -46,11 +46,12 @@ others (in my opinion of course):
4646
* the `CoroutineScheduler` consumes only 2 bytes (8-bit) or 4 bytes (32-bit)
4747
no matter how many coroutines are active
4848
* extremely fast context switching
49-
* ~6 microseconds on a 16 MHz ATmega328P
50-
* ~2.9 microseconds on a 48 MHz SAMD21
51-
* ~1.7 microseconds on a 80 MHz ESP8266
49+
* ~5.3 microseconds on a 16 MHz ATmega328P
50+
* ~2.5 microseconds on a 48 MHz SAMD21
51+
* ~1.8 microseconds on a 72 MHz STM32
52+
* ~1.5 microseconds on a 80 MHz ESP8266
5253
* ~0.4 microseconds on a 240 MHz ESP32
53-
* 0.7-1.1 microseconds on 96 MHz Teensy 3.2 (depending on compiler settings)
54+
* ~1.0 microseconds on 96 MHz Teensy 3.2 (depending on compiler settings)
5455
* uses the [computed goto](https://gcc.gnu.org/onlinedocs/gcc/Labels-as-Values.html)
5556
feature of the GCC compiler (also supported by Clang) to avoid the
5657
[Duff's Device](https://en.wikipedia.org/wiki/Duff%27s_device) hack
@@ -81,7 +82,7 @@ AceRoutine is a self-contained library that works on any platform supporting the
8182
Arduino API (AVR, Teensy, ESP8266, ESP32, etc), and it provides a handful of
8283
additional macros that can reduce boilerplate code.
8384

84-
**Version**: 1.2.2 (2020-12-20)
85+
**Version**: 1.2.3 (2021-01-19)
8586

8687
**Changelog**: [CHANGELOG.md](CHANGELOG.md)
8788

@@ -455,8 +456,8 @@ etc) for a handful of AceRoutine features. Here are some highlights:
455456
* AVR (e.g. Nano)
456457
* 1 Coroutine: 1098 bytes
457458
* 2 Coroutines: 1326 bytes
458-
* `CoroutineScheduler()` + 1 Coroutine: 1238 bytes
459-
* `CoroutineScheduler()` + 2 Coroutines: 1388 bytes
459+
* `CoroutineScheduler()` + 1 Coroutine: 1240 bytes
460+
* `CoroutineScheduler()` + 2 Coroutines: 1390 bytes
460461
* ESP8266
461462
* 1 Coroutine: 680 bytes
462463
* 2 Coroutines: 908 bytes
@@ -466,21 +467,45 @@ etc) for a handful of AceRoutine features. Here are some highlights:
466467
<a name="CPU"></a>
467468
### CPU
468469
469-
See [examples/AutoBenchmark](examples/AutoBenchmark).
470+
See [examples/AutoBenchmark](examples/AutoBenchmark). In summary, the overhead
471+
of AceRoutine context switching is about 5 micros on an 8-bit AVR, to as low as
472+
0.41 micros on a 32-bit ESP32.
470473
471474
<a name="SystemRequirements"></a>
472475
## System Requirements
473476
477+
### Hardware
478+
479+
The library has been extensively tested on the following boards:
480+
481+
* Arduino Nano clone (16 MHz ATmega328P)
482+
* SparkFun Pro Micro clone (16 MHz ATmega32U4)
483+
* SAMD21 M0 Mini (48 MHz ARM Cortex-M0+)
484+
* STM32 Blue Pill (STM32F103C8, 72 MHz ARM Cortex-M3)
485+
* NodeMCU 1.0 (ESP-12E module, 80 MHz ESP8266)
486+
* WeMos D1 Mini (ESP-12E module, 80 MHz ESP8266)
487+
* ESP32 dev board (ESP-WROOM-32 module, 240 MHz dual core Tensilica LX6)
488+
* Teensy 3.2 (96 MHz ARM Cortex-M4)
489+
490+
I will occasionally test on the following hardware as a sanity check:
491+
492+
* Arduino Pro Mini clone (16 MHz ATmega328P)
493+
* Mini Mega 2560 (Arduino Mega 2560 compatible, 16 MHz ATmega2560)
494+
* Teensy LC (48 MHz ARM Cortex-M0+)
495+
474496
### Tool Chain
475497
476498
This library was developed and tested using:
477499
* [Arduino IDE 1.8.13](https://www.arduino.cc/en/Main/Software)
500+
* [Arduino CLI 0.14.0](https://arduino.github.io/arduino-cli)
478501
* [Arduino AVR Boards 1.8.3](https://github.com/arduino/ArduinoCore-avr)
479-
* [Arduino SAMD Boards 1.8.6](https://github.com/arduino/ArduinoCore-samd)
502+
* [Arduino SAMD Boards 1.8.9](https://github.com/arduino/ArduinoCore-samd)
480503
* [SparkFun AVR Boards 1.1.13](https://github.com/sparkfun/Arduino_Boards)
504+
* [SparkFun SAMD Boards 1.8.1](https://github.com/sparkfun/Arduino_Boards)
505+
* [STM32duino 1.9.0](https://github.com/stm32duino/Arduino_Core_STM32)
481506
* [ESP8266 Arduino 2.7.4](https://github.com/esp8266/Arduino)
482507
* [ESP32 Arduino 1.0.4](https://github.com/espressif/arduino-esp32)
483-
* [Teensydino 1.53.beta](https://www.pjrc.com/teensy/td_download.html)
508+
* [Teensydino 1.53](https://www.pjrc.com/teensy/td_download.html)
484509
485510
It should work with [PlatformIO](https://platformio.org/) but I have
486511
not tested it.
@@ -493,23 +518,6 @@ the [UnixHostDuino](https://github.com/bxparks/UnixHostDuino) emulation layer.
493518
I use Ubuntu 18.04 and 20.04 for most of my development and sometimes do sanity
494519
checks on MacOS 10.14.5.
495520
496-
### Hardware
497-
498-
The library has been extensively tested on the following boards:
499-
500-
* Arduino Nano clone (16 MHz ATmega328P)
501-
* Arduino Pro Mini clone (16 MHz ATmega328P)
502-
* Arduino Pro Micro clone (16 MHz ATmega32U4)
503-
* SAMD21 M0 Mini (48 MHz ARM Cortex-M0+) (compatible with Arduino Zero)
504-
* NodeMCU 1.0 clone (ESP-12E module, 80 MHz ESP8266)
505-
* ESP32 dev board (ESP-WROOM-32 module, 240 MHz dual core Tensilica LX6)
506-
* Teensy 3.2 (72 MHz ARM Cortex-M4)
507-
508-
I will occasionally test on the following hardware as a sanity check:
509-
510-
* Teensy LC (48 MHz ARM Cortex-M0+)
511-
* Mini Mega 2560 (Arduino Mega 2560 compatible, 16 MHz ATmega2560)
512-
513521
<a name="License"></a>
514522
## License
515523
@@ -518,6 +526,10 @@ I will occasionally test on the following hardware as a sanity check:
518526
<a name="Feedback"></a>
519527
## Feedback and Support
520528
529+
If you find this library useful, consider starring this project on GitHub. The
530+
stars will let me prioritize the more popular libraries over the less popular
531+
ones.
532+
521533
If you have any questions, comments, bug reports, or feature requests, please
522534
file a GitHub ticket instead of emailing me unless the content is sensitive.
523535
(The problem with email is that I cannot reference the email conversation when

USER_GUIDE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ See the [README.md](README.md) for installation instructions and other
44
background information. This document describes how to use the library once it
55
is installed.
66

7-
**Version**: 1.2.2 (2020-12-20)
7+
**Version**: 1.2.3 (2021-01-19)
88

99
## Table of Contents
1010

docs/doxygen.cfg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ PROJECT_NAME = "AceRoutine"
3838
# could be handy for archiving the generated documentation or if some version
3939
# control system is used.
4040

41-
PROJECT_NUMBER = 1.2.2
41+
PROJECT_NUMBER = 1.2.3
4242

4343
# Using the PROJECT_BRIEF tag one can provide an optional one line description
4444
# for a project that appears at the top of each page and should give viewer a

docs/html/AceRoutine_8h_source.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<tr style="height: 56px;">
2323
<td id="projectalign" style="padding-left: 0.5em;">
2424
<div id="projectname">AceRoutine
25-
&#160;<span id="projectnumber">1.2.2</span>
25+
&#160;<span id="projectnumber">1.2.3</span>
2626
</div>
2727
<div id="projectbrief">A low-memory, fast-switching, cooperative multitasking library using stackless coroutines on Arduino platforms.</div>
2828
</td>
@@ -103,8 +103,8 @@
103103
<div class="line"><a name="l00041"></a><span class="lineno"> 41</span>&#160;<span class="preprocessor">#include &quot;ace_routine/Channel.h&quot;</span></div>
104104
<div class="line"><a name="l00042"></a><span class="lineno"> 42</span>&#160; </div>
105105
<div class="line"><a name="l00043"></a><span class="lineno"> 43</span>&#160;<span class="comment">// Version format: xxyyzz == &quot;xx.yy.zz&quot;</span></div>
106-
<div class="line"><a name="l00044"></a><span class="lineno"> 44</span>&#160;<span class="preprocessor">#define ACE_ROUTINE_VERSION 10202</span></div>
107-
<div class="line"><a name="l00045"></a><span class="lineno"> 45</span>&#160;<span class="preprocessor">#define ACE_ROUTINE_VERSION_STRING &quot;1.2.2&quot;</span></div>
106+
<div class="line"><a name="l00044"></a><span class="lineno"> 44</span>&#160;<span class="preprocessor">#define ACE_ROUTINE_VERSION 10203</span></div>
107+
<div class="line"><a name="l00045"></a><span class="lineno"> 45</span>&#160;<span class="preprocessor">#define ACE_ROUTINE_VERSION_STRING &quot;1.2.3&quot;</span></div>
108108
<div class="line"><a name="l00046"></a><span class="lineno"> 46</span>&#160; </div>
109109
<div class="line"><a name="l00047"></a><span class="lineno"> 47</span>&#160;<span class="preprocessor">#endif</span></div>
110110
</div><!-- fragment --></div><!-- contents -->

docs/html/Channel_8h_source.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<tr style="height: 56px;">
2323
<td id="projectalign" style="padding-left: 0.5em;">
2424
<div id="projectname">AceRoutine
25-
&#160;<span id="projectnumber">1.2.2</span>
25+
&#160;<span id="projectnumber">1.2.3</span>
2626
</div>
2727
<div id="projectbrief">A low-memory, fast-switching, cooperative multitasking library using stackless coroutines on Arduino platforms.</div>
2828
</td>

docs/html/CoroutineScheduler_8cpp_source.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<tr style="height: 56px;">
2323
<td id="projectalign" style="padding-left: 0.5em;">
2424
<div id="projectname">AceRoutine
25-
&#160;<span id="projectnumber">1.2.2</span>
25+
&#160;<span id="projectnumber">1.2.3</span>
2626
</div>
2727
<div id="projectbrief">A low-memory, fast-switching, cooperative multitasking library using stackless coroutines on Arduino platforms.</div>
2828
</td>

docs/html/CoroutineScheduler_8h_source.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<tr style="height: 56px;">
2323
<td id="projectalign" style="padding-left: 0.5em;">
2424
<div id="projectname">AceRoutine
25-
&#160;<span id="projectnumber">1.2.2</span>
25+
&#160;<span id="projectnumber">1.2.3</span>
2626
</div>
2727
<div id="projectbrief">A low-memory, fast-switching, cooperative multitasking library using stackless coroutines on Arduino platforms.</div>
2828
</td>

docs/html/Coroutine_8cpp_source.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<tr style="height: 56px;">
2323
<td id="projectalign" style="padding-left: 0.5em;">
2424
<div id="projectname">AceRoutine
25-
&#160;<span id="projectnumber">1.2.2</span>
25+
&#160;<span id="projectnumber">1.2.3</span>
2626
</div>
2727
<div id="projectbrief">A low-memory, fast-switching, cooperative multitasking library using stackless coroutines on Arduino platforms.</div>
2828
</td>
@@ -229,7 +229,7 @@
229229
<div class="ttc" id="aclassace__routine_1_1Coroutine_html_a79844c12576ff2fd2065c5f5e4b422c8"><div class="ttname"><a href="classace__routine_1_1Coroutine.html#a79844c12576ff2fd2065c5f5e4b422c8">ace_routine::Coroutine::kDelayTypeSeconds</a></div><div class="ttdeci">static const uint8_t kDelayTypeSeconds</div><div class="ttdoc">Delay using units of seconds.</div><div class="ttdef"><b>Definition:</b> <a href="Coroutine_8h_source.html#l00503">Coroutine.h:503</a></div></div>
230230
<div class="ttc" id="aclassace__routine_1_1Coroutine_html_ad29d0f43128b49c48a71a167331dac51"><div class="ttname"><a href="classace__routine_1_1Coroutine.html#ad29d0f43128b49c48a71a167331dac51">ace_routine::Coroutine::resume</a></div><div class="ttdeci">void resume()</div><div class="ttdoc">Add a Suspended coroutine into the head of the scheduler linked list, and change the state to Yieldin...</div><div class="ttdef"><b>Definition:</b> <a href="Coroutine_8cpp_source.html#l00103">Coroutine.cpp:103</a></div></div>
231231
<div class="ttc" id="aclassace__routine_1_1Coroutine_html_a668e339557964dc092540bad162056a7"><div class="ttname"><a href="classace__routine_1_1Coroutine.html#a668e339557964dc092540bad162056a7">ace_routine::Coroutine::kDelayTypeMillis</a></div><div class="ttdeci">static const uint8_t kDelayTypeMillis</div><div class="ttdoc">Delay using units of millis.</div><div class="ttdef"><b>Definition:</b> <a href="Coroutine_8h_source.html#l00497">Coroutine.h:497</a></div></div>
232-
<div class="ttc" id="acompat_8h_html_aaa60649c7ffe7ed1fbe16dc20ed7e8c3"><div class="ttname"><a href="compat_8h.html#aaa60649c7ffe7ed1fbe16dc20ed7e8c3">FPSTR</a></div><div class="ttdeci">#define FPSTR(p)</div><div class="ttdoc">A macro that converts a const char* that already points to a PROGMEM string to a const __FlashStringH...</div><div class="ttdef"><b>Definition:</b> <a href="compat_8h_source.html#l00081">compat.h:81</a></div></div>
232+
<div class="ttc" id="acompat_8h_html_aaa60649c7ffe7ed1fbe16dc20ed7e8c3"><div class="ttname"><a href="compat_8h.html#aaa60649c7ffe7ed1fbe16dc20ed7e8c3">FPSTR</a></div><div class="ttdeci">#define FPSTR(p)</div><div class="ttdoc">A macro that converts a const char* that already points to a PROGMEM string to a const __FlashStringH...</div><div class="ttdef"><b>Definition:</b> <a href="compat_8h_source.html#l00087">compat.h:87</a></div></div>
233233
<div class="ttc" id="aclassace__routine_1_1Coroutine_html_a826df2b7d3db16170a13ba4b2756c853"><div class="ttname"><a href="classace__routine_1_1Coroutine.html#a826df2b7d3db16170a13ba4b2756c853">ace_routine::Coroutine::coroutineMicros</a></div><div class="ttdeci">virtual unsigned long coroutineMicros() const</div><div class="ttdoc">Returns the current millisecond clock.</div><div class="ttdef"><b>Definition:</b> <a href="Coroutine_8cpp_source.html#l00118">Coroutine.cpp:118</a></div></div>
234234
<div class="ttc" id="aclassace__routine_1_1Coroutine_html_a397f0d87d99b538189353fa47e918022"><div class="ttname"><a href="classace__routine_1_1Coroutine.html#a397f0d87d99b538189353fa47e918022">ace_routine::Coroutine::kStatusSuspended</a></div><div class="ttdeci">static const Status kStatusSuspended</div><div class="ttdoc">Coroutine has been suspended using suspend() and the scheduler should remove it from the queue upon t...</div><div class="ttdef"><b>Definition:</b> <a href="Coroutine_8h_source.html#l00479">Coroutine.h:479</a></div></div>
235235
<div class="ttc" id="acompat_8h_html"><div class="ttname"><a href="compat_8h.html">compat.h</a></div></div>

docs/html/Coroutine_8h.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<tr style="height: 56px;">
2323
<td id="projectalign" style="padding-left: 0.5em;">
2424
<div id="projectname">AceRoutine
25-
&#160;<span id="projectnumber">1.2.2</span>
25+
&#160;<span id="projectnumber">1.2.3</span>
2626
</div>
2727
<div id="projectbrief">A low-memory, fast-switching, cooperative multitasking library using stackless coroutines on Arduino platforms.</div>
2828
</td>

0 commit comments

Comments
 (0)