Skip to content

Commit 9b657ac

Browse files
authored
Make JLedSequence objects assignable (#94)
1 parent 8380506 commit 9b657ac

File tree

5 files changed

+11
-6
lines changed

5 files changed

+11
-6
lines changed

CHANGELOG.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11
# JLed changelog (github.com/jandelgado/jled)
22

3-
## [2022-02-24] 4.10.0
3+
## [2022-03-29] 4.11.0
4+
5+
* change: `JLedSequence` objects are now assignable, making switching
6+
effects easier. See https://github.com/jandelgado/jled-example-switch-sequence for an example.
7+
8+
## [2022-03-24] 4.10.0
49

510
* new: `On`, `Off` and `Set` now take an optional `duration` value, making
611
these effects behave like any other in this regard. This allows to add

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -552,6 +552,7 @@ Example sketches are provided in the [examples](examples/) directory.
552552
* [Simple User provided effect](examples/user_func)
553553
* [Morsecode example](examples/morse)
554554
* [Custom HAL example](examples/custom_hal)
555+
* [Dynamically switch sequences](https://github.com/jandelgado/jled-example-switch-sequence)
555556
* [JLed compiled to WASM and running in the browser](https://jandelgado.github.io/jled-wasm)
556557
* [Raspberry Pi Pico Demo](examples/raspi_pico)
557558
* [ESP32 ESP-IDF example](https://github.com/jandelgado/jled-esp-idf-example)

library.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "JLed",
3-
"version": "4.10.0",
3+
"version": "4.11.0",
44
"description": "An embedded library to control LEDs",
55
"license": "MIT",
66
"frameworks": ["espidf", "arduino", "mbed"],

library.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name=JLed
2-
version=4.10.0
2+
version=4.11.0
33
author=Jan Delgado <jdelgado[at]gmx.net>
44
maintainer=Jan Delgado <jdelgado[at]gmx.net>
55
sentence=An Arduino library to control LEDs

src/jled_base.h

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -569,16 +569,15 @@ class TJLedSequence {
569569
bool IsForever() const { return num_repetitions_ == kRepeatForever; }
570570

571571
private:
572-
const eMode mode_;
572+
eMode mode_;
573573
L* leds_;
574574
size_t cur_;
575-
const size_t n_;
575+
size_t n_;
576576
static constexpr uint16_t kRepeatForever = 65535;
577577
uint16_t num_repetitions_ = 1;
578578
uint16_t iteration_ = 0;
579579
bool is_running_ = true;
580580
};
581581

582582
}; // namespace jled
583-
584583
#endif // SRC_JLED_BASE_H_

0 commit comments

Comments
 (0)