shields: add Sparkfun MAX3421E shield support
Add Sparkfun MAX3421E shield support. Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
This commit is contained in:
parent
da639954c1
commit
bb7ab1e0f2
4 changed files with 91 additions and 0 deletions
9
boards/shields/max3421e/Kconfig.defconfig
Normal file
9
boards/shields/max3421e/Kconfig.defconfig
Normal file
|
@ -0,0 +1,9 @@
|
|||
# Copyright (c) 2022 Nordic Semiconductor ASA
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
if SHIELD_SPARKFUN_MAX3421E
|
||||
|
||||
config UHC_DRIVER
|
||||
default y
|
||||
|
||||
endif # SHIELD_SPARKFUN_MAX3421E
|
5
boards/shields/max3421e/Kconfig.shield
Normal file
5
boards/shields/max3421e/Kconfig.shield
Normal file
|
@ -0,0 +1,5 @@
|
|||
# Copyright (c) 2022 Nordic Semiconductor ASA
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
config SHIELD_SPARKFUN_MAX3421E
|
||||
def_bool $(shields_list_contains,sparkfun_max3421e)
|
58
boards/shields/max3421e/doc/index.rst
Normal file
58
boards/shields/max3421e/doc/index.rst
Normal file
|
@ -0,0 +1,58 @@
|
|||
.. _max3421e_shield:
|
||||
|
||||
MAX3421E Shield
|
||||
###############
|
||||
|
||||
Overview
|
||||
********
|
||||
|
||||
Support for expansion boards (shields) based on MAX3421E USB Peripheral/Host
|
||||
controller.
|
||||
|
||||
Sparkfun USB Host Shield
|
||||
************************
|
||||
|
||||
Pins Assignment of the Shield Connector
|
||||
=======================================
|
||||
|
||||
+-----------------------+-----------------------+-----------------------------+
|
||||
| Shield Connector Pin | Function | MAX3421E Pin |
|
||||
+=======================+=======================+=============================+
|
||||
| D0 | not connected | |
|
||||
+-----------------------+-----------------------+-----------------------------+
|
||||
| D1 | not connected | |
|
||||
+-----------------------+-----------------------+-----------------------------+
|
||||
| D2 | not connected | |
|
||||
+-----------------------+-----------------------+-----------------------------+
|
||||
| D3 | not connected | |
|
||||
+-----------------------+-----------------------+-----------------------------+
|
||||
| D4 | not connected | |
|
||||
+-----------------------+-----------------------+-----------------------------+
|
||||
| D5 | not connected | |
|
||||
+-----------------------+-----------------------+-----------------------------+
|
||||
| D6 | not connected | |
|
||||
+-----------------------+-----------------------+-----------------------------+
|
||||
| D7 | RESET pin | |
|
||||
+-----------------------+-----------------------+-----------------------------+
|
||||
| D8 | not connected | |
|
||||
+-----------------------+-----------------------+-----------------------------+
|
||||
| D9 | INTn | 24 (Interrupt Output) |
|
||||
+-----------------------+-----------------------+-----------------------------+
|
||||
| D10 | SPI CSn | 34 (SPI Chip Select) |
|
||||
+-----------------------+-----------------------+-----------------------------+
|
||||
| D11 | SPI MOSI | 36 (SPI Serial Data Input) |
|
||||
+-----------------------+-----------------------+-----------------------------+
|
||||
| D12 | SPI MISO | 35 (SPI Serial Data Out) |
|
||||
+-----------------------+-----------------------+-----------------------------+
|
||||
| D13 | SPI SCK | 37 (SPI Serial Clock Input) |
|
||||
+-----------------------+-----------------------+-----------------------------+
|
||||
| D14 | not connected | |
|
||||
+-----------------------+-----------------------+-----------------------------+
|
||||
| D15 | not connected | |
|
||||
+-----------------------+-----------------------+-----------------------------+
|
||||
|
||||
Programming
|
||||
***********
|
||||
|
||||
Set ``-DSHIELD=sparkfun_max3421e`` when you invoke ``west build`` or ``cmake``
|
||||
in your Zephyr application.
|
19
boards/shields/max3421e/sparkfun_max3421e.overlay
Normal file
19
boards/shields/max3421e/sparkfun_max3421e.overlay
Normal file
|
@ -0,0 +1,19 @@
|
|||
/*
|
||||
* Copyright (c) 2022 Nordic Semiconductor ASA
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
&arduino_spi {
|
||||
status = "okay";
|
||||
cs-gpios = <&arduino_header 16 GPIO_ACTIVE_LOW>; /* D10 */
|
||||
|
||||
zephyr_uhc0: max3421e@0 {
|
||||
compatible = "maxim,max3421e_spi";
|
||||
spi-max-frequency = <26000000>;
|
||||
int-gpios = <&arduino_header 15 GPIO_ACTIVE_LOW>; /* D9 */
|
||||
reset-gpios = <&arduino_header 13 GPIO_ACTIVE_LOW>; /* D7 */
|
||||
status = "okay";
|
||||
reg = <0>;
|
||||
};
|
||||
};
|
Loading…
Add table
Add a link
Reference in a new issue