Skip to content

Commit f29856c

Browse files
committed
Update docstrings and docs.
1 parent b0206e9 commit f29856c

File tree

9 files changed

+209
-5
lines changed

9 files changed

+209
-5
lines changed

adafruit_led_animation/animation.py

+1-2
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,7 @@
2424
`adafruit_led_animation.animation`
2525
================================================================================
2626
27-
CircuitPython helper library for LED animations.
28-
27+
Animation base class, and basic animations for CircuitPython helper library for LED animations.
2928
3029
* Author(s): Roy Hooper, Kattni Rembor
3130

adafruit_led_animation/color.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
2020
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
2121
# THE SOFTWARE.
22-
"""Color variables made available for import.
22+
"""Color variables made available for import for CircuitPython LED animations library.
2323
2424
RAINBOW is a list of colors to use for cycling through.
2525
"""

adafruit_led_animation/group.py

+49
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,52 @@
1+
# The MIT License (MIT)
2+
#
3+
# Copyright (c) 2019-2020 Roy Hooper
4+
# Copyright (c) 2020 Kattni Rembor for Adafruit Industries
5+
#
6+
# Permission is hereby granted, free of charge, to any person obtaining a copy
7+
# of this software and associated documentation files (the "Software"), to deal
8+
# in the Software without restriction, including without limitation the rights
9+
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10+
# copies of the Software, and to permit persons to whom the Software is
11+
# furnished to do so, subject to the following conditions:
12+
#
13+
# The above copyright notice and this permission notice shall be included in
14+
# all copies or substantial portions of the Software.
15+
#
16+
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17+
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18+
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19+
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20+
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21+
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
22+
# THE SOFTWARE.
23+
"""
24+
`adafruit_led_animation.group`
25+
================================================================================
26+
27+
Animation group helper for CircuitPython helper library for LED animations..
28+
29+
30+
* Author(s): Roy Hooper, Kattni Rembor
31+
32+
Implementation Notes
33+
--------------------
34+
35+
**Hardware:**
36+
37+
* `Adafruit NeoPixels <https://www.adafruit.com/category/168>`_
38+
* `Adafruit DotStars <https://www.adafruit.com/category/885>`_
39+
40+
**Software and Dependencies:**
41+
42+
* Adafruit CircuitPython firmware for the supported boards:
43+
https://circuitpython.org/downloads
44+
45+
"""
46+
47+
__version__ = "0.0.0-auto.0"
48+
__repo__ = "https://github.com/adafruit/Adafruit_CircuitPython_LED_Animation.git"
49+
150
class AnimationGroup:
251
"""
352
A group of animations that are active together. An example would be grouping a strip of

adafruit_led_animation/helper.py

+1-2
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,7 @@
2323
`adafruit_led_animation.helper`
2424
================================================================================
2525
26-
Helper classes for making complex animations using LED Animation library.
27-
26+
Helper classes for making complex animations using CircuitPython LED animations library.
2827
2928
* Author(s): Roy Hooper, Kattni Rembor
3029

adafruit_led_animation/rainbow.py

+47
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,54 @@
1+
# The MIT License (MIT)
2+
#
3+
# Copyright (c) 2019-2020 Roy Hooper
4+
# Copyright (c) 2020 Kattni Rembor for Adafruit Industries
5+
#
6+
# Permission is hereby granted, free of charge, to any person obtaining a copy
7+
# of this software and associated documentation files (the "Software"), to deal
8+
# in the Software without restriction, including without limitation the rights
9+
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10+
# copies of the Software, and to permit persons to whom the Software is
11+
# furnished to do so, subject to the following conditions:
12+
#
13+
# The above copyright notice and this permission notice shall be included in
14+
# all copies or substantial portions of the Software.
15+
#
16+
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17+
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18+
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19+
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20+
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21+
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
22+
# THE SOFTWARE.
23+
"""
24+
`adafruit_led_animation.rainbow`
25+
================================================================================
26+
27+
Rainbow animations for CircuitPython helper library for LED animations.
28+
29+
* Author(s): Roy Hooper, Kattni Rembor
30+
31+
Implementation Notes
32+
--------------------
33+
34+
**Hardware:**
35+
36+
* `Adafruit NeoPixels <https://www.adafruit.com/category/168>`_
37+
* `Adafruit DotStars <https://www.adafruit.com/category/885>`_
38+
39+
**Software and Dependencies:**
40+
41+
* Adafruit CircuitPython firmware for the supported boards:
42+
https://circuitpython.org/downloads
43+
44+
"""
45+
146
from adafruit_led_animation.animation import Animation, Chase, Comet
247
from adafruit_led_animation.color import BLACK, colorwheel
348
from . import NANOS_PER_SECOND, monotonic_ns
449

