-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #38 from makermelissa/refactor
Updated manual merge of all existing outstanding PRs
- Loading branch information
Showing
22 changed files
with
604 additions
and
323 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
# SPDX-FileCopyrightText: Tony DiCola 2017 for Adafruit Industries | ||
# | ||
# SPDX-License-Identifier: MIT | ||
|
||
""" | ||
`adafruit_is31fl3731.charlie_bonnet` | ||
==================================================== | ||
CircuitPython driver for the IS31FL3731 charlieplex IC. | ||
* Author(s): Tony DiCola, Melissa LeBlanc-Williams | ||
Implementation Notes | ||
-------------------- | ||
**Hardware:** | ||
* `Adafruit 16x8 CharliePlex LED Matrix Bonnets | ||
<https://www.adafruit.com/product/4127>`_ | ||
**Software and Dependencies:** | ||
* Adafruit CircuitPython firmware for the supported boards: | ||
https://github.com/adafruit/circuitpython/releases | ||
""" | ||
|
||
# imports | ||
from . import IS31FL3731 | ||
|
||
|
||
class CharlieBonnet(IS31FL3731): | ||
"""Supports the Charlieplexed bonnet""" | ||
|
||
width = 16 | ||
height = 8 | ||
|
||
@staticmethod | ||
def pixel_addr(x, y): | ||
"""Calulate the offset into the device array for x,y pixel""" | ||
if x >= 8: | ||
return (x - 6) * 16 - (y + 1) | ||
return (x + 1) * 16 + (7 - y) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
# SPDX-FileCopyrightText: Tony DiCola 2017 for Adafruit Industries | ||
# | ||
# SPDX-License-Identifier: MIT | ||
|
||
""" | ||
`adafruit_is31fl3731.charlie_wing` | ||
==================================================== | ||
CircuitPython driver for the IS31FL3731 charlieplex IC. | ||
* Author(s): Tony DiCola, Melissa LeBlanc-Williams | ||
Implementation Notes | ||
-------------------- | ||
**Hardware:** | ||
* `Adafruit 15x7 CharliePlex LED Matrix Display FeatherWings | ||
<https://www.adafruit.com/product/2965>`_ | ||
**Software and Dependencies:** | ||
* Adafruit CircuitPython firmware for the supported boards: | ||
https://github.com/adafruit/circuitpython/releases | ||
""" | ||
|
||
# imports | ||
from . import IS31FL3731 | ||
|
||
|
||
class CharlieWing(IS31FL3731): | ||
"""Supports the Charlieplexed feather wing""" | ||
|
||
width = 15 | ||
height = 7 | ||
|
||
@staticmethod | ||
def pixel_addr(x, y): | ||
"""Calulate the offset into the device array for x,y pixel""" | ||
if x > 7: | ||
x = 15 - x | ||
y += 8 | ||
else: | ||
y = 7 - y | ||
return x * 16 + y |
Oops, something went wrong.