Skip to content

Commit 538d34c

Browse files
soburikartben
andcommitted
boards: shields: Add support for Adafruit AW9523 board
Add support for Adafruit AW9523 GPIO Expander/LED Controller Co-authored-by: Benjamin Cabé <[email protected]> Signed-off-by: TOKITA Hiroshi <[email protected]>
1 parent 0161dd0 commit 538d34c

File tree

5 files changed

+77
-1
lines changed

5 files changed

+77
-1
lines changed
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Copyright (c) 2024 TOKITA Hiroshi
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
config SHIELD_ADAFRUIT_AW9523
5+
def_bool $(shields_list_contains,adafruit_aw9523)
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
/*
2+
* Copyright (c) 2024 TOKITA Hiroshi
3+
*
4+
* SPDX-License-Identifier: Apache-2.0
5+
*/
6+
7+
&stemma_qt_i2c {
8+
status = "okay";
9+
10+
adafruit_aw9523: aw9523b@58 {
11+
status = "okay";
12+
reg = <0x58>;
13+
compatible = "awinic,aw9523b";
14+
15+
adafruit_aw9523_gpio: aw9523b-gpio {
16+
status = "okay";
17+
compatible = "awinic,aw9523b-gpio";
18+
gpio-controller;
19+
#gpio-cells = <2>;
20+
};
21+
};
22+
};
Binary file not shown.
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
.. _adafruit_aw9523:
2+
3+
Adafruit AW9523 GPIO Expander and LED Driver
4+
############################################
5+
6+
Overview
7+
********
8+
9+
The `Adafruit AW9523 GPIO Expander and LED Driver`_ provides
10+
16-channel GPIO/LED controller function.
11+
12+
.. figure:: adafruit_aw9523.webp
13+
:align: center
14+
:alt: Adafruit AW9523
15+
16+
Adafruit AW9523 (Credit: Adafruit)
17+
18+
Pin Assignments
19+
===============
20+
21+
+--------------------------+------------------------------------------+
22+
| Shield Pin | Function |
23+
+==========================+==========================================+
24+
| SDA | AW9523B I2C SDA |
25+
+--------------------------+------------------------------------------+
26+
| SCL | AW9523B I2C SCL |
27+
+--------------------------+------------------------------------------+
28+
| INT (Pad on board) | AW9523B Interrupt output [1]_ |
29+
+--------------------------+------------------------------------------+
30+
| RST (Pad on board) | AW9523B Reset pin [2]_ |
31+
+--------------------------+------------------------------------------+
32+
33+
.. [1] To receive interrupts, connect the INT pin to the SoC's GPIO and set the connected
34+
GPIO in the ``int-gpios`` property in an additional overlay. The INT terminal must be
35+
pulled up.
36+
37+
.. [2] If you want to control the reset pin from the SoC, connect it to a GPIO on the SoC
38+
and define the ``reset-gpios`` property in an additional overlay.
39+
40+
Programming
41+
***********
42+
43+
Set ``--shield adafruit_aw9523`` when you invoke ``west build``.
44+
45+
.. _Adafruit AW9523 GPIO Expander and LED Driver:
46+
https://learn.adafruit.com/adafruit-aw9523-gpio-expander-and-led-driver
47+
48+
.. _Awinic AW9523B 16 MULTI-FUNCTION LED DRIVER AND GPIO CONTROLLER WITH I2C INTERFACE:
49+
https://doc.awinic.com/doc/202403/deffbf3b-7e7b-4ff6-8e91-fd85e2d845d5.pdf

dts/bindings/mfd/awinic,aw9523b.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Copyright (c) 2024 TOKITA Hiroshi
22
# SPDX-License-Identifier: Apache-2.0
33

4-
description: Awinic AW9523B
4+
description: Awinic AW9523B 16 multi-function LED driver and GPIO controller
55

66
compatible: "awinic,aw9523b"
77

0 commit comments

Comments
 (0)