50+
__version__ = "0.0.0-auto.0"
51+
__repo__ = "https://github.com/adafruit/Adafruit_CircuitPython_LED_Animation.git"
552

653
class Rainbow(Animation):
754
"""

adafruit_led_animation/sequence.py

+48
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,55 @@
1+
# The MIT License (MIT)
2+
#
3+
# Copyright (c) 2019-2020 Roy Hooper
4+
# Copyright (c) 2020 Kattni Rembor for Adafruit Industries
5+
#
6+
# Permission is hereby granted, free of charge, to any person obtaining a copy
7+
# of this software and associated documentation files (the "Software"), to deal
8+
# in the Software without restriction, including without limitation the rights
9+
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10+
# copies of the Software, and to permit persons to whom the Software is
11+
# furnished to do so, subject to the following conditions:
12+
#
13+
# The above copyright notice and this permission notice shall be included in
14+
# all copies or substantial portions of the Software.
15+
#
16+
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17+
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18+
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19+
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20+
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21+
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
22+
# THE SOFTWARE.
23+
"""
24+
`adafruit_led_animation.sequence`
25+
================================================================================
26+
27+
Animation sequence helper for CircuitPython helper library for LED animations.
28+
29+
30+
* Author(s): Roy Hooper, Kattni Rembor
31+
32+
Implementation Notes
33+
--------------------
34+
35+
**Hardware:**
36+
37+
* `Adafruit NeoPixels <https://www.adafruit.com/category/168>`_
38+
* `Adafruit DotStars <https://www.adafruit.com/category/885>`_
39+
40+
**Software and Dependencies:**
41+
42+
* Adafruit CircuitPython firmware for the supported boards:
43+
https://circuitpython.org/downloads
44+
45+
"""
46+
147
import random
248
from adafruit_led_animation.color import BLACK
349
from . import NANOS_PER_SECOND, monotonic_ns
450

51+
__version__ = "0.0.0-auto.0"
52+
__repo__ = "https://github.com/adafruit/Adafruit_CircuitPython_LED_Animation.git"
553

654
class AnimationSequence:
755
"""

adafruit_led_animation/sparkle.py

+48
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,55 @@
1+
# The MIT License (MIT)
2+
#
3+
# Copyright (c) 2019-2020 Roy Hooper
4+
# Copyright (c) 2020 Kattni Rembor for Adafruit Industries
5+
#
6+
# Permission is hereby granted, free of charge, to any person obtaining a copy
7+
# of this software and associated documentation files (the "Software"), to deal
8+
# in the Software without restriction, including without limitation the rights
9+
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10+
# copies of the Software, and to permit persons to whom the Software is
11+
# furnished to do so, subject to the following conditions:
12+
#
13+
# The above copyright notice and this permission notice shall be included in
14+
# all copies or substantial portions of the Software.
15+
#
16+
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17+
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18+
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19+
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20+
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21+
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
22+
# THE SOFTWARE.
23+
"""
24+
`adafruit_led_animation.sparkle`
25+
================================================================================
26+
27+
Sparkle animations for CircuitPython helper library for LED animations.
28+
29+
30+
* Author(s): Roy Hooper, Kattni Rembor
31+
32+
Implementation Notes
33+
--------------------
34+
35+
**Hardware:**
36+
37+
* `Adafruit NeoPixels <https://www.adafruit.com/category/168>`_
38+
* `Adafruit DotStars <https://www.adafruit.com/category/885>`_
39+
40+
**Software and Dependencies:**
41+
42+
* Adafruit CircuitPython firmware for the supported boards:
43+
https://circuitpython.org/downloads
44+
45+
"""
46+
147
import random
248
from adafruit_led_animation.animation import Animation
349
from . import NANOS_PER_SECOND, monotonic_ns
450

51+
__version__ = "0.0.0-auto.0"
52+
__repo__ = "https://github.com/adafruit/Adafruit_CircuitPython_LED_Animation.git"
553

654
class Sparkle(Animation):
755
"""

docs/api.rst

+12
Original file line numberDiff line numberDiff line change
@@ -12,3 +12,15 @@
1212

1313
.. automodule:: adafruit_led_animation.helper
1414
:members:
15+
16+
.. automodule:: adafruit_led_animation.group
17+
:members:
18+
19+
.. automodule:: adafruit_led_animation.sequence
20+
:members:
21+
22+
.. automodule:: adafruit_led_animation.rainbow
23+
:members:
24+
25+
.. automodule:: adafruit_led_animation.sparkle
26+
:members:

examples/led_animation_gridmap.py

+2
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44
55
For NeoPixel FeatherWing. Update pixel_pin and pixel_num to match your wiring if using
66
a different form of NeoPixels.
7+
8+
This example does not work on SAMD21 (M0) boards.
79
"""
810
import board
911
import neopixel

0 commit comments

Comments
 (0)